[exhibit] How 'remove' function works

View: New views
2 Messages — Rating Filter:   Alert me  

[exhibit] How 'remove' function works

by mikima :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

hi to all
i'm using exhibit for an univeristy project.
i want that if a property has a value, exhibit print a sting, but if the property has no value; exhibit show nothing.
To be more clear i post the code i've wrote:


<div class="title"
       ex:content="if(exists(.platform), 'This item is part of:', '')"></div>

        <div class="text"
               ex:content=".platform"></div>


In this way, if .platform has no value, exhibit put an empty line, and i don't want this.

i hope to have explained my problem (i'm not so good with english).
What can i do? there is a solution? i've seen that there is a function 'remove', but i didn't understand how it works.

thanks
michele

Re: [exhibit] How 'remove' function works

by David Karger :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Here is in easier way:

<div ex:if-exists=".platform">This item is part of: <span
ex:content=".platform"></span></div>

mikima wrote:

> hi to all
> i'm using exhibit for an univeristy project.
> i want that if a property has a value, exhibit print a sting, but if the
> property has no value; exhibit show nothing.
> To be more clear i post the code i've wrote:
>
>
> <div class="title"
>        ex:content="if(exists(.platform), 'This item is part of:',
> '')"></div>
>
>         <div class="text"
>                ex:content=".platform"></div>
>
>
> In this way, if .platform has no value, exhibit put an empty line, and i
> don't want this.
>
> i hope to have explained my problem (i'm not so good with english).
> What can i do? there is a solution? i've seen that there is a function
> 'remove', but i didn't understand how it works.
>
> thanks
> michele
>
>  
_______________________________________________
General mailing list
General@...
http://simile.mit.edu/mailman/listinfo/general