PHP Classes

Parse Error

Recommend this page to a friend!

      Battlefield 2 Server Query  >  All threads  >  Parse Error  >  (Un) Subscribe thread alerts  
Subject:Parse Error
Summary:T_OLD_FUNCTION or T_FUNCTION or T_VAR
Messages:2
Author:Matt Webb
Date:2005-07-15 23:09:06
Update:2005-07-16 05:20:33
 

 


  1. Parse Error   Reply   Report abuse  
Picture of Matt Webb Matt Webb - 2005-07-15 23:09:06
Used the index.php and supplied my ip and port. Variable passed fine in the URL. However on battlefield-2-layout.php, i get this error;


Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/****/public_html/****/battlefield-2-class.php on line 37

Line 37 is

private function delete_array_element_by_key($array,$keyname)

I use php 4.3 and all files are chmodded to 775


  2. Re: Parse Error   Reply   Report abuse  
Picture of Bogdan Zarchievici Bogdan Zarchievici - 2005-07-16 05:20:33 - In reply to message 1 from Matt Webb
On PHP Classes I have uploaded the PHP5 class. I forgot that many people still use PHP 4. In order to make it work with your PHP 4 please remove the "private" and "public".

I will upload the PHP4 compatible class later today.