1
I have some time ago asked how to port a script to XOOPS and was told to try ModGen. So I did, but for some reason I can't get the blocks to work right (at all even).
My module, however undone it is as it is not finished, can be downloaded here. As I said it isn't done but you'll probably get the idea.
rotator moduleAll I really want is to have the preview.php in a block on the front page, eighter as an iframe or better as the script found in preview.php
The Preview.php can be seen here alson.
$dagenidag = date("w");
$nydagenidag = $dagarr[date("w")];
$tidnu = date("H:i:s");
$nextevent = date("H:i:s",strtotime("+1 minutes"));
$resultnext = mysql_query("SELECT * FROM xoops_dj_dj WHERE 'djstart' > '$tidnu' AND '$dagenidag' = djdag LIMIT 1") or die(mysql_error());
while($nextnow = mysql_fetch_array($resultnext))
{
$id = $nextnow['id'];
$djtitel = stripslashes2($nextnow['djtitel']);
$djname = stripslashes2($nextnow['djname']);
$djstation = stripslashes2($nextnow['djstation']);
$djbeskrivelse = stripslashes2($nextnow['djbeskrivelse']);
$nextmarquee= "<MARQUEE DIRECTION=Left BEHAVIOR=SCROLL SCROLLAMOUNT=10 SCROLLDELAY=400>"._AM_DJ_scripttextnext.$nextnow['djstart']._AM_DJ_breaker.$nextnow['djslut']." ".stripslashes2($nextnow['djtitel']).$marqueewith." ".stripslashes2($nextnow['djname'])." </marquee>";
}
$resultshow = mysql_query("SELECT * FROM xoops_dj_dj WHERE ('$tidnu' BETWEEN djstart AND djslut) AND '$dagenidag' = djdag") or die(mysql_error());
while($now = mysql_fetch_array($resultshow))
{
$id = $now['id'];
$djtitel = stripslashes2($now['djtitel']);
$djname = stripslashes2($now['djname']);
$djstation = stripslashes2($now['djstation']);
$djbeskrivelse = stripslashes2($now['djbeskrivelse']);
echo "<table width=200 border=0 align=center>
<tr>
<bgcolor=#FF0000><center><font color=#000000 face=Verdana size=1>"."<br><br><strong><font size=1>"._AM_DJ_ligenupåstation.stripslashes2($now['djstation'])."<br></strong></bgcolor><font size=1>".stripslashes2($now["djtitel"])."<br>".'<a href="javascript://" onclick="window.open('preview2.php?mode=info&id='.$now[id].'',null,'height=500,width=550,status=no,toolbar=no,menubar=no,location=no,left=0,top=0')"><img src="images/shots/thumbs/'.$now['djbillede'].'" width="100" height="120" alt="".$now[djnavn]." border="0"></a><br>'.stripslashes2($now["djname"])."<br></a><br>".$nydagenidag."<br>".$now['djstart']." to ".$now['djslut']."<td><br><td><br><br>".$nextmarquee."</center></tr>
</td></table>";
}
Anyone can give me an idea as to what I am doing wrong ?
Programming is like sex:
One mistake and you have to support it for the rest of your life.