![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| new NIC card doesn't show in show-nets | iperez | SUN Solaris | 13 | 09-26-2008 04:52 AM |
| Secondary groups show in groups but don't show in id (Not working) | zen03 | HP-UX | 4 | 12-31-2007 11:15 AM |
| how to access root priveliges if root password is lost | wojtyla | Linux | 1 | 02-18-2005 06:24 AM |
| Run non-root script as root with non-root environment | bubba112557 | UNIX for Dummies Questions & Answers | 2 | 12-03-2004 12:39 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Have htdocs/site/ show up at root
I have a site, www.mySite.com
I have a folder where pages are served from, htdocs/ I have a folder containing one site at htdocs/drupal/. I'd like to be able to go to www.mySite.com and see the index.php page within the drupal folder, but instead I see a directory listing: drupal phpBB3 How can I make this index page show up at www.mySite.com, and how can I hide the directory? I think this is easily accomplished in Apache's config file, httpd.conf, but I can't figure it out. Thank you so much! This is driving me crazy. |
|
|||||
|
Quote:
|
|
||||
|
Still confused
Thank you very much for the link. After reading through it, I don't think that's exactly what I need. I want someone to go to www.example.com and see the page that really lives at www.example.com/drupal. I can see how I could redirect them from www.example.com to www.example.com/drupal, but I don't want the name in the address bar in the browser to ever change...
I was looking at RewriteBase inthe .htaccess file in my drupal directory, but wasn't sure if that was the correct way to go. Sorry, but I'm still confused... Thanks in advance! Last edited by kumakuma; 08-19-2008 at 05:00 PM.. Reason: didn't want URLs parsed |
|
||||
|
Interesting
Wow, that's a very clever way to get it working! I tried it and it does indeed work. Thank you!
Sorry, I didn't mean I don't want the address bar to never change; I meant I didn't want to redirect visitors from www.mysite.com to www.mysite.com/drupal (which seems fairly easy to do with .htaccess, but then they would see the address bar change). Ideally, I'd like visitors to be able to go to www.mysite.com and see what is in my public_html/drupal folder. The way I have it now, they would see a directory listing containing a drupal folder and a phpBB3 folder. Of course, I could accomplish this by moving all the stuff from my drupal folder to public_html folder, but I'd like to keep things organized and keep the drupal site contained within the drupal folder. I know there's some simple way to do this... I tried creating a symlink of the index.php file in the drupal folder in the public_html folder, but it didn't work. Seems like I would need the drupal folder to be the RewriteBase for all the links from within the drupal folder to work correctly... (I'm not sure if this is the right variable, but after reading about it in the httpd.conf file, it seems like I'll need to incorporate it. |
|
|||||
|
Isn't it just a virtual domain you need here? If you want anybody visiting www.mysite.com to end up in ~/public_html/drupal/ and want anybody visiting via another alias (like www.mysitephpbb.com) to end up in ~/public_html/phpBB3/ then that would be the simplest solution I'd say...
If that is what you are after, add the following to your config: Code:
<VirtualHost *>
ServerAdmin webmaster@mysite.com
DocumentRoot /path/to/htdocs/drupal
ServerName www.mysite.com
</VirtualHost>
|
![]() |
| Bookmarks |
| Tags |
| apache, drupal, httpd.conf, virtual server |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|