Hallo,
ich versuche seit Tagen die URLs meiner Seite zu verbessern.
Also die URLs sehen jetzt so aus:
http://www.domain.com/index.php?page=PC&pg=1&ukat=ab1
Haben möchte ich: http://www.domain.com/PC/1/ab1.htm
Im Moment kriege ich nur das:
http://www.domain.com/PC.htm&pg=1&ukat=ab1
Also wird ja schon mal was umgeschrieben. Aber wie mache ich es, dass ich das richtige Ergebnis kriege?
Hier mal meine Config.php vom CMSMS:
#------------
#URL Settings
#------------
#What type of URL rewriting should we be using for pretty URLs? Valid options are:
#‚none‘, ‚internal‘, and ‚mod_rewrite‘. ‚internal‘ will not work with IIS some CGI
#configurations. ‚mod_rewrite‘ requires proper apache configuration, a valid
#.htaccess file and most likely {metadata} in your page templates. For more
#information, see:
#http://wiki.cmsmadesimple.org/index.php/FAQ/Installa…
$config[‚url_rewriting‘] = ‚mod_rewrite‘;
#Extension to use if you’re using mod_rewrite for pretty URLs.
$config[‚page_extension‘] = ‚.htm‘;
Und hier die htaccess:
Attempt to override some php settings, these settings may be helpful on some hosts if your
default configuration does not meet CMS’s minimum requirements, and your host
has given your account appropriate permissions
#php_value upload_max_filesize „10M“
#php_value session_save_path „tmp/cache“
#php_flag magic_quotes_gpc Off
#php_flag register_globals Off
#php_flag session.use_trans_sid Off
(this is important, so uncomment if your host permit)
#Options -Indexes
#ServerSignature Off
#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
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+).htm$ index.php?page=$1 [QSA]
Bitte helft mir mal…
Danke.
Mfg
Torsten