CMS MADE SIMPLE FORGE

News Module

 

[#3203] Improvement about the module "news"

avatar
Created By: Lionel Maccaud (lionel)
Date Submitted: 2009-03-25 18:23

Assigned To:
Resolution: Won't Fix
State: Closed
Summary:
Improvement about the module "news"
Detailed Description:
I will propose an improvement about the module "news". It would be interesting
to be able to modify the design of a post according to the category. For example
: my post in the category “Water” have a blue border and those of the “Natural”
category have a green border. In this way, there would be a field “Add CSS
class” for each category.


my category: Water
my class: water

<div class="NewsSummary" class="water"> ...

So we can draw each category differently.

History

Comments
avatar
Date: 2009-03-26 07:00
Posted By: Ronny Krijt (ronnyk)

What is different on the logic, that you can already use in the styling, by
putting something like .....

<div class="NewsSummary" class="{$entry->category}" >

to your summary template.

That will do the same, or am I missing something?
      
avatar
Date: 2009-03-26 09:16
Posted By: Lionel Maccaud (lionel)

I thought of this solution. But there are several problems. In English for
example:

If my category is “cats and dogs”, my class will be “cats and dogs” also but
interpreted by CSS like

class= "cats and dogs” - > class= "cats” + class= "and” + class= "dogs”

In French it's more complicated with the accents:

For example:

Category = télévision
class="télévision” -> that generates a bug

The best way is that we can write the category that we would like

There will be no problem of interpretation with the CSS

What do you think about it?
      
avatar
Date: 2009-03-26 10:28
Posted By: Robert Campbell (calguy1000)

This is not a news specific issue
there are many ways to do this.
      
Updates

Updated: 2012-04-15 00:17
state: Open => Closed

Updated: 2009-03-26 10:27
resolution_id: 10 => 8

Updated: 2009-03-26 07:00
resolution_id: => 10