I have something like:

```
{if !(strstr(substr($firstsub.url_add,-4), '.jpg'))}
<b><a href="{$firstsub.url_add}" target="_blank">{$firstsub.url_add}</a></b>
{/if}

```

But how to add also .gif, .jpeg others... I mean if .jpg OR .gif OR .jpeg then show the link.
Of course if $firstsub.url\_add contains .jpg, OR .gif extension, I wanna to show the link.

If I use this:

```
{if !(strstr(substr($firstsub.url_add,-4), '.jpg')) || !(strstr(substr($firstsub.url_add,-4), '.gif'))}
<b><a href="{$firstsub.url_add}" target="_blank">{$firstsub.url_add}</a></b>
{/if}

```

system understand this like AND.
Please help :)