Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

List subdirectories of domain

Featured Replies

I want to make a url show a list of the subdirectories in that domains folder and of cuorse with out the option to go back behind that folder so people can't mass with my files...

 

I will try to be more clear:

I have, lets say this domain: tests.domain.com

 

and in that domain i have a lot of folders of websites i'm working on:

 

tests.domain.com/TestWebsite1/

tests.domain.com/TestWebsite2/

tests.domain.com/TestWebsite3/

tests.domain.com/TestWebsite4/

And so on...

 

So i want that when i'm going to 'tests.domain.com' it will show me those sub-folders so when i click on them it will take me to this test website...

 

 

Any idea how to do that?

 

 

Thanks.

Ok, I would suggest setting up the main root as password protected or lock it by IP address depending what's better for your situation. Set the robots.txt to disallow all which will stop the whole thing being indexed.

 

Inside the root you can allow indexing of folders with htaccess (see http://stackoverflow.com/questions/12646668/allow-access-to-certain-directories-in-htaccess). Then inside each of the site folders so long as it has an index file the sites will automatically appear when a folder is clicked.

 

There are probably other ways to do this, no doubt someone on here will know a better way.

  • Author

Thanks.

 

So i'm trying, i have in this main domain folder only the subfolders and two files:

 

1. htaccess

 

2. htpasswd

 

Bothe generated by this generator you linked, but when i go to the url it says:

 

 

Forbidden

You don't have permission to access / on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.