Re: contador visitas

From: Date: Thu, 25 Jul 2002 14:41:55 +0000
Subject: Re: contador visitas
References: 1  Groups: php.general.es 
Request: Send a blank email to general-es+get-25317@lists.php.net to get a copy of this message
encontre este codigo: <?php ######################################################################## # Copyright © 2001 Wanja Hemmerich # # © March 2001 # # Original from: Guy N. Hurst # ######################################################################## # COPYRIGHT NOTICE # # Copyright 2001 Wanja Hemmerich. All rights reserved. # # # # This program may be used and modified, as long as this copyright # # notice stays intact. # # # # Wanja Hemmerich is not responsible for damage, which is possibly # # caused by his program. # # # # This program code may not be sold, nor auctioneered, nor be used in # # any other commercial way in order to make money. # # # # This Programm may not be distributed to download neither by # # Internet, nor by another medium. # ######################################################################## # By using this programm, you agree with these conditions. # # # ######################################################################## # The text above must be kept intact under all circumstances. # ######################################################################## # Edit variables: ############################################################### $path = "./"; # Path to the image file $image = "digits_2.gif"; # Destination of the file in $path $maxlength = 15; # Maximum number of digits # Done! ############################################################### if (!$data) $data = dirname(__FILE__)."/hits.txt"; $stand = file($data); $neustand = $stand[0] + 1; $neu = fopen($data, "w+"); fputs($neu, $neustand); fclose($neu); $count = $neustand; $length = strlen($count); if ($digits < 1) $digits = $length; } if ($digits > $maxlength) { $digits = $maxlength; } $count = sprintf("%0".$digits."s",$count); $count = substr("$count", -$digits); if (file_exists("$path/$pix.gif")) { $image="$pix.gif"; } $output_image = ImageCreateFromGIF("$path/$image"); $output_imag_x = ImageSX($output_image); $output_imag_y = ImageSY($output_image); $cutter = $output_imag_x/10; $output_x = $cutter*$digits; $output = ImageCreate($output_x, $output_imag_y); $counter = 0; while ($counter < $digits) { $c = substr("$count", $counter, 1); $x = $counter*$cutter; $y = $c*$cutter; ImageCopyResized($output, $output_image, $x, 0, $y, 0, $cutter, $output_imag_y, $cutter, $output_imag_y); $counter++; } Header("Content-type: image/gif"); ImageGIF($output); ImageDestroy($output); ?> pero al ejecutarlo me sale: Warning: ImageCreateFromGif: Unable to open .//digits_2.gif for reading in /home/httpd/html/aefic/phpcounter/pixcount_en/pixcount.php3 on line 63 Warning: Unable to find image pointer in /home/httpd/html/aefic/phpcounter/pixcount_en/pixcount.php3 on line 64 Warning: Unable to find image pointer in /home/httpd/html/aefic/phpcounter/pixcount_en/pixcount.php3 on line 65 Warning: Unable to find image pointer in /home/httpd/html/aefic/phpcounter/pixcount_en/pixcount.php3 on line 76 Warning: Cannot add more header information - the header was already sent (header information may be added only before any output is generated from the script - check for text or whitespace outside PHP tags, or calls to functions that output text) in /home/httpd/html/aefic/phpcounter/pixcount_en/pixcount.php3 on line 80 GIF87a€,,; alguien sabe que falta Saludos Lizardo

« previous php.general.es (#25317) next »