So I am currently working at Stanford over the summer and I have to
make a google gadget on energy conservation. What I want the gadget to
do is allow the user to log in, and based on the login info, I should
be able to use php scripts to access information from a database about
their energy usage. So far I have this:
<?xml version="1.0" encoding="UTF-8" ?>
<Module>
<ModulePrefs title="Go to Photo Album" height="350" scaling="false" /
>
<Content type="html">
<![CDATA[
<html>
<head></head>
<body>
<form action="summedDataGrabber.php" method="POST" ><br>
<div>
<h2> Power Checker </h2><br>
Channel ID <input type="text" name="channelID"><br>
Home ID <input type"text" name="homeID"><br>
Start Date <input type"text" name="startTime"><br>
End Date <input type"text" name="endTime"><br>
</div>
<input type="submit" value="Submit!"/>
</form>
</body>
</html>
]]>
</Content>
</Module>
The php file on my server is this:
<?php
/*takes in a homeID, channelID, start and end time and retrieves total
energy output during that time period*/
//input variables
$channelID = $_POST["channelID"]; //of the form: deviceID-nodeID
$deviceID = strtok($channelID,"-");
$nodeID = strtok("-");
$homeID = $_POST["homeID"];
$start = $_POST["startTime"];
$end = $_POST["endTime"];
echo('whhhhhhhhat');
?>
But when I click the submit button, the forms are still there and
nothing is echo'ed. I don't have a lot of html or javascript
experience and any advice would be appreciated. Thanks.
--
You received this message because you are subscribed to the Google Groups
"iGoogle Developer Forum" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/Google-Gadgets-API?hl=en.