przyjazny URL, problemy

Pomoc po polsku dla CMS Made Simple
Post Reply
korneliusz
Forum Members
Forum Members
Posts: 15
Joined: Wed Oct 28, 2009 10:22 am

przyjazny URL, problemy

Post by korneliusz »

czesc

mam kilka problemow z tymi przyjaznymi URLami

strone trzymam w podkatalogu cmssimple

./
--/cmssimple

plik htaccess

Code: Select all

  Options +FollowSymLinks
  RewriteEngine on
  RewriteBase /cmssimple
 
  # 301 Redirect all requests that don't contain a dot or trailing slash to
  # include a trailing slash
  # except for form POSTS
  RewriteCond %{REQUEST_URI} !/$
  RewriteCond %{REQUEST_URI} !\.
  RewriteCond %{REQUEST_METHOD} !POST$
  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 ^(.+)$ index.php?page=$1 [QSA]
plik config.php

Code: Select all

#------------
#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/Installation/Pretty_URLs#Pretty_URL.27s
$config['url_rewriting'] = 'mod-rewrite';

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

#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';

#$config['url_rewriting'] = 'mod_rewrite'; // this is new from 1.6
#$config['page_extension'] = '.html';
#$config['use_hierarchy'] = true; // this will be the standard from 1.7
#$config['query_var'] = 'page';
#$config['internal_pretty_urls'] = false;
$config['assume_mod_rewrite'] = true;
przyjazne URLe dzialaja

http://www.nazwastrony.pl/cmssimple/o-nas

ale linki w menu generuja sie w postaci
http://www.nazwastrony.pl/cmssimple/ind ... s&hl=pl_PL

dlaczego ?



ale jest gorszy problem
przyjazne URLe w newsach ...

przy wlaczonym $config['url_rewriting'] = 'mod-rewrite'; adresy newsow wygladaja w kosmicznej postaci

Code: Select all

index.php?mact=News,cntnt01,detail,0&cntnt01articleid=1&cntnt01origid=74&cntnt01returnid=83&hl=pl_PL
???

przy wlaczonym $config['url_rewriting'] = 'internal'; jest lepiej ale tez cos nie tak
index.php/pl_PL/news/1/83/temat-wiadomosci/

natomiast przy zadnym z tych dwoch ustawien nie dziala dla Newsow adres w postaci
http://www.nazwastrony.pl/temat-wiadomosci/
Last edited by korneliusz on Wed Jan 20, 2010 11:30 am, edited 1 time in total.
User avatar
korpirkor
Forum Members
Forum Members
Posts: 100
Joined: Sun Oct 28, 2007 1:15 pm
Location: Poland, Warsaw

Re: przyjazny URL, problemy

Post by korpirkor »

Co do linków generowanych przez menu: Prawdopodobnie jest to wina modułu wielojęzyczności, który doinstalowałeś.

Co newsów: przeszukaj tematy w dziale Tips and Tricks. Ja znalazłem to: http://forum.cmsmadesimple.org/index.php?topic=24968.0
[url=http://www.polishwebdesign.pl/]Polish WebDesign Cezary Nowak
Projektowanie stron WWW[/ur]
camillo
New Member
New Member
Posts: 2
Joined: Fri May 07, 2010 1:31 pm

Re: przyjazny URL, problemy

Post by camillo »

#configurations. 'mod_rewrite' requires proper apache configuration, a valid
a Ty wpisałeś:
$config['url_rewriting'] = 'mod-rewrite';
widzisz różnice?
Post Reply

Return to “Polish - Polski”