4 votes
Accepted

Cannot get drop down menu to display for pset7. Why would this be?

The request method is GET by default. When the user visits http://pset7/sell.php, she is requesting the page (i.e., sell.php in this case) using GET. Therefore, the condition $_SERVER["REQUEST_METHOD]...
user avatar
  • 17.3k
2 votes

Creating dropdown menu using information in an SQL database

It looks like you aren't actually putting anything into the HTML to display the value itself. Can you try something like this? echo "<option value = \"".$row["Symbol"]."\">".$row["Symbol"]. "&...
user avatar
  • 18.3k
1 vote
Accepted

pset7 sell: can not make drop down menu work

Just after I posted a question i got it. I should put all data manipulations under else from request.method == "POST".
user avatar
  • 11
1 vote
Accepted

Drop down list using database values in PHP - Doesn't work - Final project

This is sketchy: foreach($result as $result): ?> because the var names are the same (and I'm not sure about : in php). Wouldn't the proper syntax here <option value="$result["name"]"> be <...
user avatar
1 vote

Drop-down Menu for Sell_View.PHP gives empty options

How are you passing the php variable from your controller to your viewing page (sell page)? You are storing the array returned by your mysql query in $symbol, but it looks like you are passing $stocks ...
user avatar
  • 1,415

Only top scored, non community-wiki answers of a minimum length are eligible