Location: PHPKode > scripts > OekakiPoteto > oekakipoteto/index.php
<?
//OekakiPoteto © RanmaGuy (Theo Chakkapark), http://suteki.nu
if ($mode=="res_msg") {
include('dbconn.php');
	$result = mysql_query("SELECT * from ".$OekakiPoteto_Prefix."oekakidta where usrname='$OekakiU' order by ID_2 DESC");
	$row = mysql_fetch_array($result);
	$resno = $row[PIC_ID];
	header ("Location: redirect.php?resno=".$resno."&mode=res_msg&edittimes=".$edittimes."&datatype=".$datatype);
	mysql_close();
	exit;
}

if ($mode=="ani_msg") {
include('dbconn.php');
	$result = mysql_query("SELECT * from ".$OekakiPoteto_Prefix."oekakidta where usrname='$OekakiU' order by ID_2 DESC");
	$row = mysql_fetch_array($result);
	$resno = $row[PIC_ID];
	header ("Location: redirect.php?resno=".$resno."&mode=ani_msg&edittimes=".$edittimes."&datatype=".$datatype);
	mysql_close();
	exit;
}
?>
<html>
<?
include('header.php');
include('dbconn.php');
if (!$pageno) $pageno=0;
$i = 0;
if (!$sort) $sort="0";
if ($artist) $sort="6";

