Error message on subcription process

Elmar

New Member
Hi Stan,
when trying to subscribe, I suddenly get the following error message:
"Parse error: syntax error, unexpected T_IF, expecting ')' in /mnt/web8/43/12/5808312/htdocs/inhypnos/mlm/lm/html/subscribe_single_fixed.php on line 21"
I didn't change anything for the last weeks. Anything worked fine. Line 21 in the file subscribe_single_fixed.php shows up as follows:
"if ( $email == "" ) { $errors[] = "Enter your email address in the email address text box"; $wrong['email'] = TRUE; }"

I hope you can help.

Best regards, Elmar
 

stanbusk

Administrator
Staff member
It looks like your code lacks a closing bracket before line 21. It is what the error means. The PHP parser is surprised to encounter a 'if' instruction.
 

Elmar

New Member
Okay, but what does that mean in consequence for me? In fact a closing bracket is not correct there, as my comparison with the file "subscribe_single_selection.php" shows. This file works without any complexes. In my eyes it is a wrong error code (although, of cause, it must have its reason). Somewhere must be a mistake.
My Question, of cause: What can I do to get the thing working again?

Elmar
 

stanbusk

Administrator
Staff member
Usually when that happens the script will not work anymore. Please paste all lines up to line 21 and I will check them.
 

Elmar

New Member
Here they are:

<?php

$mlm_debug = False;

if ( $mlm_debug ) {
error_reporting(E_ALL);
ini_set('display_errors','on');
} else {
error_reporting(E_ALL ^ E_NOTICE);
ini_set('display_errors','off');
}

if ( isset( $_REQUEST['cmd'] ) && !empty( $_REQUEST['cmd'] ) ) { $cmd = $_REQUEST['cmd']; }
if ( isset( $_REQUEST['email'] ) && !empty( $_REQUEST['email'] ) ) { $email = $_REQUEST['email']; }
if ( isset( $_REQUEST['list'] ) && !empty( $_REQUEST['list'] ) ) { $list = $_REQUEST['list']; } else { $list = "inhypnos-newsletter"; }
if ( isset( $_REQUEST['firstname'] ) && !empty( $_REQUEST['firstname'] ) ) { $firstname = $_REQUEST['firstname']; }
if ( isset( $_REQUEST['lastname'] ) && !empty( $_REQUEST['lastname'] ) ) { $lastname = $_REQUEST['lastname']; }

if ( isset( $_REQUEST['submit'] ) ) {
$errors = array(
if ( $email == "" ) { $errors[] = "Enter your email address in the email address text box"; $wrong['email'] = TRUE; }
 
Top