I would choose javascript to to check this

-----Original Message-----
From: Stuart Felenstein [mailto:[EMAIL PROTECTED] 
Sent: vrijdag 29 oktober 2004 15:13
To: [EMAIL PROTECTED]
Subject: [PHP] Code help on a multi select list


I want to do a server side trap if a user selects more
from a mult select list then allowed.  Just unsure and
didn't find any examples.  Seems people rely more on
javascript these days.  

So here is how I grab the array:

if ( is_array( $_REQUEST['LurkerIndustry'] ) ) { $_SESSION['l_industry']
= array_unique( array_merge( $_SESSION['l_industry'],
$_REQUEST['LurkerIndustry'] ) ); }

here is my somewhat hazy notion: 

if 
( is_array( $_REQUEST['LurkerIndustry'] ) ) { $_SESSION['l_industry'] =
array_unique( if $l_industry > 5 
   ( Here I'm guess I need to redirect back to page   
         with and error message)

else
array_merge( $_SESSION['l_industry'],  $_REQUEST['LurkerIndustry'] ) );
}

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to