News Module custom fields

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
chriggi
New Member
New Member
Posts: 5
Joined: Wed Nov 11, 2009 5:33 pm

News Module custom fields

Post by chriggi »

Hello everybody,

I have a website where I want to display news on the front page and news on another page called "news". (same website)
I have got this working without any problems.

Now I would prefer to only have some "special" news displayed on the homepage and all news on the "news" page. Is this possible? I could imagine doing this by adding a custom field like "special: true/false", and then somehow only fetch the news on the homepage where this field special == true.

Is this the right way?

Thanks for reading!
Regards
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: News Module custom fields

Post by velden »

What about the use of categories for that? Then you don't have to add a field, plus it should be more efficient.
(optional) category="category" - Used in the summary view to display only items for the specified categories. Use * after the name to show children. Multiple categories can be used if separated with a comma. Leaving empty, will show all categories. This parameter also works for the frontend submit action, however only a single category name is supported.
chriggi
New Member
New Member
Posts: 5
Joined: Wed Nov 11, 2009 5:33 pm

Re: News Module custom fields

Post by chriggi »

Perfect! Didn't come to my mind. Thanks for that!
Greets
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Contact:

Re: News Module custom fields

Post by Rolf »

chriggi wrote:Perfect!
Solved? Please add [solved] to the title of the first post
http://forum.cmsmadesimple.org/viewtopi ... =8&t=13968
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
Post Reply

Return to “CMSMS Core”