2013-05-07 14:20:08 -04:00
< ?
$which = $_REQUEST [ 'which' ];
require ( " include/top.php " );
require ( " include/libbb.php " );
require ( " include/awardscategories.inc.php " );
2013-05-07 20:22:01 -04:00
if ( $_COOKIES ) foreach ( $_COOKIES as $key => $val )
{
2013-05-07 14:20:08 -04:00
$trimmedKey = trim ( key );
if ( $trimmedKey != $key )
$_COOKIES [ $trimmedKey ] = $val ;
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
}
$query = " SELECT MAX(id) FROM prods " ;
$result = mysql_query ( $query );
$maxid = mysql_result ( $result , 0 );
$query = " SELECT * FROM prods " ;
if (( ! $which ) || ( $which > $maxid )) {
$query .= " ORDER BY RAND() " ;
} else {
$query .= " WHERE id= " . ( int ) $which . " " ;
}
$query .= " LIMIT 1 " ;
$result = mysql_query ( $query );
$prod = mysql_fetch_array ( $result );
if (( ! $which ) || ( $which > $maxid )) {
$which = $prod [ " id " ];
}
$which = ( int ) $which ;
$query = " SELECT nickname,avatar FROM users WHERE id= " . $prod [ " added " ];
$result = mysql_query ( $query );
2013-05-07 20:21:48 -04:00
if ( $result )
{
$tmp = mysql_fetch_array ( $result );
$prod [ " nickname " ] = $tmp [ " nickname " ];
$prod [ " avatar " ] = $tmp [ " avatar " ];
}
2013-05-07 14:20:08 -04:00
if ( $prod [ " party " ])
{
$query = " SELECT name FROM parties WHERE id= " . $prod [ " party " ];
$result = mysql_query ( $query );
$prod [ " partyname " ] = mysql_result ( $result , 0 );
}
if ( $prod [ " invitation " ])
{
$query = " SELECT name FROM parties WHERE id= " . $prod [ " invitation " ];
$result = mysql_query ( $query );
$prod [ " invitationpartyname " ] = mysql_result ( $result , 0 );
}
if ( $prod [ " boardID " ])
{
$query = " SELECT name FROM bbses WHERE id= " . $prod [ " boardID " ];
$result = mysql_query ( $query );
$prod [ " boardname " ] = mysql_result ( $result , 0 );
}
if ( isset ( $prod [ " party_year " ]))
{
$pyear = $prod [ " party_year " ];
}
if ( isset ( $prod [ " invitationyear " ]))
{
$piyear = $prod [ " invitationyear " ];
}
if ( $prod [ " group1 " ])
{
$query = " SELECT name,web,acronym FROM groups WHERE id= " . $prod [ " group1 " ];
$result = mysql_query ( $query );
$tmp = mysql_fetch_array ( $result );
$prod [ " groupname1 " ] = $tmp [ " name " ];
$prod [ " groupweb1 " ] = $tmp [ " web " ];
$prod [ " groupa1 " ] = $tmp [ " acronym " ];
}
if ( $prod [ " group2 " ])
{
$query = " SELECT name,web,acronym FROM groups WHERE id= " . $prod [ " group2 " ];
$result = mysql_query ( $query );
$tmp = mysql_fetch_array ( $result );
$prod [ " groupname2 " ] = $tmp [ " name " ];
$prod [ " groupweb2 " ] = $tmp [ " web " ];
$prod [ " groupa2 " ] = $tmp [ " acronym " ];
}
if ( $prod [ " group3 " ])
{
$query = " SELECT name,web,acronym FROM groups WHERE id= " . $prod [ " group3 " ];
$result = mysql_query ( $query );
$tmp = mysql_fetch_array ( $result );
$prod [ " groupname3 " ] = $tmp [ " name " ];
$prod [ " groupweb3 " ] = $tmp [ " web " ];
$prod [ " groupa3 " ] = $tmp [ " acronym " ];
}
$query = " SELECT prodotherparty.party, prodotherparty.party_place, prodotherparty.party_year, prodotherparty.partycompo, parties.name FROM prodotherparty LEFT JOIN parties ON parties.id=prodotherparty.party WHERE prod= " . $prod [ " id " ];
$result = mysql_query ( $query );
2013-05-07 20:21:48 -04:00
if ( $result )
{
while ( $tmp = mysql_fetch_array ( $result )) {
$prodotherparties [] = $tmp ;
}
}
2013-05-07 14:20:08 -04:00
$query = " select platforms.name, platforms.icon from prods_platforms, platforms where prods_platforms.prod=' " . $which . " ' and platforms.id=prods_platforms.platform " ;
$result = mysql_query ( $query );
while ( $tmp = mysql_fetch_array ( $result )) {
$platforms [] = $tmp ;
}
for ( $i = 0 ; $i < count ( $platforms ); $i ++ )
2013-05-07 20:22:01 -04:00
{
2013-05-07 14:20:08 -04:00
if ( $platforms [ $i ] == " Commodore 64 " ) $check64 = 1 ;
if ( $platforms [ $i ] == " C64 DTV " ) $check64 = 1 ;
if ( $platforms [ $i ] == " ZX Spectrum " ) $checkzx = 1 ;
}
// popularity
function CheckReferrer ( $ref ) {
global $which ;
//if ($which == 55991 || $which == 55471) return false;
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
$myurl = parse_url ( $ref );
if ( strstr ( $myurl [ " host " ], " farb-rausch.de " )) return false ;
if ( strstr ( $myurl [ " host " ], " flipcode.com " )) return false ;
if ( strstr ( $myurl [ " host " ], " 0ccult.de " )) return false ;
if ( strstr ( $myurl [ " host " ], " ypocamp.fr " )) return false ;
if ( strstr ( $myurl [ " host " ], " chanka.emulatronia.com " )) return false ;
if ( strstr ( $myurl [ " host " ], " images.google " )) return false ;
if ( strstr ( $myurl [ " host " ], " urlreload " )) return false ;
if ( strlen ( $ref ) < 2 ) return false ;
return true ;
}
2013-05-13 23:04:17 +02:00
$currentip = $_SERVER [ 'REMOTE_ADDR' ];
2013-05-13 23:05:51 +02:00
if ( $prod [ " latestip " ] != $currentip && CheckReferrer ( $_SERVER [ 'HTTP_REFERER' ]) ) {
//print("im about to add another view because my ref is ".$_SERVER['HTTP_REFERER']." have a nice day!!");
2013-05-07 20:22:01 -04:00
mysql_query ( " UPDATE prods SET views=views+1,latestip=' " . $currentip . " ' WHERE id= " . $prod [ " id " ]);
2013-05-07 14:20:08 -04:00
}
$result = mysql_query ( " SELECT MAX(views) FROM prods " );
$max_views = mysql_result ( $result , 0 );
// popularity
// comments begin
if ( ! isset ( $howmanycomments )) $howmanycomments = 25 ;
$comments_per_page = $howmanycomments ;
if ( $comments_per_page != 0 ){
// get nb of comments
$result = mysql_query ( " SELECT count(0) FROM comments WHERE comments.which=' " . $prod [ " id " ] . " ' " );
$nb_comments = mysql_result ( $result , 0 );
// if ($comments_per_page < 0) $comments_per_page = $nb_comments;
if ( ! isset ( $page )) $page = floor ( $nb_comments / $comments_per_page );
if ( $page == ( $nb_comments / $comments_per_page )) $page -- ;
$comments_offset = $page * $comments_per_page ;
// get the comments and the associated data
$query = " SELECT comments.id,comments.comment,comments.rating,comments.who,comments.quand,users.nickname,users.avatar,users.level FROM comments,users WHERE comments.which=' " . $prod [ " id " ] . " ' AND users.id=comments.who ORDER BY comments.quand ASC " ;
if ( $comments_per_page >= 0 )
$query .= " LIMIT $comments_offset , $comments_per_page " ;
// print ($query);
$result = mysql_query ( $query );
2013-05-07 20:21:48 -04:00
if ( $result )
{
while ( $tmp = mysql_fetch_array ( $result )) {
$comments [] = $tmp ;
}
}
2013-05-07 14:20:08 -04:00
}
$query = " SELECT * from users_cdcs where users_cdcs.cdc=' " . $prod [ " id " ] . " ' " ;
$result = mysql_query ( $query );
while ( $tmp = mysql_fetch_array ( $result )) {
$cdcs [] = $tmp ;
}
for ( $j = 0 ; $j < count ( $cdcs ); $j ++ )
{
for ( $i = 0 ; $i < count ( $comments ); $i ++ )
{
if ( $cdcs [ $j ][ " user " ] == $comments [ $i ][ " who " ]){
$comments [ $i ][ " cdc " ] = $cdcs [ $j ][ " cdc " ];
}
}
}
$query = " SELECT * from users_cdcs left join comments on users_cdcs.user=comments.who AND users_cdcs.cdc = comments.which where users_cdcs.cdc=' " . $prod [ " id " ] . " ' and comments.id IS NULL " ;
$result = mysql_query ( $query );
while ( $tmp = mysql_fetch_object ( $result )) {
$othercdc [] = $tmp -> user ;
}
// comments end
if ( $prod [ " id " ])
{
//cdc count
$result = mysql_query ( " SELECT count(0) from users_cdcs where cdc= " . $prod [ " id " ]);
$prod [ " cdc " ] = mysql_result ( $result , 0 );
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
$result = mysql_query ( " SELECT count(0) from cdc where which= " . $prod [ " id " ]);
$prod [ " cdc " ] = $prod [ " cdc " ] + mysql_result ( $result , 0 );
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
//sceneorgrecommended check
$result = mysql_query ( " SELECT * from sceneorgrecommended where prodid= " . $prod [ " id " ] . " ORDER BY type " );
while ( $tmp = mysql_fetch_array ( $result )) {
$sceneorgrecommends [] = $tmp ;
}
//affiliated prods
$result = mysql_query (
" SELECT affiliatedprods.type as type, " .
" affiliatedprods.derivative as derivative, " .
" affiliatedprods.original as original, " .
" prods.name as name " .
" from affiliatedprods " .
" join prods on prods.id=affiliatedprods.original " .
" where affiliatedprods.derivative= " . $prod [ " id " ] . " ORDER BY affiliatedprods.type " );
while ( $tmp = mysql_fetch_array ( $result )) {
$tmp [ " prod " ] = " original " ;
$affils [] = $tmp ;
}
$result = mysql_query (
" SELECT affiliatedprods.type as type, " .
" affiliatedprods.derivative as derivative, " .
" affiliatedprods.original as original, " .
" prods.name as name " .
" from affiliatedprods " .
" join prods on prods.id=affiliatedprods.derivative " .
" where affiliatedprods.original= " . $prod [ " id " ] . " ORDER BY affiliatedprods.type " );
while ( $tmp = mysql_fetch_array ( $result )) {
$tmp [ " prod " ] = " derivative " ;
$affils [] = $tmp ;
}
$query = " SELECT downloadlinks.id,downloadlinks.link,downloadlinks.type FROM downloadlinks WHERE downloadlinks.prod= " . $prod [ " id " ] . " ORDER BY downloadlinks.type " ;
$result = mysql_query ( $query );
while ( $tmp = mysql_fetch_array ( $result )) {
$dl [] = $tmp ;
}
}
if ( file_exists ( " screenshots/ " . $prod [ " id " ] . " .jpg " )) {
$shotpath = " screenshots/ " . $prod [ " id " ] . " .jpg " ;
} elseif ( file_exists ( " screenshots/ " . $prod [ " id " ] . " .gif " )) {
$shotpath = " screenshots/ " . $prod [ " id " ] . " .gif " ;
} elseif ( file_exists ( " screenshots/ " . $prod [ " id " ] . " .png " )) {
$shotpath = " screenshots/ " . $prod [ " id " ] . " .png " ;
}
?>
< br />
< ? if ( count ( $prod ) > 2 ) : ?>
< table width = " 50% " >< tr >< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " colspan = " 4 " >
< table cellspacing = " 0 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< b >
< font size = " +1 " >< ?
$s = $prod [ " name " ];
$s = stripslashes ( $s );
$s = htmlspecialchars ( $s );
$s = str_replace ( " &# " , " &# " , $s );
echo $s ;
?> </font>
< ? if ( $prod [ " groupname1 " ]) : ?>
by
< a href = " groups.php?which=<? print( $prod["group1"] ); ?> " >< ? if ( ( strlen ( $prod [ " groupname1 " ]) < 25 ) || ! $prod [ " groupa1 " ]) { print ( $prod [ " groupname1 " ]);} else { print ( $prod [ " groupa1 " ]);} ?> </a>
< ? if ( $prod [ " groupweb1 " ]) : ?>
[ < a href = " <? print( $prod["groupweb1"] ); ?> " > web </ a > ]
< ? endif ; ?>
< ? endif ; ?>
< ? if ( $prod [ " groupname2 " ]) : ?>
& amp ;
< a href = " groups.php?which=<? print( $prod["group2"] ); ?> " >< ? if ( ( strlen ( $prod [ " groupname2 " ]) < 25 ) || ! $prod [ " groupa2 " ]) { print ( $prod [ " groupname2 " ]);} else { print ( $prod [ " groupa2 " ]);} ?> </a>
< ? if ( $prod [ " groupweb2 " ]) : ?>
[ < a href = " <? print( $prod["groupweb2"] ); ?> " > web </ a > ]
< ? endif ; ?>
< ? endif ; ?>
< ? if ( $prod [ " groupname3 " ]) : ?>
& amp ;
< a href = " groups.php?which=<? print( $prod["group3"] ); ?> " >< ? if ( ( strlen ( $prod [ " groupname3 " ]) < 25 ) || ! $prod [ " groupa3 " ]) { print ( $prod [ " groupname3 " ]);} else { print ( $prod [ " groupa3 " ]);} ?> </a>
< ? if ( $prod [ " groupweb3 " ]) : ?>
[ < a href = " <? print( $prod["groupweb3"] ); ?> " > web </ a > ]
< ? endif ; ?>
< ? endif ; ?>
</ b >
</ td >
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
< td align = " right " valign = " bottom " nowrap >
< b >
< ? if ( $SESSION_LEVEL == 'administrator' || $SESSION_LEVEL == 'moderator' || $SESSION_LEVEL == 'gloperator' ) : ?>
[ < a href = " editprod_light.php?which=<? print( $which ); ?> " > edit </ a > ]
< ? endif ; ?>
< ? if ( file_exists ( " nfo/ " . $prod [ " id " ] . " .nfo " )) : ?>
< ? if ( filesize ( " nfo/ " . $prod [ " id " ] . " .nfo " )) : ?>
[ < a href = " nfo.php?which=<? print( $prod["id"] );
$query = " select count(0) from prods_platforms, platforms WHERE platforms.name like 'Amiga%' and prods_platforms.platform=platforms.id and prods_platforms.prod= " . $prod [ " id " ];
$result = mysql_query ( $query );
if ( mysql_result ( $result , 0 ) > 0 ) print ( " &f=4 " ); ?> ">nfo</a>]
< ? endif ; ?>
< ? else : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
[ < small >
< a href = " submitnfo.php?which=<? print( $prod["id"] ); ?> " >+. nfo </ a >
</ small > ] < br />
< ? endif ; ?>
< ? endif ; ?>
</ b >
</ td >
</ tr >
</ table >
</ td >
</ tr >
< tr bgcolor = " #446688 " >
< td rowspan = " 3 " align = " center " valign = " center " nowrap >
< ? if ( $shotpath ) : ?>
2013-05-07 20:22:01 -04:00
< ? $mysize = GetImageSize ( $shotpath );
2013-05-07 14:20:08 -04:00
$query = " SELECT screenshots.added as dt,users.nickname as nick FROM screenshots,users WHERE prod= " . $prod [ " id " ] . " and users.id=screenshots.user " ;
$result = mysql_query ( $query );
$ssuser = mysql_fetch_object ( $result );
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
if ( $SESSION_LEVEL == 'administrator' || $SESSION_LEVEL == 'moderator' || $SESSION_LEVEL == 'gloperator' ) {
?>
< a href = " submitsshot.php?which=<?= $prod["id"] ?> " >< img src = " <? print( $shotpath ); ?> " < ? print ( $mysize [ 3 ]); ?> border="0" title="screenshot added on the <?=substr($ssuser->dt,0,10)?> by <?=htmlentities($ssuser->nick)?>"></a><br />
< ?
} else {
?>
< img src = " <? print( $shotpath ); ?> " < ? print ( $mysize [ 3 ]); ?> border="0" title="screenshot added on the <?=substr($ssuser->dt,0,10)?> by <?=htmlentities($ssuser->nick)?>"><br />
< ?
}
?>
< ? else : ?>
no screenshot yet ...< br />
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< a href = " submitsshot.php?which=<? print( $prod["id"] ); ?> " > upload one </ a >< br />
< ? endif ; ?>
< ? endif ; ?>
</ td >
< td colspan = " 3 " valign = " top " >
< table border = " 0 " >
< tr >
< td nowrap valign = " top " > platform :</ td >
< td nowrap >
< table cellspacing = " 0 " cellpadding = " 0 " border = " 0 " >
< ?
for ( $i = 0 ; $i < count ( $platforms ); $i ++ ) {
?>
< tr >
< td >
< a href = " prodlist.php?platform[]=<? print( $platforms[$i] [ " name " ]); ?> " >< img src = " gfx/os/<? print( $platforms[$i] [ " icon " ]); ?> " width = " 16 " height = " 16 " border = " 0 " title = " <? print( $platforms[$i] [ " name " ]); ?> " ></ a >< br />
</ td >
< td >& nbsp ; </ td >
< td nowrap >
< a href = " prodlist.php?platform[]=<? print( $platforms[$i] [ " name " ]); ?> " >< ? print ( $platforms [ $i ][ " name " ]); ?> </a><br />
</ td >
</ tr >
< ?
}
?>
</ table >
</ td >
</ tr >
< tr >
< td nowrap valign = " top " > type :</ td >
< td nowrap >
< table cellspacing = " 0 " cellpadding = " 0 " border = " 0 " >
< ? $typess = explode ( " , " , $prod [ " type " ]);
for ( $i = 0 ; $i < count ( $typess ); $i ++ ) { ?>
< tr >
< td >
< a href = " prodlist.php?type[]=<? print( $typess[$i] ); ?> " >< img src = " gfx/types/<? print( $types[$typess[$i] ]); ?> " width = " 16 " height = " 16 " border = " 0 " title = " <? print( $typess[$i] ); ?> " ></ a >< br />
</ td >
< td >& nbsp ; </ td >
< td >
< a href = " prodlist.php?type[]=<? print( $typess[$i] ); ?> " >< ? print ( $typess [ $i ]); ?> </a><br />
</ td >
</ tr >
< ? } ?>
</ table >
</ td >
</ tr >
< ? if ( $prod [ " invitation " ] != 0 ) : ?>
< tr >
< td nowrap > invit for :</ td >
< td nowrap >
< a href = " party.php?which=<? print( $prod["invitation"] ); ?>&when=<? print(sprintf( " % 02 d " , $prod["invitationyear"] )); ?> " >< ? print ( $prod [ " invitationpartyname " ]); ?> </a> <? print($piyear); ?><br />
</ td >
</ tr >
< ? endif ; ?>
< ? if ( $prod [ " boardID " ] != 0 ) : ?>
< tr >
< td nowrap > advertising for :</ td >
< td nowrap >
< a href = " bbses.php?which=<? print( $prod["boardID"] ); ?> " >< ? print ( $prod [ " boardname " ]); ?> </a><br />
</ td >
</ tr >
< ? endif ; ?>
< tr >
< td nowrap > release date :</ td >
< td nowrap colspan = " 2 " >
< ?
if (( $prod [ " date " ] != " 0000-00-00 " ) && ( strlen ( $prod [ " date " ]) > 0 )) {
$rdate = explode ( " - " , $prod [ " date " ]);
switch ( $rdate [ 1 ]) {
case " 01 " : $rmonth = " january " ; break ;
case " 02 " : $rmonth = " february " ; break ;
case " 03 " : $rmonth = " march " ; break ;
case " 04 " : $rmonth = " april " ; break ;
case " 05 " : $rmonth = " may " ; break ;
case " 06 " : $rmonth = " june " ; break ;
case " 07 " : $rmonth = " july " ; break ;
case " 08 " : $rmonth = " august " ; break ;
case " 09 " : $rmonth = " september " ; break ;
case " 10 " : $rmonth = " october " ; break ;
case " 11 " : $rmonth = " november " ; break ;
case " 12 " : $rmonth = " december " ; break ;
default : $rmonth = " " ; break ;
}
?>
< ? print ( $rmonth ); ?> <? print($rdate[0]); ?><br />
< ? } else { ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitpartyinfo.php?which=<?= $prod["id"] ?> " >+</ a > ] < br />
< ? else : ?>
< font color = " #9999AA " > n / a </ font >< br />
< ? endif ; ?>
< ? } ?>
</ td >
</ tr >
< ? if ( ! ( $prod [ " party " ] == 1024 )) : ?>
< tr >
< td nowrap > release party :</ td >
< td nowrap >
< ? if ( strlen ( $prod [ " partyname " ]) > 0 ) : ?>
< a href = " party.php?which=<? print( $prod["party"] ); ?>&when=<? print(sprintf( " % 02 d " , $prod["party_year"] )); ?> " >< ? print ( $prod [ " partyname " ]); ?> </a> <? print($pyear); ?><br />
< ? else : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitpartyinfo.php?which=<?= $prod["id"] ?> " >+</ a > ] < br />
< ? else : ?> <font color="#9999AA">n/a</font>
< ? endif ; ?>
< ? endif ; ?>
</ td >
</ tr >
< ? if ( $prod [ " partycompo " ] != " none " ) : ?>
< tr >
< td nowrap > compo :</ td >
< td nowrap >
< ? if ( $prod [ " partycompo " ]) :
print ( $prod [ " partycompo " ] . " <br /> " );
2013-05-07 20:22:01 -04:00
else :
2013-05-07 14:20:08 -04:00
if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitpartyinfo.php?which=<?= $prod["id"] ?> " >+</ a > ] < br />
2013-05-07 20:22:01 -04:00
< ? else : ?> <font color="#9999AA">n/a</font>
2013-05-07 14:20:08 -04:00
< ? endif ; ?>
< ? endif ; ?>
</ td >
</ tr >
< tr >
< td nowrap > ranked :</ td >
< td nowrap >
< ? if ( $prod [ " party_place " ]) :
switch ( $prod [ " party_place " ]) {
case 1 :
case 21 :
case 31 :
case 41 :
case 51 :
case 61 :
case 71 :
case 81 :
2013-05-07 20:22:01 -04:00
case 91 : $placeadj = " st " ;
2013-05-07 14:20:08 -04:00
print ( $prod [ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 2 :
case 22 :
case 32 :
case 42 :
case 52 :
case 62 :
case 72 :
case 82 :
2013-05-07 20:22:01 -04:00
case 92 : $placeadj = " nd " ;
2013-05-07 14:20:08 -04:00
print ( $prod [ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 3 :
case 23 :
case 33 :
case 43 :
case 53 :
case 63 :
case 73 :
case 83 :
2013-05-07 20:22:01 -04:00
case 93 : $placeadj = " rd " ;
2013-05-07 14:20:08 -04:00
print ( $prod [ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 97 : print ( " disqualified<br /> " );
break ;
case 98 : print ( " n/a<br /> " );
break ;
case 99 : print ( " not shown<br /> " );
break ;
default : $placeadj = " th " ;
print ( $prod [ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
}
?>
< ? else : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitpartyinfo.php?which=<?= $prod["id"] ?> " >+</ a > ] < br />
2013-05-07 20:22:01 -04:00
< ? else : ?> <font color="#9999AA">n/a</font>
2013-05-07 14:20:08 -04:00
< ? endif ; ?>
< ? endif ; ?>
</ td >
</ tr >
< ? endif ; ?>
< ? endif ; ?>
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
< ? //otherparty
for ( $i = 0 ; $i < count ( $prodotherparties ); $i ++ ) :
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
if ( isset ( $prodotherparties [ $i ][ " party_year " ])) {
$pyear = $prodotherparties [ $i ][ " party_year " ];
}
?>
< tr >
< td nowrap > release party :</ td >
< td nowrap >
< ? if ( strlen ( $prodotherparties [ $i ][ " name " ]) > 0 ) : ?>
< a href = " party.php?which=<? print( $prodotherparties[$i] [ " party " ]); ?>&when=<? print(sprintf( " % 02 d " , $prodotherparties[$i] [ " party_year " ])); ?> " >< ? print ( $prodotherparties [ $i ][ " name " ]); ?> </a> <? print($pyear); ?><br />
< ? else : ?>
< font color = " #9999AA " > n / a </ font >
< ? endif ; ?>
</ td >
</ tr >
< ? if ( $prodotherparties [ $i ][ " partycompo " ] != " none " ) : ?>
< tr >
< td nowrap > compo :</ td >
< td nowrap >
< ? if ( $prodotherparties [ $i ][ " partycompo " ]) :
print ( $prodotherparties [ $i ][ " partycompo " ] . " <br /> " );
else : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitotherpartyinfo.php?which=<?= $prod["id"] ?>&what=<?= $prodotherparties[$i] [ " party " ]?> " >+</ a > ] < br />
2013-05-07 20:22:01 -04:00
< ? else : ?> <font color="#9999AA">n/a</font>
2013-05-07 14:20:08 -04:00
< ? endif ; ?>
< ? endif ; ?>
</ td >
</ tr >
< tr >
< td nowrap > ranked :</ td >
< td nowrap >
< ? if ( $prodotherparties [ $i ][ " party_place " ]) :
switch ( $prodotherparties [ $i ][ " party_place " ]) {
case 1 :
case 21 :
case 31 :
case 41 :
case 51 :
case 61 :
case 71 :
case 81 :
2013-05-07 20:22:01 -04:00
case 91 : $placeadj = " st " ;
2013-05-07 14:20:08 -04:00
print ( $prodotherparties [ $i ][ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 2 :
case 22 :
case 32 :
case 42 :
case 52 :
case 62 :
case 72 :
case 82 :
2013-05-07 20:22:01 -04:00
case 92 : $placeadj = " nd " ;
2013-05-07 14:20:08 -04:00
print ( $prodotherparties [ $i ][ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 3 :
case 23 :
case 33 :
case 43 :
case 53 :
case 63 :
case 73 :
case 83 :
2013-05-07 20:22:01 -04:00
case 93 : $placeadj = " rd " ;
2013-05-07 14:20:08 -04:00
print ( $prodotherparties [ $i ][ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
case 97 : print ( " disqualified<br /> " );
break ;
case 98 : print ( " n/a<br /> " );
break ;
case 99 : print ( " not shown<br /> " );
break ;
default : $placeadj = " th " ;
print ( $prodotherparties [ $i ][ " party_place " ] . " <font color= \" #CCCCCC \" > " . $placeadj . " </font><br /> " );
break ;
}
else :
if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< font color = " #9999AA " > n / a </ font > [ < a href = " submitotherpartyinfo.php?which=<?= $prod["id"] ?>&what=<?= $prodotherparties[$i] [ " party " ]?> " >+</ a > ] < br />
2013-05-07 20:22:01 -04:00
< ? else : ?> <font color="#9999AA">n/a</font>
2013-05-07 14:20:08 -04:00
< ? endif ; ?>
< ? endif ; ?>
</ td >
</ tr >
< ? endif ; ?>
< ? endfor ; ?>
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
< ? if ( count ( $affils )) : ?>
< tr >
< td nowrap valign = " top " > related :</ td >
< td nowrap >< ? for ( $i = 0 ; $i < count ( $affils ); $i ++ ) : ?>
< a href = " prod.php?which=<? print( $affils[$i] [ $affils[$i] [ " prod " ]]); ?> " >< ?
if ( $affils [ $i ][ " prod " ] == " derivative " )
print ( $affilorig [ $affils [ $i ][ " type " ]]);
else
print ( $affilinverse [ $affils [ $i ][ " type " ]]);
echo " : " . $affils [ $i ][ " name " ];
?> </a><br /><? endfor; ?>
</ td >
</ tr >
< ? endif ; ?>
</ table >
</ td >
</ tr >
< ? $pourcent = floor ( $prod [ " views " ] * 100 / $max_views ); ?>
< tr >
< td bgcolor = " #557799 " >
< table border = " 0 " >
< tr >
< td >< img src = " gfx/rulez.gif " width = " 16 " height = " 16 " border = " 0 " title = " rulez " >
</ td >
< td >
< ? if ( ! $prod [ " voteup " ]) { print ( " 0 " );} else { print ( $prod [ " voteup " ]);} ?>
</ td >
2013-05-07 20:22:01 -04:00
</ tr >
2013-05-07 14:20:08 -04:00
< tr >
< td >< img src = " gfx/isok.gif " width = " 16 " height = " 16 " border = " 0 " title = " piggie " >
</ td >
< td >
< ? if ( ! $prod [ " votepig " ]) { print ( " 0 " );} else { print ( $prod [ " votepig " ]);} ?>
</ td >
2013-05-07 20:22:01 -04:00
</ tr >
2013-05-07 14:20:08 -04:00
< tr >
< td >< img src = " gfx/sucks.gif " width = " 16 " height = " 16 " border = " 0 " title = " sucks " >
</ td >
< td >
< ? if ( ! $prod [ " votedown " ]) { print ( " 0 " );} else { print ( $prod [ " votedown " ]);} ?>
</ td >
2013-05-07 20:22:01 -04:00
</ tr >
2013-05-07 14:20:08 -04:00
</ table >
</ td >
< td bgcolor = " #446688 " align = " center " valign = " center " >
< table border = " 0 " width = " 100 " >
< tr >
< td >
popularity :< br />
</ td >
< td align = " right " nowrap >
< ? print ( $pourcent ); ?> %<br />
</ td >
</ tr >
< tr >
< td colspan = " 3 " >
< ? DoBar ( $pourcent , true ); ?>
</ td >
</ tr >
2013-05-07 20:22:01 -04:00
< ?
2013-05-07 14:20:08 -04:00
if ( count ( $sceneorgrecommends )) :
print ( " <tr><td nowrap align= \" left \" > " );
for ( $k = 0 ; $k < count ( $sceneorgrecommends ); $k ++ ) {
printf ( " <a href='./sceneorg.php#%s'><img src= \" gfx/sceneorg/%s.gif \" title= \" %s \" alt= \" %s \" border= \" 0 \" ></a> " ,
$sceneorgrecommends [ $k ][ " type " ] == " viewingtip " ? substr ( $prod [ " date " ], 0 , 4 ) : substr ( $prod [ " date " ], 0 , 4 ) . str_replace ( " " , " " , $sceneorgrecommends [ $k ][ " category " ]),
$sceneorgrecommends [ $k ][ " type " ],
$sceneorgrecommends [ $k ][ " category " ],
$sceneorgrecommends [ $k ][ " category " ]);
}
print ( " <br /></td></tr> " );
endif ;
?>
</ table >
</ td >
</ tr >
< tr >
< td bgcolor = " #557799 " >
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
< ? if ( $prod [ " voteavg " ] > 0 )
$thumbgfx = " gfx/rulez.gif " ;
elseif ( $prod [ " voteavg " ] == 0 )
$thumbgfx = " gfx/isok.gif " ;
else
$thumbgfx = " gfx/sucks.gif " ;
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
if ( $prod [ " cdc " ] > 0 ) $cdcprint = " <td> </td><td><img src= \" gfx/titles/coupdecoeur.gif \" width= \" 16 \" height= \" 16 \" border= \" 0 \" alt= \" cdc \" ></td><td> </td><td> " . $prod [ " cdc " ] . " </td> " ;
else $cdcprint = " " ;
2013-05-07 20:22:01 -04:00
2013-05-07 14:20:08 -04:00
printf (
" <table cellspacing= \" 0 \" cellpadding= \" 0 \" > " .
" <tr> " .
" <td><img src= \" " . $thumbgfx . " \" width= \" 16 \" height= \" 16 \" border= \" 0 \" alt= \" average rating \" align= \" left \" ></td> " .
" <td> </td> " .
" <td>%.2f</td> " . $cdcprint .
" </tr> " .
" </table> \n " , $prod [ " voteavg " ]);
echo " <div style='margin:10px auto; font-size:80%; text-align:center;'> " ;
echo " alltime top: " ;
if ( $prod [ " rank " ])
printf ( " #%d " , $prod [ " rank " ]);
else
echo " n/a " ;
echo " </div> " ;
?>
</ td >
< td bgcolor = " #446688 " align = " right " valign = " bottom " colspan = " 2 " nowrap >
< ? if ( $prod [ " csdb " ]) : ?>
[ < a href = " http://noname.c64.org/csdb/release/?id=<? print( $prod["csdb"] ); ?> " > csdb </ a > ] < br />
< ? else : ?>
< ? if ( $check64 ) : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
[ < small >
< a href = " submitprodcsdb.php?which=<? print( $prod["id"] ); ?> " >+ csdb </ a >
</ small > ] < br />
< ? endif ; ?>
< ? endif ; ?>
< ? endif ; ?>
< ? if ( $prod [ " sceneorg " ]) : ?>
[ < a href = " http://scene.org/file.php?id=<? print( $prod["sceneorg"] ); ?> " > sceneorg </ a > ] < br />
< ? else : ?> <? /*if($_SESSION["SCENEID_ID"]): ?>
[ < small >
< a href = " submitprodsceneorg.php?which=<? print( $prod["id"] ); ?> " >+ sceneorg </ a >
</ small > ]
< ? endif ; */ ?>
< ? endif ; ?>
< ? if ( $prod [ " zxdemo " ]) : ?>
[ < a href = " http://zxdemo.org/item.php?id=<? print( $prod["zxdemo"] ); ?> " > zxdemo </ a > ] < br />
< ? else : ?>
< ? if ( $checkzx ) : ?>
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
[ < small >
< a href = " submitprodzxdemo.php?which=<? print( $prod["id"] ); ?> " >+ zxdemo </ a >
</ small > ] < br />
< ? endif ; ?>
< ? endif ; ?>
< ? endif ; ?>
< span id = " mainDownload " > [ < a id = " mainDownloadLink " href = " <?= $prod["download"] ?> " > download </ a > ] </ span >< br />
< ? for ( $i = 0 ; $i < count ( $dl ); $i ++ ) : ?>
[ < a href = " <? print( $dl[$i] [ " link " ]); ?> " >< ? print ( $dl [ $i ][ " type " ]); ?> </a>]<br />
< ? endfor ; ?>
[ < a href = " download.php?which=<?= $prod["id"] ?> " > mirrors ...</ a > ] < br />
</ td >
</ tr >
< tr >
< td bgcolor = " #6688AA " colspan = 4 " align= " right " >
< table cellspacing = " 0 " cellpadding = " 0 " >
< tr >
< td > added on the < ? print ( substr ( $prod [ " quand " ], 0 , 10 )); ?> by <a href="user.php?who=<? print($prod["added"]); ?>"><? print($prod["nickname"]); ?></a></td>
< td >& nbsp ; < br /></ td >
< td >< a href = " user.php?who=<? print( $prod["added"] ); ?> " >< img src = " avatars/<? print( $prod["avatar"] ); ?> " width = " 16 " height = " 16 " border = " 0 " ></ a ></ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
< br />
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > popularity helper </ b >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #446688 " align = " center " >
increase the popularity of this prod by spreading this URL :< br />
2013-05-14 22:19:46 -04:00
< input type = " text " value = " http://pouet.net/prod.php?which=<? print( $prod["id"] ); ?> " size = " 50 " readonly >
2013-05-07 14:20:08 -04:00
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
< br />
< ? if ( count ( $comments ) > 0 ) : ?>
< table id = " prodcommenttable " bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > comments </ b >< br />
</ td >
</ tr >
< ? for ( $i = 0 ; $i < count ( $comments ); $i ++ ) : ?>
< tr class = " cite-<?= $comments[$i] [ " who " ]?> " >
< td bgcolor = " #446688 " id = " c<?= $comments[$i] [ " id " ]?> " >
< ?
if ( ( ( $comments [ $i ][ " level " ] == 'fakeuser' ) && $user [ " prodhidefakeuser " ] ) || ( ( $comments [ $i ][ " level " ] == 'pr0nstahr' ) && $user [ " prodhidepornstar " ] ) || ( ( $comments [ $i ][ " level " ] == 'annoyinguser' ) && $user [ " prodhideannoyinguser " ] ) )
2013-05-09 22:14:51 -04:00
{ print ( " i'm a " . $comments [ $i ][ " level " ] . " so i got shamelessly censored, if you're registered you can uncensor my level's posts <a href= \" customize.php \" >here</a> " ); }
2013-05-07 14:20:08 -04:00
else { print ( parse_message ( $comments [ $i ][ " comment " ])); }
?>
</ td >
</ tr >
< tr class = " cite-<?= $comments[$i] [ " who " ]?> " >
< td bgcolor = " #6688AA " colspan = " 2 " align = " right " >
< table cellspacing = " 0 " cellpadding = " 0 " width = " 100% " >
< tr >
< td width = " 100% " >
< ? if ( $comments [ $i ][ " rating " ] == 1 ) : ?>
< img src = " gfx/rulez.gif " width = " 16 " height = " 16 " border = " 0 " title = " rulez " >
< ? elseif ( $comments [ $i ][ " rating " ] ==- 1 ) : ?>
< img src = " gfx/sucks.gif " width = " 16 " height = " 16 " border = " 0 " title = " sucks " >
< ? endif ; ?>
< ? if ( $comments [ $i ][ " cdc " ] == $prod [ " id " ] && ! $cdcdone [ $comments [ $i ][ " who " ]]) : ?>
< img src = " gfx/titles/coupdecoeur.gif " width = " 16 " height = " 16 " border = " 0 " title = " cdc " >
< ? $cdcdone [ $comments [ $i ][ " who " ]] = 1 ; endif ; ?>
2013-05-07 20:22:01 -04:00
& nbsp ; </ td >
2013-05-07 14:20:08 -04:00
< td nowrap > added on the < a href = " prod.php?which=<?= $prod["id"] ?>#c<?= $comments[$i] [ " id " ]?> " >< ? print ( $comments [ $i ][ " quand " ]); ?> </a> by <a href="user.php?who=<? print($comments[$i]["who"]); ?>"><? print($comments[$i]["nickname"]); ?></a></td>
< td nowrap >& nbsp ; </ td >
< td nowrap >< a href = " user.php?who=<? print( $comments[$i] [ " who " ]); ?> " >< img src = " avatars/<? print( $comments[$i] [ " avatar " ]); ?> " width = " 16 " height = " 16 " border = " 0 " title = " <? print( $comments[$i] [ " nickname " ]); ?> " ></ a ></ td >
</ tr >
</ table >
</ td >
</ tr >
< ? endfor ; ?>
< ? $page_link = " prod.php?which= $which &howmanycomments= $howmanycomments &page= " ; ?>
< tr bgcolor = " #224488 " >
< td >
< table width = " 100% " cellspacing = " 0 " cellpadding = " 0 " border = " 0 " >
< tr >
< ? if (( $page >= 1 ) && ( $comments_per_page > 0 )) : ?>
< td >
< a href = " <?= $page_link .( $page -1)?> " >
< img src = " gfx/flecheg.gif " border = " 0 " >< br />
</ a >
</ td >
< td >& nbsp ; </ td >
< td nowrap >
< a href = " <?= $page_link .( $page -1)?> " >
< b > previous page </ b >< br />
</ a >
</ td >
< ? endif ; ?>
< td width = " 100% " align = " center " >
< form name = " howmanycomments " action = " prod.php " >
< table >< tr >
< td nowrap >
displaying
< input type = " hidden " name = " which " value = " <? print( $which ); ?> " >
< select name = " howmanycomments " onChange = " document.howmanycomments.submit(); " >
< option value = " 0 " < ? = ( $howmanycomments == 0 ) ? 'selected' : '' ?> >none</option>
< option value = " 25 " < ? = ( $howmanycomments == 25 ) ? 'selected' : '' ?> >25</option>
< option value = " 50 " < ? = ( $howmanycomments == 50 ) ? 'selected' : '' ?> >50</option>
< option value = " 100 " < ? = ( $howmanycomments == 100 ) ? 'selected' : '' ?> >100</option>
< option value = " -1 " < ? = ( $howmanycomments ==- 1 ) ? 'selected' : '' ?> >all</option>
</ select >
comments
< ? if ( $comments_per_page > 0 ) : ?>
( < b >< ? = ( $page * $comments_per_page + 1 ) ?> </b>-<b><?=min(($page+1)*$comments_per_page, $nb_comments)?></b>)
< ? endif ; ?>
out of < b >< ? = $nb_comments ?> </b>
< ? if ( $page > 0 ) : ?> (<a href="<?=$page_link?>0">go to first</a>)
< ? endif ; ?>
</ td >
</ tr ></ table >
</ form >
</ td >
< ? if (((( $page + 1 ) * $comments_per_page ) < $nb_comments ) && ( $comments_per_page > 0 )) : ?>
< td nowrap >
< a href = " <?= $page_link .( $page +1)?> " >
< b > next page </ b >< br />
</ a >
</ td >
< td >& nbsp ; </ td >
< td >
< a href = " <?= $page_link .( $page +1)?> " >
< img src = " gfx/fleched.gif " border = " 0 " >< br />
</ a >
</ td >
< ? endif ; ?>
</ tr >
</ table >
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
< ?
if ( count ( $othercdc )) {
?>
< br />
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< th > sneaky cdc ' s </ th >
</ tr >
< ?
foreach ( $othercdc as $v ) {
$query = " SELECT nickname,avatar,id FROM users WHERE id= " . $v ;
$result = mysql_query ( $query );
$o = mysql_fetch_object ( $result );
printf ( " <tr><td class='bg1'><a href='user.php?who=%d'><img src='avatars/%s' border='0'></a> <a href='user.php?who=%d'>%s</a></td></tr> " ,
$o -> id , $o -> avatar , $o -> id , $o -> nickname );
}
2013-05-07 20:22:01 -04:00
?>
2013-05-07 14:20:08 -04:00
</ table >
2013-05-07 20:22:01 -04:00
< ?
2013-05-07 14:20:08 -04:00
}
?>
< ? endif ; ?>
< ? if ( $howmanycomments == 0 ) : ?>
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > comments </ b >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #446688 " align = " center " >
Comments are actually hidden .< br />
< b >< a href = " prod.php?which=<?= $which ?>&howmanycomments=25 " > Click here to show the comments again .</ a ></ b >< br />
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
< ? endif ; ?>
< br />
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > submit changes </ b >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #446688 " align = " center " >
if this prod is a fake , some info is false or the download link is broken , < br />
do not post about it in the comments , it will get lost .< br />
instead , < a href = " topic.php?which=1024 " >< b > post </ b ></ a > about it .< br />
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
< br />
< ? if ( $_SESSION [ " SCENEID_ID " ]) : ?>
< form action = " add.php " method = " post " >
< input type = " hidden " name = " which " value = " <? print( $prod["id"] ); ?> " >
< input type = " hidden " name = " type " value = " comment " >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > add a comment </ b >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #446688 " align = " center " >
< ?
// check if the logged user has already rated (not commented) this prod
$query = 'SELECT count(0) FROM comments WHERE which=' . $prod [ " id " ] . ' AND who=' . $_SESSION [ " SCENEID_ID " ] . ' AND rating!=0' ;
$result = mysql_query ( $query );
if ( ! mysql_result ( $result , 0 )) :
?>
< table border = " 0 " >
< tr >
< td > this prod </ td >
< td align = " right " >< input type = " radio " name = " rating " value = " rulez " ></ td >
< td >< img src = " gfx/rulez.gif " width = " 16 " height = " 16 " border = " 0 " title = " rulez " ></ td >
< td > rulez </ td >
< td align = " right " >< input type = " radio " name = " rating " value = " isok " checked ></ td >
< td >< img src = " gfx/isok.gif " width = " 16 " height = " 16 " border = " 0 " title = " is ok " ></ td >
< td > is ok </ td >
< td align = " right " >< input type = " radio " name = " rating " value = " sucks " ></ td >
< td >< img src = " gfx/sucks.gif " width = " 16 " height = " 16 " border = " 0 " title = " sucks " ></ td >
< td > sucks </ td >
</ tr >
</ table >
< ? else : ?>
< input type = " hidden " name = " rating " value = " isok " >
< ? endif ; ?>
< script language = " JavaScript " type = " text/javascript " >
<!--
function checkWarning ( cmt )
{
document . getElementById ( " commentwarning " ) . innerHTML = " " ;
if ( cmt . search ( / youtube / i ) !=- 1 || cmt . search ( / youtu\ . be / i ) !=- 1 )
{
2013-05-14 22:19:46 -04:00
document . getElementById ( " commentwarning " ) . innerHTML = " if you want to add a youtube link, go <a href='/topic.php?which=1024'>here</a> instead! " ;
2013-05-07 14:20:08 -04:00
}
if ( cmt . search ( / soundcloud / i ) !=- 1 || cmt . search ( / \ . mp3 / i ) !=- 1 || cmt . search ( / \ . ogg / i ) !=- 1 )
{
2013-05-14 22:19:46 -04:00
document . getElementById ( " commentwarning " ) . innerHTML = " if you want to add a soundtrack link, go <a href='/topic.php?which=1024'>here</a> instead! " ;
2013-05-07 14:20:08 -04:00
}
}
//-->
2013-05-07 20:22:01 -04:00
</ script >
2013-05-07 14:20:08 -04:00
< textarea name = " comment " cols = " 50 " rows = " 5 " onkeyup = " checkWarning(this.value) " ></ textarea >< br />
< a href = " faq.php#BB Code " >< b > BB Code </ b ></ a > is allowed here < br />
</ td >
</ tr >
< tr >
< td bgcolor = " #6688AA " colspan = " 2 " align = " right " >
< script language = " JavaScript " type = " text/javascript " >
<!--
document . write ( '<div id="commentwarning" style="float:left;padding-top:2px;padding-left:2px"></div>' );
document . write ( '<input type="image" src="gfx/preview.gif" onclick=\'return preview(this.form,"prod")\' border="0">' );
//-->
2013-05-07 20:22:01 -04:00
</ script >
2013-05-07 14:20:08 -04:00
< input type = " image " src = " gfx/submit.gif " border = " 0 " >< br />
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
</ form >
< ? else : ?>
< form action = " login.php " method = " post " >
< table cellspacing = " 1 " cellpadding = " 2 " class = " box " >
< tr >< th > add a comment </ th ></ tr >
< tr bgcolor = " #446688 " >
< td nowrap align = " center " >
You need to be logged in to add a comment :: < a href = " account.php " > register here </ a >< br />
< input type = " text " name = " login " value = " SceneID " size = " 15 " maxlength = " 16 " onfocus = " this.value='' " >
< input type = " password " name = " password " value = " password " size = " 15 " onfocus = " javascript:if(this.value=='password') this.value=''; " >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #6688AA " align = " right " >
< input type = " image " src = " gfx/submit.gif " >
</ td >
</ tr >
</ table >
</ form >
< br />
< ? endif ; ?>
< br />
2013-05-07 20:22:01 -04:00
< ?
2013-05-07 14:20:08 -04:00
//if ($SESSION_LEVEL=='administrator'):
$yearcheck = substr ( $prod [ " date " ], 0 , - 6 );
if ( $sceneorgyear && $yearcheck == $sceneorgyear ) {
//if (0) {
$result = mysql_query ( " SELECT * from awardscand_ " . $sceneorgyear . " where user=' " . $_SESSION [ " SCENEID_ID " ] . " ' " );
$awardscand = mysql_fetch_assoc ( $result );
/*
if ( $prod [ " id " ] == $awardscand [ " cat1 " ]
|| $prod [ " id " ] == $awardscand [ " cat2 " ]
|| $prod [ " id " ] == $awardscand [ " cat3 " ]
|| $prod [ " id " ] == $awardscand [ " cat4 " ]
|| $prod [ " id " ] == $awardscand [ " cat5 " ]
|| $prod [ " id " ] == $awardscand [ " cat6 " ]
|| $prod [ " id " ] == $awardscand [ " cat7 " ]
|| $prod [ " id " ] == $awardscand [ " cat8 " ]
|| $prod [ " id " ] == $awardscand [ " cat9 " ]
|| $prod [ " id " ] == $awardscand [ " cat10 " ]
|| $prod [ " id " ] == $awardscand [ " cat11 " ]) $nominate = true ;
*/
?>
< form action = " awardscandidates.php " method = " post " name = " awardscandidates " >
< input type = " hidden " name = " prod " value = " <?= $prod["id"] ?> " >
< input type = " hidden " name = " action " value = " alter " >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 0 " border = " 0 " width = " 100% " >
< tr >
< td >
< table bgcolor = " #000000 " cellspacing = " 1 " cellpadding = " 2 " border = " 0 " width = " 100% " >
< tr >
< td bgcolor = " #224488 " >
< b > scene . org awards candidate </ b >< br />
</ td >
</ tr >
< tr >
< td bgcolor = " #446688 " align = " center " >
suggest this prod to the jury for a < a href = " http://awards.scene.org " > scene . org awards </ a > category !
check your full suggestions < a href = " awardscandidates.php " > here </ a >< br />
<!-- div style = 'background:#800;color:white;margin:10px;padding:10px' > suggestions will close on wednesday , january the 5 th ! vote now !</ div -->
< select name = " cat[] " multiple = " multiple " size = " <?=count( $awardscat[$yearcheck] )?> " >
< ?
foreach ( $awardscat [ $yearcheck ] as $x => $name ) {
if ( $prod [ " id " ] == $awardscand [ " cat " . $x ]) $is_selected = " selected " ;
else $is_selected = " " ;
print ( " <option value=' " . $x . " ' " . $is_selected . " > " . $name . " </option> \n " );
}
?>
</ td >
</ tr >
< tr >
< td bgcolor = " #6688AA " align = " right " colspan = " 3 " >
< input type = " image " src = " gfx/submit.gif " >
</ td >
</ tr >
</ table >
</ td >
</ tr >
</ table >
</ form >
< ?
}
?>
</ td ></ tr ></ table >
< ? else : ?>
< center >< ? print ( " the wrongly submitted prod that you are looking for has been lobsterxiced from our database! " .
" <br /> probably with a very good reason too! <br /> <br />*clack clack* ( \ /) o o ( \ /) *clack clack* " ); ?> </center>
< ? endif ; ?>
< br />
2013-05-07 20:22:01 -04:00
< ? require ( " include/bottom.php " ); ?>