trouble with if command... VERY URGENT!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm working on a Joomla component (don't let that scare you) for forms.  I'm
trying to limit access to specific forms until the previous ones have been
completed.  I started by using a $_SESSION variable set at a specific point
that each user must pass to go on.  That worked marvelously.  I'm trying to
add a second step and the page is not being stopped.  Here is my code as is
(I'm very green at writing PHP, please be nice).

 

if ( $_REQUEST['formid'] == 2 and $_SESSION['uccverified'] != 1) {

                        $_SESSION['uccverified'] = 1;

                        header ("Location:
http://www.floracraft.com/index.php?option=performs&formid=1";);

                        exit;

                        } 

elseif ( $_REQUEST['formid'] == 2 and $_SESSION['uccverified'] = 1) {

                        $_SESSION['uccverified'] = '2';

} 
elseif ( $_REQUEST['formid'] == 3 and $_SESSION['uccverified'] != 2) {

                        unset ($_SESSION['uccverified']);

                        header ("Location:
http://www.floracraft.com/index.php?option=performs&formid=1";);

                        exit; 

                        } 

elseif ( $_REQUEST['formid'] == 3 and $_SESSION['uccverified'] = 2) {

                                    unset ($_SESSION['uccverified']);

                        }

 

The first checkpoint works.  If you try to access formid=2 and you have not
passed the checkpoint where the $_SESSION variable is set, you get
automatically sent back to formid=1.  If I try to browse to formid=3,
however, I am not reverted back to formid=1.  :-(  My deadline on this is
about an hour.  This was a last minute change for security measures and I
need to get this going.  Please help!

 

Aaron

  _____  

From: php-objects@xxxxxxxxxxxxxxx [mailto:php-objects@xxxxxxxxxxxxxxx] On
Behalf Of Atkinson, Robert
Sent: Wednesday, October 31, 2007 5:27 AM
To: php-objects@xxxxxxxxxxxxxxx
Subject:  HTML Query String Problem

 

I'm passing control to a popup window using a string like this :-

/do_something?display&copy_target&123abc

The problem is that '&copy' is being translated into the copywrite symbol.
Anyone know the correct syntax to pass the string in, to stop this being
translated?

I've tried using JavaScript escape() to translate to %26 (or something like
that), but it's not being translated back again.

Rob.

****************************************************************************
*******
Any opinions expressed in email are those of the individual and not
necessarily those of the company. This email and any files transmitted with
it are confidential and solely for the use of the intended recipient 
or entity to whom they are addressed. It may contain material protected by
attorney-client privilege. If you are not the intended recipient, or a
person responsible for delivering to the intended recipient, be advised that
you have received this email in error and that any use is strictly
prohibited.

Random House Group + 44 (0) 20 7840 8400
http://www.randomho <http://www.randomhouse.co.uk> use.co.uk
http://www.booksatt <http://www.booksattransworld.co.uk> ransworld.co.uk 
http://www.kidsatra <http://www.kidsatrandomhouse.co.uk> ndomhouse.co.uk
Generic email address - enquiries@randomhou
<mailto:enquiries%40randomhouse.co.uk> se.co.uk

Name & Registered Office:
THE RANDOM HOUSE GROUP LIMITED
20 VAUXHALL BRIDGE ROAD
LONDON
SW1V 2SA
Random House Group Ltd is registered in the United Kingdom with company No.
00954009, VAT number 102838980
****************************************************************************
*******

[Non-text portions of this message have been removed]

 



[Non-text portions of this message have been removed]


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Soap]     [Kernel Newbies]     [Yosemite]     [Yosemite Campsites]

  Powered by Linux