ich habe ein kleines Problem. Ich wollte meine Forum auf den aktuellsten Stand bringen und fing mit dem Update 2.0.21 an. Anfangs klappte es auch alles wunderbar bis ich zu den datein
includes/usercp_confirm
und
includes/usercp_register kam. z.B. folgender Quelltext:
Code: Alles auswählen
#-----[ OPEN ]---------------------------------------------
#
includes/usercp_confirm.php
#
#-----[ FIND ]---------------------------------------------
# Line 64
// If we can we will generate a single filtered png else we will have to simply
// output six seperate original pngs ... first way is preferable!
if (@extension_loaded('zlib'))
{
$_png = define_filtered_pngs();
$total_width = 320;
$total_height = 50;
$img_height = 40;
$img_width = 0;
$l = 0;
list($usec, $sec) = explode(' ', microtime());
mt_srand($sec * $usec);
$char_widths = array();
for ($i = 0; $i < strlen($code); $i++)
{
$char = $code{$i};
$width = mt_rand(0, 4);
$char_widths[] = $width;
$img_width += $_png[$char]['width'] - $width;
}
$offset_x = mt_rand(0, $total_width - $img_width);
$offset_y = mt_rand(0, $total_height - $img_height);
$image = '';
$hold_chars = array();
for ($i = 0; $i < $total_height; $i++)
{
$image .= chr(0);
if ($i > $offset_y && $i < $offset_y + $img_height)
{
$j = 0;
for ($k = 0; $k < $offset_x; $k++)
{
$image .= chr(mt_rand(140, 255));
}
for ($k = 0; $k < strlen($code); $k++)
{
$char = $code{$k};
if (empty($hold_chars[$char]))
{
$hold_chars[$char] = explode("\n", chunk_split(base64_decode($_png[$char]['data']), $_png[$char]['width'] + 1, "\n"));
}
$image .= randomise(substr($hold_chars[$char][$l], 1), $char_widths[$j]);
$j++;
}
for ($k = $offset_x + $img_width; $k < $total_width; $k++)
{
$image .= chr(mt_rand(140, 255));
}
$l++;
}
else
{
for ($k = 0; $k < $total_width; $k++)
{
$image .= chr(mt_rand(140, 255));
}
}
}
unset($hold);
$image = create_png(gzcompress($image), $total_width, $total_height);
// Output image
header('Content-Type: image/png');
header('Cache-control: no-cache, no-store');
echo $image;
unset($image);
unset($_png);
exit;
}
else
{
$_png = define_raw_pngs();
$c = intval($HTTP_GET_VARS['c']);
$char = substr($code, $c - 1, 1);
header('Content-Type: image/png');
header('Cache-control: no-cache, no-store');
echo base64_decode($_png[$char]);
unset($_png);
exit;
}
exit;
Meine beiden Dateien sehen wie folgt aus:
usercp_confirm.txt
usercp_register.txt
Ich würd mich freuen, wenn mir jemand helfen könnte.