Matching up class and current object class [SOLVED]

Matching up class and current object class [SOLVED]

Monday 11 October 2010 5:05:34 am - 2 replies

Modified on Monday 11 October 2010 12:55:10 pm by Lo' F.

Author Message

Lo' F.

Monday 11 October 2010 5:57:04 am

I maybe got the actual class name to match..

{def $class=fetch('content', 'class', hash('class_id', 35))}
{if ...|eq($class.name)}
...

yet missing the current one..

loredanaebook.it

Lo' F.

Monday 11 October 2010 12:54:50 pm

..and got it!

{def $class=fetch('content', 'class', hash('class_id', 35))}
{if $module_result[content_info][class_id]|eq($class.id)}
{literal}
<script type="text/javascript">
   ...
</script>
{/literal}
{/if}

Used id instead of name since the latter returned the name of the class one with the first letter in capital and the other not.. so chose this way as a shortcut..

loredanaebook.it

You must be logged in to post messages in this topic!

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.