And this place is fuckin' dead.
36 new posts since last night.
wtf?
36 new posts since last night.
wtf?
<?
// set config file
if(is_file('config.cfg.php'))
require 'config.cfg.php';
else
die('Error, no config file');
//image directory
if(!is_dir($_images_dir_))
die('Error, no image directory');
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-2">
<title>/justinb.us/gallery/</title>
<meta NAME="Author" CONTENT="JustinB">
<link href="gallery2.css" rel="stylesheet" type="text/css">
</head>
<body>
<?
$time_start = microtime(true);
//specify image type (jpg i gif)
$noimage = 0;
if ($dh = opendir($_images_dir_)) {
while (($f = readdir($dh)) !== false) {
if((substr(strtolower($f),-3) == 'jpg') || (substr(strtolower($f),-3) == 'jpg'))
{
$imageinfo = getimagesize($_images_dir_.$f);
$width = $imageinfo[0];
$height = $imageinfo[1];
$size = round(filesize($_images_dir_.$f)/1024,1).' KB';
$noimage++;
$images[] = array('filename' => $f, 'width' => $width, 'height' => $height, 'size' => $size);
array_multisort($images, $_sort_, SORT_REGULAR);
}
}
closedir($dh);
}
if($noimage)
{
if($_GET["img"] != '')
{
echo '<p class="title">'.$images[$_GET["img"]][filename].'</p>';
if($images[$_GET["img"]][filename] != '')
{
if($_GET["img"])
$_no_ = ceil(($_GET["img"]+1)/$_no_pics_per_page_);
else
$_no_ = 1;
if($_GET["img"] == 0)
$side = '<p class="link"><a href="'.$_SERVER["PHP_SELF"].'?no='.$_no_.'" class="link">UP</a> <a href="'.$_SERVER["PHP_SELF"].'?img='.($_GET["img"]+1).'" class="link">NEXT >></a></p>';
elseif($_GET["img"] == ($noimage-1))
$side = '<p class="link"><a href="'.$_SERVER["PHP_SELF"].'?img='.($_GET["img"]-1).'" class="link"><< PREV</a> <a href="'.$_SERVER["PHP_SELF"].'?no='.$_no_.'" class="link">UP</a></p>';
else
$side = '<p class="link"><a href="'.$_SERVER["PHP_SELF"].'?img='.($_GET["img"]-1).'" class="link"><< PREV</a> <a href="'.$_SERVER["PHP_SELF"].'?no='.$_no_.'" class="link">UP</a> <a href="'.$_SERVER["PHP_SELF"].'?img='.($_GET["img"]+1).'" class="link">NEXT >></a></p>';
echo $side.'<p align="center"><img class= "link" src="picture.php?img='.$images[$_GET["img"]][filename].'&show=full" border="'.$_border_.'" hspace="'.$_hspace_.'" vspace="'.$_vspace_.'" alt="'.$images[$_GET["img"]][filename].'" title="'.$images[$_GET["img"]][filename].', '.$images[$_GET["img"]][width].'x'.$images[$_GET["img"]][height].', '.$images[$_GET["img"]][size].'" ></p>'.$side;
}
}
else
{
echo '<p class="title">'.$_page_title_.'</p>';
// echo $noimage.'<br>'.print_r($images);
if($noimage > $_no_pics_per_page_)
$norows = ceil($_no_pics_per_page_/$_no_cols_);
else
$norows = ceil($noimage/$_no_cols_);
$nopos = ceil($noimage/$_no_pics_per_page_);
// echo $nopos;
echo '<table border="0" align="center" cellpadding="0" cellspacing="0">
';
if($_GET["no"] == "")
$no = 1;
else
$no = $_GET["no"];
$index=abs($no-1)*$_no_pics_per_page_;
if(($noimage-$index)<$_no_pics_per_page_)
$norows= ceil(($noimage-$index)/$_no_cols_);
for($a = 1;$a<=$norows;$a++)
{
echo '
<tr>
';
for($b = 1;$b<=$_no_cols_;$b++)
{
if($images[$index][filename] != '')
{
echo '<td width="'.(2*$_vspace_+$_width_min_).'" valign="top" align="center"><a href="'.$_SERVER["PHP_SELF"].'?img='.$index.'" ><img class="link"src="picture.php?img='.$images[$index][filename].'" border="'.$_border_.'" hspace="'.$_hspace_.'" vspace="'.$_vspace_.'" alt="'.$images[$index][filename].'" title="'.$images[$index][filename].', '.$images[$index][width].'x'.$images[$index][height].', '.$images[$index][size].'"></a>
';
if($_filename_)
echo '<span class="name">'.$images[$index][filename].'</span><br><br>';
echo '</td>';
$index++;
}
else
echo '<td width="'.(2*$_vspace_+$_width_min_).'"> </td>';
}
echo '</tr>
';
}
echo '
</table>
';
if($nopos>1)
{
echo '<p class="stopka">';
for($i=1;$i<=$nopos;$i++)
{
if($i == $no)
echo '<font class="stopka_select">'.$i.'</font> ';
else
echo '<a href="'.$_SERVER["PHP_SELF"].'?no='.$i.'" class="stopka">'.$i.'</a> ';
}
echo '</p>';
}
}
}
else
die('No images in directory');
$time_end = microtime(true);
$time = $time_end - $time_start;
echo '<p class="exe"><br>All images in gallery : '.count($images).'</p>';
?>
<p align="center">
<span style="button">
<a href="http://validator.w3.org/check?uri=http%3A%2F%2Fwww.justinb.us%2Fgallery%2F;ss=1;sp=1"><img border="0"
src="html.png"
alt="Valid HTML 4.01!" height="16" width="80"></a>
<a href="http://jigsaw.w3.org/css-validator/validator?uri=http://www.justinb.us/gallery/gallery2.css"><img border="0"
src="css.png"
alt="Valid CSS!" height="16" width="80"></a>
</span>
</p>
</body>
</html>
// begin irrelevant non-PHP code
void MJ_Tile::Render_FrontFace()const{
if(this->selected){ glColor3f(1.0,0.0,0.0);
}else{ glColor3f(.95,.95,.6); }
if(this->hint){ glColor3f(0.0,1.0,0.0); }
glBindTexture( GL_TEXTURE_2D, this->face_texture);
glBegin(GL_QUADS);
glTexCoord2f( 0.0f, 0.0f );
glVertex3f(pos_x-TILE_V_DX,pos_y+TILE_V_DY,pos_z+TILE_V_DZ);
glTexCoord2f( 1.0f, 0.0f );
glVertex3f(pos_x+TILE_V_DX,pos_y+TILE_V_DY,pos_z+TILE_V_DZ);
glTexCoord2f( 1.0f, 1.0f );
glVertex3f(pos_x+TILE_V_DX,pos_y-TILE_V_DY,pos_z+TILE_V_DZ);
glTexCoord2f( 0.0f, 1.0f );
glVertex3f(pos_x-TILE_V_DX,pos_y-TILE_V_DY,pos_z+TILE_V_DZ);
glEnd();
Unforgiven said:i know nothing of code.
so why the hell did i just read all of that?
Exactly, Since the creation of the Computing Chamber, WTF.com has become a overridden site. Damn computers and their Smart computing ways!Unforgiven said:the only computer language i know is html... and even with that, very little.
HTML isn't really that hard. Aside from XML or Perl, it's probably the easiest language out there. You should check out www.w3schools.com, they have tutorials on how to write semantic, standards compliant code.Unforgiven said:the only computer language i know is html... and even with that, very little.
You people forget so quickly. Jonny's a WinZip haXor111!Bullshyt said:With what, your mom's titties?