Pretty url problem or something else?

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
User avatar
SusanN
Forum Members
Forum Members
Posts: 192
Joined: Wed Jun 13, 2007 5:57 pm

Pretty url problem or something else?

Post by SusanN »

Hello,

I am in the process of moving one of my clients into CMS MS and am experiencing a strange problem. 

Version:  CMS MS 1.2.3
CMS Site:  vir gin iafr eyermu th.com/cms  (please remove the spaces)
Original Site:  same as above minus /cms

The home page works just as expected.  However, I've now added a new page and I can't access it in the browser.  I can preview it in the page editing section, though. 

I've titled the new page "biography".  And the page alias is listed as "biography".  So, I tried vir gin iafr eyermu th.com/cms/biography and the only thing I get is an unstyled version of the original site's home page.  I know it's the original version by looking at the source code - the doctype is HTML and not XHTML.

My config.php file contains this:

Code: Select all

#------------
#URL Settings
#------------

#Show mod_rewrite URLs in the menu? You must enable 'use_hierarchy' for this to work for modules
$config['assume_mod_rewrite'] = true;

#Extension to use if you're using mod_rewrite for pretty URLs.
$config['page_extension'] = '/';

#If you don't use mod_rewrite, then would you like to use the built-in
#pretty url mechanism?  This will not work with IIS and the {metadata} tag
#should be in all of your templates before enabling.
$config['internal_pretty_urls'] = false;

#If you're using the internal pretty url mechanism or mod_rewrite, would you like to
#show urls in their hierarchy?  (ex. http://www.mysite.com/parent/parent/childpage)
$config['use_hierarchy'] = false;

#If using none of the above options, what should we be using for the query string
#variable?  (ex. http://www.mysite.com/index.php?page=somecontent)
$config['query_var'] = 'page';
My .htaccess contains this:

Code: Select all

Options +FollowSymLinks
RewriteEngine on
RewriteBase /

# 301 Redirect all requests that don't contain a dot or trailing slash to
# include a trailing slash
RewriteCond %{REQUEST_URI} !/$
RewriteCond %{REQUEST_URI} !\.
RewriteRule ^(.*) %{REQUEST_URI}/ [R=301,L]

# Rewrites urls in the form of /parent/child/
# but only rewrites if the requested URL is not a file or directory
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteCond %{REQUEST_FILENAME} !-d [NC]
RewriteRule ^(.+)$ index.php?page=$1 [QSA]
Both my config.php and .htaccess files reside in the /cms directory.


So, I have no idea why I can't view the biography page's content in the browser.  Do you see my mistake?

Thanks!
Wiedmann
Forum Members
Forum Members
Posts: 233
Joined: Wed Mar 26, 2008 1:49 am

Re: Pretty url problem or something else?

Post by Wiedmann »

Code: Select all

RewriteBase /
Both my config.php and .htaccess files reside in the /cms directory.
Don't use RewriteBase if the directory "cms" is a subdirectory of your DocumentRoot, or use "RewriteBase /cms"
User avatar
SusanN
Forum Members
Forum Members
Posts: 192
Joined: Wed Jun 13, 2007 5:57 pm

Re: Pretty url problem or something else?

Post by SusanN »

Thank you for your quick reply!!  It works now!  :)
Post Reply

Return to “CMSMS Core”