1
Hi,
I am currently designing a theme but have some difficulties with putting random image into the header.
I wanted to use a simple php command to make the <img> tag's src value but it failed. Guess it somehow related to smarty but now I am stucked.
I tried to insert my command into the theme.html as follows:
<script type="text/php">
<!--
print ('<img src="<{$xoops_imageurl}>images/bg'.rand(1,6).'.jpg >"');
//-->
</script>
and like this
<?php print ('<img src="<{$xoops_imageurl}>images/bg'.rand(1,6).'.jpg >"'); ?>
but none of them worked
If I check the source of the page what XOOPS generated I see the php command in it, so it is wrong.
Does anybody know how to solve this?
Any idea should be appreciated, thx in advance.