I see that I can put a reference to an object, inside the <%= %> tag.


        I can do something like:


                <%=  currentNode.orderNumber %>


        But I want to be able to print a field only if it's defined. 

        For example, Address, an address can have two lines, currentNode.line1
        and possibly currentNode.line2

        I want to have the second line print if it's present but only if it has 
a non zero length..

        Currently I have
                <p>
                        <%= currentNode.line1 %><br/>
                        <%= currentNode.line1 %><br/>
                        <%= currentNode.town %><br/>
                </p>


and I get entries like:


                5 Middle St
                undefined
                New York

It does't seem to be possible to put arbitrary java script commands between 
those delimiters.


Any suggestions?



Reply via email to