ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Add icons to entry

October 22, 2009 6:52pm

Subscribe [3]
  • #1 / Oct 22, 2009 6:52pm

    Denidorm

    15 posts

    I’m building a job board with EE. The goal is to let employers fill in the Publish page which I eddited with stuff like ‘discribe the job’ etc. My categories are regions.

    Now, I would like to make it possible to let the employer click on something (+18 and driving licence needed) which would result in 2 small icons next to every title.

    How should I do this?

    thx

  • #2 / Oct 22, 2009 8:31pm

    Bill the Grue

    162 posts

    I guess you could use something like http://brandon-kelly.com/fieldframe field frame. to create custom fields. 

    Then, in your “job display code” you could add conditionals:

    {weblog entries="jobs"}
    
    {summary}
    {body}
    
    {if license != ""}
    (license icon here)
    {/if}
    
    {if over18 != ""}
    (over 18 icon here)
    {/if}
    
    {/weblog:entries}
  • #3 / Oct 23, 2009 2:30am

    Denidorm

    15 posts

    Thanks for the fast reply and the link,
    gonna have a look!
    Looks exactly as what I want.

  • #4 / Oct 23, 2009 6:01am

    Mark Bowen

    12637 posts

    Not wanting to knock the FieldFrame extension as it is a fabulous extension but you could also do this with the standard built-in drop down field type. Just have a drop down for each instance and in them have the words No and Yes (I always place them backwards like that incase I don’t want the icon to appear in most cases and then it doesn’t matter if you forget to select something. Reverse if the opposite though 😉).

    Now you can do this sort of thing :

    {if license == "Yes"}
    license icon here
    {/if}
    
    {if over18 == "Yes"}
    over 18 icon here
    {/if}

    Same sort of thing but with the built-in field types. Again not wanting to knock FieldFrame but if you don’t use it (FieldFrame) for anything else on the site then it might be overkill to install it just for this type of thing.

    Best wishes,

    Mark

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases