P
Prawy

  • May 11, 2020
  • Joined Jul 16, 2019
  • Hello,

    what can occur this problem?
    This code used to work normally
    2
    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 196

    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 197
    2
    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 196

    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 197
    2
    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 196

    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 197
    2
    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 196

    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 197
    2
    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 196

    Notice: Undefined offset: 0 in C:\xampp\htdocs\admin\index.php on line 197

    Here is a link to full index.php code: https://pastebin.com/eT5TBDim

    Thank you in advance for any help

    • these 4 things have warning:

      		$newsTitle[ count( $newsTitle ) ] = $tmp[ 0 ];
      		$newsText[ count( $newsText ) ] = $tmp[ 1 ];			
      		$newsDate[ count( $newsDate ) ] = $tmp[ 2 ];	
      		$newsApproval[ count( $newsApproval ) ] = $tmp[ 3 ];
      • Hello how to fix it guys?

        Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\htdocs\admin\index.php on line 284

        Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\htdocs\admin\index.php on line 285

        Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\htdocs\admin\index.php on line 286

        Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\htdocs\admin\index.php on line 287

        • I need it for server statistics

          ^ Means a color in game for example ^ 1 = red ^ 2 = green

          If you don't know still just visit zom.rostojek.com and check at server status. Bot called Fagiosteals0 is green in game his nickname is ^ 2fagiosteals0

          • Hello here is my function to make working colors prefix from Call of Duty. Prefix for color is for example ^1 = red

            But this code looks like doesn't work on the newest php.

            function colorize( $s ) {
            	$s = htmlSpecialChars( $s );
            	$t = $s;
            	global $numtags;
            	global $add;
            	
            	$a = array( "red", "#000", "#a8e61d", "#fff200", "#0000d1", "#00c9cd", "#cb00ce", "#696164", "#eb93bb", "#dcdcdc" );
            	for( $i = 0; $i < count( $a ); $i++ ) $s = str_replace( '^^' . $i . $i, '<span style="color:' . $a[ $i ] . '";">', $s );	
                for( $i = 0; $i < count( $a ); $i++ ) $s = str_replace( '^' . $i, '<span style="color:' . $a[ $i ] . '";">', $s );		
            	$spans = preg_match_all( '/\^[0-9]/U', $t, $matches );
            	for( $i = 1; $i <= $numtags; $i++ ) $add .= '</span>';
                return $s . $add;
            }
            • Hello i'm new in here

              I have got this problem and i don't know php totally. Please help me to fix that!

              Fatal error: Uncaught Error: Call to undefined function eregi_replace() in C:\xampp\htdocs\admin\index.php:203 Stack trace: #0 C:\xampp\htdocs\admin\index.php(92): color('\xFF\xFF\xFF\xFFprint\n"sv_h...') #1 {main} thrown in C:\xampp\htdocs\admin\index.php on line 203

              Line 203: $text = eregi_replace('^0', '<font color="gray">',$text);