Found this useful? Love this post

Hide a directory or asset from the front-end using Web Paths in Squiz Matrix

Using Squiz Matrix, you might wish to hide or prevent a directory from being viewable to the public. All it takes is a quick couple of steps using Web Paths to hide the directory and its children.

A prime example of this is if you have a folder inside a directory such as the example shown below:

squiz-folder-structure

The front-end URL might be:


http://www.domsammut.com/landing-page/sidebar/

Now you don’t really want the sidebar folder to visible to the front-end user. To hide this folder you need to remove the Web Path for it.

Removing the Web Path will make all the child assets become inaccessible via a URL.

To remove the web path, right click on the folder and select Web Paths

squiz-folder-structure-webpaths

You should now see the the Web Paths dialog.

squiz-webpaths-dialog-prior-to-removal

From here, simply remove the text from the Paths field, leaving it blank

squiz-webpaths-dialog-removal

Hit Commit down in the bottom right-hand corner.

Your Web Paths dialog should now look like this:

squiz-webpaths-after-removal

This folder is now no-longer viewable to front-end user and depending on your setup, should return a 404.

 

Subscribe

You'll only get 1 email per month containing new posts (I hate spam as much as you!). You can opt out at anytime.

Categories

Leave a Reply

Your email address will not be published. Required fields are marked *

Preview Comment

css.php