if ($sort==0) {
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1' order by ID_2 DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}

if ($sort==1){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta where postlock='1' order by lastcmt DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}

//animation sort by newest
if ($sort==2){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1' order by ID_2 DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}

//animation sort by comment
if ($sort==3){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta WHERE animation = 1 and postlock='1' order by lastcmt DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}

//archive sort by newest
if ($sort==4){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1' order by ID_2 DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}


//archive sort by date
if ($sort==5){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta WHERE archive = 1 and postlock='1' order by lastcmt DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}

//artist sort by newest
if ($sort==6){
$result5 = mysql_query("SELECT count(ID_2) as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE usrname LIKE '%$artist%'");
$rownum2 = mysql_result($result5, 0, 'rowno');
$pages = intval($rownum2/$ppage) + 1;
$rsql = "SELECT ID_2 as rowno FROM ".$OekakiPoteto_Prefix."oekakidta WHERE usrname LIKE '%$artist%' LIMIT ".($pageno*$ppage).", ".$ppage;
$result5 = mysql_query($rsql);
$rownum = mysql_numrows($result5);
$rsql2 = "SELECT * FROM ".$OekakiPoteto_Prefix."oekakidta WHERE usrname LIKE '%$artist%' order by lastcmt DESC LIMIT ".($pageno*$ppage).", ".$ppage;
$result = mysql_query($rsql2);
}
?>
<div align="center"><br>
  <br>
  <br>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="0" align="center" class="infotable">
    <tr> 
      <td><font size = "-1"><?include('notice.php');?></font></td>
    </tr>
  </table>
  <br>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="0" align="center" class="infotable">
    <tr> 
      <td><font size="-2"><b><a name="pagetop"></a><?=$langop_common_moveto?> </b> 
        <? WHILE ($i4 < $pages):
		if($i4 != $pageno){?>
        - <a href="index.php?sort=<?=$sort?>&pageno=<?=$i4?><?if($artist){?>&artist=<?=urlencode($artist)?><?}?>"><?=$i4+1?></a>
		<? } else { ?>
		- <b><?=$i4+1?></b>	
		<?}$i4++;
endwhile;?>
        </font></td>
    </tr>
  </table>
  <br>
  <?if(!isset($display)){
  	$display = 0;
	}
	if($display==0){ ?>
  <?  
//Output rows until the value of i matches the number of rows
WHILE ($i < $rownum):  ?>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="3" align="center" class="infotable">
    <tr> 
      <td colspan="2" class="header"><a name="<?=mysql_result($result,$i,"PIC_ID");?>"></a>[<b><a href="#<?=mysql_result($result,$i,"PIC_ID");?>"> 
        <?=mysql_result($result,$i,"PIC_ID");?>
        </a></b>] 
        <? 
		if((strstr($usrflags,"O")) || (strstr($usrflags,"S")) || (strstr($usrflags,"A"))){ ?>
        [<a href="functions.php?picid=<?=mysql_result($result,$i,"PIC_ID");?>&mode=archive"> 
        <? if(mysql_result($result,$i,"archive") == "0"){ echo $langop_word_archive; } else { echo $langop_word_unarchive;}?>
        </a>] 
        <? } ?>
        <?if(mysql_result($result,$i,"usrname") == $OekakiU){?>
        [ 
        <? if(mysql_result($result,$i,"animation") == "0" && mysql_result($result,$i,"datatype") == "0"){
			 ?>
        <a href="noteBBS.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "0") {?>
        <a href="noteBBSa.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "0" && mysql_result($result,$i,"datatype") == "1"){?>
        <a href="oekakiBBS.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "1"){?>
        <a href="oekakiBBSa.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <? } ?>
        ] 
        <?} if(($guestpost == "yes") || ($OekakiU != "")){?>
        [<a href="comment.php?mode=add&resno=<?=mysql_result($result,$i,"PIC_ID");?>"><?=$langop_word_comment?></a>] 
        <?}?>
        [<a href="#pagetop"><?=$langop_word_top?></a>]<b> <?=$langop_word_artist?>:</b> <a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>', 300, 400); return false" a href="profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>"> 
        <?=mysql_result($result,$i,"usrname");?>
        </a> | <b><?=$langop_install_title2?>:</b> 
        <?=nifty2_convert(mysql_result($result,$i,"title"));?>
        | <b><?=$langop_word_time?>:</b> 
        <?$editsec=mysql_result($result,$i,"edittime");if($editsec<20){?>
        <?=$langop_word_unknown?> 
        <?}else{?>
        <?=ceil($editsec/60)?>
        <?=$langop_word_minutes?> 
        <?} if(strstr($uflags,"O") || strstr($uflags,"S") || strstr($uflags,"A")){?>
		[<a href="delconf.php?mode=dela&picno=<?=mysql_result($result,$i,"PIC_ID");?>"><?=$langop_word_delete?></a>]<?}?>
        </td>
    </tr>
    <tr> 
      <td width="5%" height="197" valign="top"> 
<div align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="-1"><a href="<?=$OPpics?>/<?=mysql_result($result,$i,"PIC_ID");?>.png"><img src="<?if (!strstr($usrflags,"X") && mysql_result($result,$i,"adult")==1) {
echo "pr0n.png";
}else {
if($jpgcompression == "yes"){
echo $OPpics.'/'.mysql_result($result,$i,"PIC_ID").".jpg";
} else {
echo $OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png";
}
}?>" alt="<?=$langop_adult_view?>" border="0"></a><br>
          <br><? if(mysql_result($result,$i,"datatype") == "0"){?>
          <?=$langop_word_paintbbs?><? } if(mysql_result($result,$i,"datatype") == "1"){?><?=$langop_word_oekakibbs?><? } ?> <br><br>
          <? if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "0"){  
		  $theImage = GetImageSize($OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png");?>
          [<a href="#" onClick="openWindow('viewani.php?xcord=<?=$theImage[0];?>&ycord=<?=$theImage[1];?>&recno=<?=mysql_result($result,$i,"ID_2");?>', '<?=$theImage[0] + 75;?>', '<?=$theImage[1] + 100;?>'); return false"><?=$langop_viewani_title?></a>] 
          <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "1"){  
		  $theImage = GetImageSize($OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png");?>
          [<a href="#" onClick="openWindow('viewanio.php?xcord=<?=$theImage[0];?>&ycord=<?=$theImage[1];?>&recno=<?=mysql_result($result,$i,"ID_2");?>', '<?=$theImage[0] + 100;?>', '<?=$theImage[1] + 100;?>'); return false"><?=$langop_viewani_title?></a>] 
          <?}if(mysql_result($result,$i,"archive") == "1"){?>
          <br>
          (<?=$langop_word_archived?>) 
          <? }?>
          </font></div>
      </td>
      <td width="95%" valign="top"> 
        <table width="<?=$cWidth?>" border="0" cellspacing="0" cellpadding="<?=$cCellPadding?>">
          <tr>
            <td class="commenttitle"> <b><a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>', 300, 400); return false" href="profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>"> 
              <?=mysql_result($result,$i,"usrname");?></a> @ <font color="<?=$dStamp?>"><?=date("l, F jS Y, g:i A",strtotime(mysql_result($result,$i,"postdate")));?>
              </font></b></td>
          </tr>
          <tr> 
            <td class="commentpost">
              <?=nifty2_convert(mysql_result($result,$i,"comment"));?>
            </td>
          </tr>
        </table>

        <br>
        <? 
$picd = mysql_result($result,$i,"PIC_ID");
$result2 = mysql_query("SELECT * FROM ".$OekakiPoteto_Prefix."oekakicmt where PIC_ID = '$picd' ORDER BY postdate asc");
$rownum2 = mysql_numrows($result2);
$i2 = 0;
WHILE ($i2 < $rownum2): 
?>
        <table width="<?=$cWidth?>" border="0" cellspacing="0" cellpadding="<?=$cCellPadding?>">
          <tr>
            <td class="commenttitle"> 
              <? if (mysql_result($result2,$i2,"usrname")=="Guest") { ?>
              <a href="mailto:<?=mysql_result($result2,$i2,"email");?>">
              <?=mysql_result($result2,$i2,"postname");?>
              </a> <a href="<?=mysql_result($result2,$i2,"url");?>">[<?=$langop_word_homepage?>]</a> 
              <? } else { ?>
              <a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result2,$i2,"usrname"));?>', 300, 400); return false" href="profile.php?user=<?=urlencode(mysql_result($result2,$i2,"usrname"));?>">
              <?=mysql_result($result2,$i2,"usrname");?>
              </a>
              <?}?>

              @ <font color="<?=$dStamp?>"> 
              <?=date("l, F jS Y, g:i A",strtotime(mysql_result($result2,$i2,"postdate")));?>
              </font> <?if(strstr($uflags,"O") || strstr($uflags,"S") || strstr($uflags,"A")){?>
		[<a href="functions.php?mode=delcmt&cmtno=<?=mysql_result($result2,$i2,"ID_3");?>"><?=$langop_word_delete?></a>]<?}?>
</td>
          </tr>
          <tr> 
            <td class="commentpost">
              <?=nifty2_convert(mysql_result($result2,$i2,"comment"));?>
            </td>
          </tr>
        </table>
        <br>
        <?   
$i2++;
endwhile; 
 ?>
      </td>
    </tr>
  </table>
  <br>
  <? 
$i3++;
if ($i3 >($ppage-1)) {
$i = $rownum;
} else {
$i++;
}
endwhile; 
mysql_close($dbconn);
 ?>
  <? } else { // display?>
  <?  
//Output rows until the value of i matches the number of rows
WHILE ($i < $rownum):  ?>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="3">
    <tr class="commentpost"> 
      <td class="header"><a name="<?=mysql_result($result,$i,"PIC_ID");?>"></a>[<b><a href="#<?=mysql_result($result,$i,"PIC_ID");?>"> 
        <?=mysql_result($result,$i,"PIC_ID");?>
        </a></b>] 
        <? 
		if((strstr($usrflags,"O")) || (strstr($usrflags,"S")) || (strstr($usrflags,"A"))){ ?>
        [<a href="functions.php?picid=<?=mysql_result($result,$i,"PIC_ID");?>&mode=archive"> 
        <? if(mysql_result($result,$i,"archive") == "0"){ echo $langop_word_archive; } else { echo $langop_word_unarchive;}?>
        </a>] 
        <? } ?>
        <?if(mysql_result($result,$i,"usrname") == $OekakiU){?>
        [ 
        <? if(mysql_result($result,$i,"animation") == "0" && mysql_result($result,$i,"datatype") == "0"){
			 ?>
        <a href="noteBBS.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "0") {?>
        <a href="noteBBSa.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "0" && mysql_result($result,$i,"datatype") == "1"){?>
        <a href="oekakiBBS.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "1"){?>
        <a href="oekakiBBSa.php?edit=<?=mysql_result($result,$i,"PIC_ID")?>"><?=$langop_word_retouch?></a> 
        <? } ?>
        ] 
        <?} if(($guestpost == "yes") || ($OekakiU != "")){?>
        [<a href="comment.php?mode=add&resno=<?=mysql_result($result,$i,"PIC_ID");?>"><?=$langop_word_comment?></a>] 
        <?}?>
        [<a href="#pagetop"><?=$langop_word_top?></a>]<b> <?=$langop_word_artist?>:</b> <a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>', 300, 400); return false" a href="profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>"> 
        <?=mysql_result($result,$i,"usrname");?>
        </a> | <b><?=$langop_install_title2?>:</b> 
        <?=nifty2_convert(mysql_result($result,$i,"title"));?>
        | <b><?=$langop_word_time?>:</b> 
        <?$editsec=mysql_result($result,$i,"edittime");if($editsec<20){?>
        <?=$langop_word_unknown?> 
        <?}else{?>
        <?=ceil($editsec/60)?>
        <?=$langop_word_minutes?> 
        <?} if(strstr($uflags,"O") || strstr($uflags,"S") || strstr($uflags,"A")){?>
        [<a href="delconf.php?mode=dela&picno=<?=mysql_result($result,$i,"PIC_ID");?>"><?=$langop_word_delete?></a>] 
        <?}?>
      </td>
    </tr>
  </table>
  <br>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="3" align="center" class="commentpost">
    <tr> 
      <td valign="top"> <div align="center"><font face="Verdana, Arial, Helvetica, sans-serif" size="-1"><a href="<?=$OPpics?>/<?=mysql_result($result,$i,"PIC_ID");?>.png"><img src="<?if (!strstr($usrflags,"X") && mysql_result($result,$i,"adult")==1) {
echo "pr0n.png";
}else {
if($jpgcompression == "yes"){
echo $OPpics.'/'.mysql_result($result,$i,"PIC_ID").".jpg";
} else {
echo $OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png";
}}?>" alt="<?=$langop_adult_view?>" border="0"></a><br>
          <br>
          <? if(mysql_result($result,$i,"datatype") == "0"){?>
          <?=$langop_word_paintbbs?> 
          <? } if(mysql_result($result,$i,"datatype") == "1"){?>
          <?=$langop_word_oekakibbs?> 
          <? } ?>
          <br>
          <br>
          <? if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "0"){  
		  $theImage = GetImageSize($OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png");?>
          [<a href="#" onClick="openWindow('viewani.php?xcord=<?=$theImage[0];?>&ycord=<?=$theImage[1];?>&recno=<?=mysql_result($result,$i,"ID_2");?>', '<?=$theImage[0] + 75;?>', '<?=$theImage[1] + 100;?>'); return false"><?=$langop_viewani_title?></a>] 
          <?} if(mysql_result($result,$i,"animation") == "1" && mysql_result($result,$i,"datatype") == "1"){  
		  $theImage = GetImageSize($OPpics.'/'.mysql_result($result,$i,"PIC_ID").".png");?>
          [<a href="#" onClick="openWindow('viewanio.php?xcord=<?=$theImage[0];?>&ycord=<?=$theImage[1];?>&recno=<?=mysql_result($result,$i,"ID_2");?>', '<?=$theImage[0] + 100;?>', '<?=$theImage[1] + 100;?>'); return false"><?=$langop_viewani_title?></a>] 
          <?}if(mysql_result($result,$i,"archive") == "1"){?>
          <br>
          (<?=$langop_word_archived ?>) 
          <? }?>
          </font></div></td>
    </tr>
    <tr> 
      <td valign="top">
<table width="<?=$cWidth?>" border="0" cellspacing="0" cellpadding="<?=$cCellPadding?>">
          <tr> 
            <td class="commenttitle"> <b><a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>', 300, 400); return false" href="profile.php?user=<?=urlencode(mysql_result($result,$i,"usrname"));?>"> 
              <?=mysql_result($result,$i,"usrname");?>
              </a> @ <font color="<?=$dStamp?>"> 
              <?=date("l, F jS Y, g:i A",strtotime(mysql_result($result,$i,"postdate")));?>
              </font></b></td>
          </tr>
          <tr> 
            <td class="commentpost"> 
              <?=nifty2_convert(mysql_result($result,$i,"comment"));?>
            </td>
          </tr>
        </table>
        <br> 
        <? 
$picd = mysql_result($result,$i,"PIC_ID");
$result2 = mysql_query("SELECT * FROM ".$OekakiPoteto_Prefix."oekakicmt where PIC_ID = '$picd' ORDER BY postdate asc");
$rownum2 = mysql_numrows($result2);
$i2 = 0;
WHILE ($i2 < $rownum2): 
?>
        <table width="<?=$cWidth?>" border="0" cellspacing="0" cellpadding="<?=$cCellPadding?>">
          <tr> 
            <td class="commenttitle"> 
              <? if (mysql_result($result2,$i2,"usrname")=="Guest") { ?>
              <a href="mailto:<?=mysql_result($result2,$i2,"email");?>"> 
              <?=mysql_result($result2,$i2,"postname");?>
              </a> <a href="<?=mysql_result($result2,$i2,"url");?>">[<?=$langop_word_homepage?>]</a> 
              <? } else { ?>
              <a onClick="openWindow('profile.php?user=<?=urlencode(mysql_result($result2,$i2,"usrname"));?>', 300, 400); return false" href="profile.php?user=<?=urlencode(mysql_result($result2,$i2,"usrname"));?>"> 
              <?=mysql_result($result2,$i2,"usrname");?>
              </a> 
              <?}?>
              @ <font color="<?=$dStamp?>"> 
              <?=date("l, F jS Y, g:i A",strtotime(mysql_result($result2,$i2,"postdate")));?>
              </font> 
              <?if(strstr($uflags,"O") || strstr($uflags,"S") || strstr($uflags,"A")){?>
              [<a href="functions.php?mode=delcmt&cmtno=<?=mysql_result($result2,$i2,"ID_3");?>"><?=$langop_word_delete?></a>] 
              <?}?>
            </td>
          </tr>
          <tr> 
            <td class="commentpost"> 
              <?=nifty2_convert(mysql_result($result2,$i2,"comment"));?>
            </td>
          </tr>
        </table>
        <br>
        <?   
$i2++;
endwhile; 
 ?>
      </td>
    </tr>
  </table>
  <br>
  <? 
$i3++;
if ($i3 >($ppage-1)) {
$i = $rownum;
} else {
$i++;
}
endwhile; 
mysql_close($dbconn);
 ?>
  <? }?>
  <br>
  <table width="<?=$hWidth?>" border="0" cellspacing="0" cellpadding="0" align="center" class="infotable">
    <tr> 
      <td><font size="-2"><b><?=$langop_common_moveto?> </b> 
        <? $i4 = 0;
		WHILE ($i4 < $pages):
		if($i4 != $pageno){?>
        - <a href="index.php?sort=<?=$sort?>&pageno=<?=$i4?><?if($artist){?>&artist=<?=urlencode($artist)?><?}?>"><?=$i4+1?></a> 
        <? } else { ?>
        - <b><?=$i4+1?></b> 
        <?}$i4++;
endwhile;?>
        </font></td>
    </tr>
  </table>
</div>
</body>
  <? include('footer.php'); ?>
Return current item: OekakiPoteto