Jump to content

conditional select


stvchez

Recommended Posts

Hi, i'm attempting to do a simple conditional select of by the url date variable.

 

here's the month get:

$m = $_GET['m]; // m = 2

 

<select name="date_month">

<OPTION  VALUE="01">01</OPTION>

<OPTION  VALUE="02">02</OPTION>

<OPTION  VALUE="03">03</OPTION>

<OPTION  VALUE="04">04</OPTION>

 

then, something along lines of:

if ($m == ...) { echo"SELECTED"; }

Link to comment
https://forums.phpfreaks.com/topic/39914-conditional-select/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.