Jump to content

What is the best way of inserting an if statement here?


the5thace

Recommended Posts

Some of the search results have snippets and some do not so I need an if statement inserted for the cases there aren't any.

Seems that when I try to insert an if statement it gets picked up as html. What would be the best way to insert an if here? 

 

$Blekko = array ("<a href=\"{$item->url}\"> 
                {$item->url_title}</a>     
                <p> {if (snippet == '')
                { 
                $item->'No snippet'
                }
                $item->snippet}</p>")
                }

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.