Search Engine Optimistaion - Pretty URLs

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.
Locked
jameshontishar

Search Engine Optimistaion - Pretty URLs

Post by jameshontishar »

How do i achieve SEO and Pretty URLs.

I have tried adding a .htaccess file and editing the config.php but then my site breaks and clues

Thanks in Advance

James
cyberman

Re: Search Engine Optimistaion - Pretty URLs

Post by cyberman »

Can you post your htaccess file and tell us something more about your config.php changes :) ?
Homersbrain

Re: Search Engine Optimistaion - Pretty URLs

Post by Homersbrain »

I've been having the same problem, but it's now fixed. Turned out to be the editor I was using. I use a mac but ended up using Notepad on a PC to edit it. Don't use frontpage or anything like that. Also, make sure you are FTPing it using ascii or auto mode (not binary).

Mike
jameshontishar

Re: Search Engine Optimistaion - Pretty URLs

Post by jameshontishar »

Here is an edited config.php file

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1
Global Settings in the admin panel)
#after making any changes to path or url related options

#-----------------
#Database Settings
#-----------------

#If app needs to coexist with other tables in the same db,
#put a prefix here.  e.g. "cms_"
$config['db_prefix'] = 'tulip_';

#Use persistent connections?  They're generally faster, but not all hosts
#allow them.
$config['persistent_db_conn'] = false;

#Use ADODB Lite?  This should be true in almost all cases.  Note, slight
#tweaks might have to be made to date handling in a "regular" adodb
#install before it can be used.
$config['use_adodb_lite'] = true;

#-------------
#Path Settings
#-------------

#Document root as seen from the webserver.  No slash at the end
#e.g. http://blah.com
$config['root_url'] = 'http://www.demo.cleardesignstudio.co.uk';

#Path to document root. This should be the directory this file is in.
#e.g. /var/www/localhost
$config['root_path'] = '/home/fhlinux182/d/demo.cleardesignstudio.co.uk/user/htdocs';

#Name of the admin directory
$config['admin_dir'] = 'admin';

#Where do previews get stored temporarily?  It defaults to tmp/cache.
$config['previews_path'] = '/home/fhlinux182/d/demo.cleardesignstudio.co.uk/user/htdocs/tmp/cache';

#Where are uploaded files put?  This defaults to uploads.
$config['uploads_path'] = '/home/fhlinux182/d/demo.cleardesignstudio.co.uk/user/htdocs/uploads';

#Where is the url to this uploads directory?
$config['uploads_url'] = 'http://www.demo.cleardesignstudio.co.uk/uploads';

#---------------
#Upload Settings
#---------------

#Maxium upload size (in bytes)?
$config['max_upload_size'] = 20000000;

#Permissions for uploaded files.  This only really needs changing if your
#host has a weird permissions scheme.
$config['default_upload_permission'] = '664';

#------------------
#Usability Settings
#------------------

#Allow smarty {php} tags?  These could be dangerous if you don't trust your users.
$config['use_smarty_php_tags'] = false;

#CMSMS Debug Mode?  Turn is on to get a better error when you
#see {nocache} errors.
$config['debug'] = false;

#Automatically assign alias based on page title?
$config['auto_alias_content'] = true;

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

$config['assume_mod_rewrite'] = true;

$config['page_extension'] = '/';

$config['use_hierarchy'] = true;

#--------------
#Image Settings
#--------------

#Which program should be used for handling thumbnails in the image manager.
#See http://wiki.cmsmadesimple.org/index.php ... ge_Manager for more
#info on what this all means
$config['image_manipulation_prog'] = 'GD';
$config['image_transform_lib_path'] = '/usr/bin/ImageMagick/';

#Default path and URL for uploaded images in the image manager
$config['image_uploads_path'] = '/home/fhlinux182/d/demo.cleardesignstudio.co.uk/user/htdocs/uploads/images';
$config['image_uploads_url'] = 'http://www.demo.cleardesignstudio.co.uk/uploads/images';

#------------------------
#Locale/Encoding Settings
#------------------------

#Locale to use for various default date handling functions, etc.  Leaving
#this blank will use the server's default.  This might not be good if the
#site is hosted in a different country than it's intended audience.
$config['locale'] = '';

#In almost all cases, default_encoding should be empty (which defaults to utf-8)
#and admin_encoding should be utf-8.  If you'd like this to be different, change
#both.  Keep in mind, however, that the admin interface translations are all in
#utf-8, and will be converted on the fly to match the admin_encoding.  This
#could seriously slow down the admin interfaces for users.
$config['default_encoding'] = '';
$config['admin_encoding'] = 'utf-8';

#---------------------------------------------
#Use the old stylesheet logic?  It's much slower, but it works with older
#versions of CMSMS.  You'll also need this set to true if there is a module
#that uses a stylesheet callback.  Leave it as false instead you really
#need it.
$config['old_stylesheet'] = false;

# URL of the Admin Panel section of the User Handbook
$config['wiki_url'] = 'http://wiki.cmsmadesimple.org/index.php ... dmin_Panel';

#Enable backwards compatibility mode?  This basically will allow some
#modules written before 1.0 was released to work.  Keep in mind that this
#will use a lot more memory and isn't guaranteed to fix the problem.
$config['backwards_compatible'] = false;

#Not used anymore... kept around, just in case
$config['disable_htmlarea_translation'] = false;
$config['use_Indite'] = true;
?>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


Here is the .htaccess

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]

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!11
jameshontishar

Re: Search Engine Optimistaion - Pretty URLs

Post by jameshontishar »

It says internal server error etc etc
jameshontishar

Re: Search Engine Optimistaion - Pretty URLs

Post by jameshontishar »

Homersbrain wrote: I've been having the same problem, but it's now fixed. Turned out to be the editor I was using. I use a mac but ended up using Notepad on a PC to edit it. Don't use frontpage or anything like that. Also, make sure you are FTPing it using ascii or auto mode (not binary).

Mike
No Change
cyberman

Re: Search Engine Optimistaion - Pretty URLs

Post by cyberman »

Can you give an example how URL should be shown?
jameshontishar

Re: Search Engine Optimistaion - Pretty URLs

Post by jameshontishar »

not sure just trying to make my site seo friendly, but assume i need to do this after reading every other post on seo pretty urls
swgreed

Re: Search Engine Optimistaion - Pretty URLs

Post by swgreed »

jameshontishar wrote: It says internal server error etc etc
Try removing the line

Code: Select all

Options +FollowSymLinks
junito
Forum Members
Forum Members
Posts: 28
Joined: Fri Oct 27, 2006 5:07 pm

Re: Search Engine Optimistaion - Pretty URLs

Post by junito »

I had such a problem... htaccess was not enabled on my server.
You need to check the apache configuration file and see if you have a line with "AllowOverride All". If not your problem may be there...
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am

Re: Search Engine Optimistaion - Pretty URLs

Post by Elijah Lofgren »

jameshontishar wrote: It says internal server error etc etc
If you can, try checking the server error log. You can do this through Cpanel if you have it. That will help narrow down the problem.
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
Pierre M.

Re: Search Engine Optimistaion - Pretty URLs

Post by Pierre M. »

Here are some tests to narrow down the problem :
http://forum.cmsmadesimple.org/index.ph ... l#msg43943
Hope it helps.

PM
Locked

Return to “CMSMS Core”