Hello all,
any help will be appreciated.
I get this error when installing jam affiliate script:
Parse error: parse error, unexpected T_CASE in /home/content/mydomain/aff2/includes/mod/mod_main.php on line 72
The code related to this line is lines 70-127 :
if ( empty( $_POST['change_status'] ) )
{
case "commissions" :
switch ( $mod )
{
switch ( $_POST['change_status'] )
{
case "delete" :
if ( $access == "deletecomm" )
{
display_admin_form( "admin_error_form" );
exit( );
}
case "approve" :
case "disapprove" :
case "paid" :
case "unpaid" :
case "pending" :
if ( !( $access == "payaffs" ) && !( $access == "editcomm" ) && !( $access == "approvecomm" ) )
{
display_admin_form( "admin_error_form" );
exit( );
}
}
continue;
switch ( $mod )
{
case "affiliates" :
switch ( $_POST['change_status'] )
{
case "active" :
case "inactive" :
case "remove" :
if ( $access == "editaff" )
{
display_admin_form( "admin_error_form" );
exit( );
}
case "delete" :
if ( $access == "deleteaff" )
{
display_admin_form( "admin_error_form" );
exit( );
}
}
if ( !ereg( "group", $_POST['change_status'] ) || !( $access == "editaff" ) )
{
display_admin_form( "admin_error_form" );
exit( );
}
}
}
}
else
{
$seclevel = "";
}
}
And as an over kil here are lines 10-127
[SNIP]
Thank you in advance
MOD EDIT: Dropped irrelevant code