【发布时间】:2011-01-13 06:07:57
【问题描述】:
这是我的代码
<form method="post">
<input name="hash" type="text" id="hash" style='width: 30%;'/>
<input name="Crack!" type="submit" value="Crack!" onfocus="if(this.blur)this.blur()"/>
</form>
<?php
if(isset($_POST['Crack!'])){
$hash = $_POST['hash'];
$xml = simplexml_load_file("http://gdataonline.com/qkhash.php?mode=xml&hash=$hash");
$status = $xml->data->status;
if ($status = "Success"){
$plain = $xml->data->result;
}elseif ($status = "Hash not found"){
$plain = "Not Found"; }
?>
<table>
<tr>
<td><?php echo "gdataonline.com: "; ?></td>
<td><?php echo "$plain"; ?></td>
</tr>
</table>
<?php
echo "<pre>";
var_dump($xml);
echo "</pre>";
} //if submit
?>
出于某种原因,我根本无法让它回显 $plain。好像连读都看不懂。
【问题讨论】: