On Sat, 14 Apr 2007 18:40:27 +0000 (UTC), "slowpoke115"
<webforumsuser@macromedia.com> wrote:
>That kinda works but the reason I wanted to use an if
statement was because i
>need some other information from the matching record set.
With the jump box I
>want three things to be selectable, when one is selected
it is used as a field
>(all this works with the code you provided me with) BUT I
also need other
>information dependant upon the jump box, in this case it
is
>service/physical/skill completion date. My database is
made in such a way that
>each one is just service_date/physical_date/skill_date.
could I just do
>"$_POST[TASKS] _date" or something fancy like that? Whats
the best way of doing
>this? Sorry its so unclear
Okay, I'm still a bit in the dark about what you want, but
perhaps this
will get you closer:
IF ("'.$_POST['TASKS']."' = Service) THEN SELECT Service
FROM DETAILS
ELSE IF ("'.$_POST['TASKS']."' = Physical) THEN SELECT
Physical FROM
DETAILS
ELSE ("'.$_POST['TASKS']."' = Skill) THEN SELECT Skill FROM
DETAILS
switch($_POST['TASKS']){
case 'Service':
// build your query here
break;
case 'Physical':
// build your query here
break;
case 'Skill':
// build your query here
break;
}
Gary