我是php的新手,现在如果我输入$ h2< $ H1。如果有人可以帮我找到我的错误在哪里,我会添加什么?我很高兴知道......
<script>
$( function() {
$("#h1").datepicker({dateFormat: 'yy-mm-dd'});
$("#h2").datepicker({dateFormat: 'yy-mm-dd'});
} );
</script>
&#13;
if ($tag == 2 and $v1 != '') {
$startu=mktime($h1);
$endu=mktime($h2);
$starts=mktime($start);
$ends=mktime($end);
$diffs=$endu-$startu;
$diff=$end-$start;
if ($diffs > 0 || 1==1) {
$query="update settings set cinemashow='$s1' where id=1";
$result=mysql_query($query) or die ('Failed to update');
$query="update settings set start='$h1' where id=1";
$result=mysql_query($query) or die ('Failed to update');
$query="update settings set end='$h2' where id=1";
$result=mysql_query($query) or die ('Failed to update');
$tag=1;
}
if ($diff < 0){
print "<td valign=middle align=center>
<a href=setting.php? onclick=\"return confirm('Failed to update. Please set date again?')\"></font></a>
</td></tr>";
}
}