我有以下几点:
$allowed_referer = array("https://localhost/**blah.php**"); //add the allowed sites in this array
$referal = $_SERVER['HTTP_REFERER'];
if (in_array($referal, $allowed_referer)){
//Do-stuff
}
因此,如果页面来自blah.php,则允许显示“保存”按钮,而不是“提交”。我已经设置了保存按钮更新数据库和提交按钮插入数据库的位置。
<?php if
我有一个php脚本,它用PDO请求我的数据库验证发送的一些值是否存在。如果它们存在,数据库将使用此行的值的id进行响应。我在mysql上测试了这个查询,它可以工作,但是收到的值是false。此代码仅供个人使用。下面是代码:
<?php
include("../template/pdo.php");
$query = $pdo->prepare("SELECT id_utilisateur FROM utilisateur
WHERE `mail` IN ( ':mail' )
AND `mdp` IN ( '
我使用wordpress作为我的平台,我添加了一个额外的数据库用于定制,当我使用从数据库中查询并转换成数据格式时,wordpress echo故障:Warning: date() expects parameter 2 to be long, string given in D:\www\forums\wordpress\wp-content\plugins\exec-php\includes\runtime.php(42) : eval()’d code on line 249,该如何解决?
<?php
...
while($result = mysql_fetch_array($re