Chapter 12 "Stock Widget"
I have attempted to modify the "Stock Widget" example to permit stock symbol entry via a text input form instead of the values being hard coded into the stockproxy.php file. This was accomplished by replacing the $SYMBOLS array with the following code (the text "ge" was retained for testing purposes):
$sticker0 = $_POST["sticker0"];
$sticker1 = $_POST["sticker1"];
$sticker2 = $_POST["sticker2"];
$sticker3 = $_POST["sticker3"];
$sticker4 = $_POST["sticker4"];
$SYMBOLS = array(
This appears to work fine for retrieving the information from Yahoo as indicated by the "echo $json->encode($object_to_serialize);" statement at the end of the stockproxy.php file. However, the table output produced by "default.htm" only includes data for the text data "ge".
Could you please help me understand why the text variables are not understood by the application?