Jump to content

Help with setting certian values


ihatetn931

Recommended Posts

ok, I run a samp server that has mysql and i'm creating a website to register on the server, Ok, I got it so you can set your charcter age (it's a role play server) but i need help with setting fighting styles, The gamemode uses pawno scirpt lang and the values i use to set each fighting style is 5,6,15 and 26.

 

I have it set it a drop down menu, I want to convert this code so it shows certian names and when you select those certian names it sets the value for that name

 

Here is the code for my age but i want set to like i said above

		</select>
			<tr>
	<td><b>Age:</b></td>
	<td><select name="age">
			<option value="---">Fighting Style</option>
			';
		for ($i=18;$i<99;$i++)
		{
			$metai = date('Y') - $i;
			echo '<option value="'. $i .'">'. $i .' (' .$metai. ')</option>
			';
		}
		echo '
		</select>

 

Instead of it outputting the Age and the Year i want it to Output those values i mention before and the style

 

Example

These are in the drop down menu

 

Kung_Fu (6)

Elbow (26)

Boxing (5)

Kick Boxing (6)

 

When you select it, It writes to the database

Link to comment
https://forums.phpfreaks.com/topic/210409-help-with-setting-certian-values/
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.