Page 2 of 2
Re: Pretty URL's for News Category Browse Links?
Posted: Sat Apr 21, 2012 6:37 pm
by Dr.CSS
This "
http://localhost/cmsms/news/2/66/My-Pretty-Page.html is actually what is know as a pretty URL for news...
No you don't have a folder called news, CMSMS doesn't make 'pages' that are in folders, all 'pages' are in the DB
Re: Pretty URL's for News Category Browse Links?
Posted: Sun Apr 22, 2012 9:18 am
by ladyr0gue
Hey Mr. Dr.... thanks 4 replying - yes that is a very pretty url as far as I'm concerned - it was when I clicked on categories in the summary view I was kinda wishing for a nice "
http://localhost/cmsms/news/general/ or general.html instead of the unpretty "
http://localhost/cmsms/index.php?mact=N ... eturnid=66 - having spent about a week trying each and every suggestion I could find in the forums I finally have my answer - it ain't gna happen...
http://forum.cmsmadesimple.org/viewtopi ... 6&p=277737
calguy1000 wrote:There is no code in the News module to handle any category urls in this way.
So even if you can... ...manage to get the links to appear properly, news will not handle them.
http://forum.cmsmadesimple.org/viewtopi ... 20&t=37978
calguy1000 wrote:Once you add parameters like sort order, sorting field, page number, page limit, summary template, detail template (and other parameters that the news and other various modules support for customizing the output) to the url, no matter what you do, it won't be pretty. and besides, usually it's the detail view that's most important anyways... users don't generally care about how ugly the url is to access "the 4th page of all news articles (even expired ones) sorted by author in decending order with 5 items per page", using a different detail template.
News allows you numerous ways to organize the data, just by adding more calls to the module. Making the pagination urls 'pretty' would require removing that flexibility.
the only reason i tried making a subfolder called news was because I also tried what it said here
http://wiki.cmsmadesimple.org/index.php ... stallation For NEWS-Module I had to create a subfolder /news and add a /news/.htaccess:
Code: Select all
Options +FollowSymLinks
RewriteEngine on
RewriteBase /
# Rewrite for NEWS
# requested URL looks like /news/12/13.html rewrite is
# index.php?mact=News,cntnt01,detail,0&cntnt01articleid=12&cntnt01returnid=13
# first number is article, second is returnid; NC = nocase, L=last (rule)
RewriteRule ^([0-9]*).html$ index.php?mact=News,cntnt01,detail,0&cntnt01articleid=$1 [NC,L]
RewriteRule ^([0-9]*)/([0-9]*).html$ index.php?mact=News,cntnt01,detail,0&cntnt01articleid=$1&
cntnt01returnid=$2 [NC,L]
One line for the rule!!
humph. am going away to sulk now

Re: Pretty URL's for News Category Browse Links?
Posted: Sun Apr 22, 2012 5:25 pm
by Dr.CSS
Have you set a default detail page in News admin?...
Re: Pretty URL's for News Category Browse Links?
Posted: Sun Apr 22, 2012 6:07 pm
by ladyr0gue
Dr.CSS wrote:Have you set a default detail page in News admin?...
yes, news page. the detail view was perfect, it was just category view.
Re: Pretty URL's for News Category Browse Links?
Posted: Thu Aug 09, 2012 5:05 pm
by swarfega
Apologies for opening this thread again but I would like to know if the news post url has changed in some way in version 1.11.
I currently use index.php?mact=News,cntnt01,default,0&cntnt01detailpage=59&cntnt01category_id=$1&cntnt01returnid=59.