Jump to content

[SOLVED] drop boxes and the GET function?


winmastergames

Recommended Posts

Hi

I started off making a script so you can type in stuff to a text box and it uses the GET function but i tried to use it with a drop box but it didnt work heres the error I dont quite get what the error means

Fatal error: Uncaught exception 'com_exception' with message 'Parameter 2: Type mismatch. ' in C:\xampp\htdocs\WAC-BETA\command-server.php:3 Stack trace: #0 C:\xampp\htdocs\WAC-BETA\command-server.php(3): com->Run(NULL, 7, false) #1 {main} thrown in C:\xampp\htdocs\WAC-BETA\command-server.php on line 3

 

 

Heres the script with the drop box Just Part of the Whole Script because i want to make this script secure and stuff and i dont want people using this script I made and use it and stuff but you dont need the whole page this is the part that has a problem in?

<form action="command-server.php" method="get">
Name: <select name="commanddrop" style="width: 123px">
<option value="notepad.exe">Notepad</option>
</select>
<input type="submit" />
</form>

 

Heres the script that has the GET function taken away what it executes in the PHP code for security Sorry

<?
Sorry taken away for security
Sorry taken away for security($_GET["command"], 7, false);
?>
Successfully completed the Operation

<br>
<br>
<a href="page-2.php">Continue</a>

 

Whats wrong?

Link to comment
https://forums.phpfreaks.com/topic/82462-solved-drop-boxes-and-the-get-function/
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.