Jump to content
The Uniform Server Community

mod_rewrite help!? ASAP!?


DJCheezy
 Share

Recommended Posts

I cant seem to get mod_rewrite to work and do not know how.

Whenever I use software that uses mod_rewrite I go to my website

 

And get this error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

 

Please contact the server administrator, admin@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

 

More information about this error may be available in the server error log.

 

Also I do not know how to get subdomains working on my server either

 

 

Help me please!

Using latest version of uniserver

and using windows vista x64bit ultimate if that helps.

My Website

http://www.djcheezy.com/

 

My Live Radio/Shoutcast Stream (Only active when I have the Shuotcast Server Online)

http://www.djcheezy.com:8000/

Link to comment
Share on other sites

1] mode_rewrite

To get this working you need to add the following line to .htaccess (in folder www):

Options +FollowSymLinks

The following pages may be of use: Installing WordPress and htaccess

 

2] Vhosts

This page is worth a read: Virtual Hosting

 

Easiest way to create a virtual host is to use Apanel

Under Configurations select Admin Virtual Host

 

This opens a new page:

In the text box “Name: (ex. newhost.localhost)” enter the address of your site that’s what a user would type into a browser to access the site e.g www.fred.com

 

In the text box “Path to DocumentRoot: (ex. c:/www/newhost)” enter the path to a folder that you want to make root for that site. The path can be relative or absolute as shown c:/www/newhost. A relative path makes it portable hence use something like /www/fred

 

After clicking Create Vhost, a virtual host entry is create in Apache’s configuration, an entry 127.0.0.1 www.fred.com is created in the hosts file and a new folder created in www named fred (root folder) where you put the site.

 

Note 1: Repeat for each virtual host you wish to create.

 

Note 2: After creating all virtual hosts you must restart the servers for them to become effective.

 

All the best

Ric :unsure:

Link to comment
Share on other sites

The above failed. I tried everything to get it to work.

 

here is my fresh htaccess file Maybe you can edit it for me?

This is for a vbulletin forum plugin vbseo that I need working.

Website:Forum http://awesomecommunity.net/

Forum http://awesomecommunity.net/forum/

 

 

# Comment the following line (add '#' at the beginning)
# to disable mod_rewrite functions.
# Please note: you still need to disable the hack in
# the vBSEO control panel to stop url rewrites.
RewriteEngine On

# Some servers require the Rewritebase directive to be
# enabled (remove '#' at the beginning to activate)
# Please note: when enabled, you must include the path
# to your root vB folder (i.e. RewriteBase /forums/)
#RewriteBase /

#RewriteCond %{HTTP_HOST} !^www\.yourdomain\.com
#RewriteRule (.*) http://www.yourdomain.com/forums/$1 [L,R=301]

RewriteRule ^((urllist|sitemap_).*\.(xml|txt)(\.gz)?)$ vbseo_sitemap/vbseo_getsitemap.php?sitemap=$1 [L]

RewriteCond %{REQUEST_URI} !(admincp/|modcp/|cron|vbseo_sitemap)
RewriteRule ^((archive/)?(.*\.php(/.*)?))$ vbseo.php [L,QSA]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !^(admincp|modcp|clientscript|cpstyles|images)/
RewriteRule ^(.+)$ vbseo.php [L,QSA]

My Website

http://www.djcheezy.com/

 

My Live Radio/Shoutcast Stream (Only active when I have the Shuotcast Server Online)

http://www.djcheezy.com:8000/

Link to comment
Share on other sites

These links show you are not using sub-domains (no www. part)

Website:Forum http://awesomecommunity.net/

Forum http://awesomecommunity.net/forum/

 

The .htaccess file will look like this, note Options +FollowSymLinks must be placed above RewriteEngine On

Enable RewriteCond and RewriteRule use your domain awesomecommunity.com as shown.

# Comment the following line (add '#' at the beginning)
# to disable mod_rewrite functions.
# Please note: you still need to disable the hack in
# the vBSEO control panel to stop url rewrites.
Options +FollowSymLinks
RewriteEngine On

# Some servers require the Rewritebase directive to be
# enabled (remove '#' at the beginning to activate)
# Please note: when enabled, you must include the path
# to your root vB folder (i.e. RewriteBase /forums/)
#RewriteBase /

RewriteCond %{HTTP_HOST} !^awesomecommunity\.com
RewriteRule (.*) http://awesomecommunity.net/forum/$1 [L,R=301]

RewriteRule ^((urllist|sitemap_).*\.(xml|txt)(\.gz)?)$ vbseo_sitemap/vbseo_getsitemap.php?sitemap=$1 [L]

RewriteCond %{REQUEST_URI} !(admincp/|modcp/|cron|vbseo_sitemap)
RewriteRule ^((archive/)?(.*\.php(/.*)?))$ vbseo.php [L,QSA]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !^(admincp|modcp|clientscript|cpstyles|images)/
RewriteRule ^(.+)$ vbseo.php [L,QSA]

Note: There is no need to use Vhosts, use the root folder www and create a sub-folder forum (vBulletin upload folder renamed to forum)

 

All the best

Ric :unsure:

Link to comment
Share on other sites

Ok I will try that.

will reply back once I test it.

 

 

BananaAcid Thanks for the help that worked lol

I thought leaving the # signs activated modules.

My Website

http://www.djcheezy.com/

 

My Live Radio/Shoutcast Stream (Only active when I have the Shuotcast Server Online)

http://www.djcheezy.com:8000/

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...