(1)我正在将我的网站上传到远程Web服务器.
(2)网站的模板系统的设置方式是通过发送url编码的get请求来形成所有页面 index.php
(3)加载初始页面工作.此页面通过评估其表单的值来确定下一页的位置.
(4)重定向到下一页是通过执行以下操作来执行的: header('location: next_page')
(5)由于某种原因,不执行重定向.这是代码的样子:
$error = "";
if(isset($_POST['index_choice'])){
$path_choice = isset($_POST['path']) ? $_POST['path'] : NULL;
//echo $path_choice;
//echo $page_inc;
//nothing after this
if($path_choice != null){
if($form->is_connected()){
//if($path_choice != "" || $path_choice != NULL){
if($path_choice == "new"){
//header('location: /login.php');
//header('location: page/login');
header('location: /index.php?page=login');
exit();
}
else{
//header('location: /amend.php');
//header('location: page/amend');
header('location: /index.php?page=amend');
exit();
}
//}
/**
else{
//destroy_session();
$error = "You haven't selected a path. Please choose a path";
}
*
*/
}
else{
//destroy_session();
$error = …Run Code Online (Sandbox Code Playgroud) 尝试修改某些表时,我不断收到此错误.这是我的代码:
/** <- line 320
*
* @param array $guests_array
* @param array $tickets_array
* @param integer $seat_count
* @param integer $order_count
* @param integer $guest_count
*/
private function book_guests($guests_array, $tickets_array, &$seat_count,
&$order_count, &$guest_count){
/* @var $guests_array ArrayObject */
$sucess = false;
if(sizeof($guests_array) >= 1){
//$this->mysqli->autocommit(FALSE);
//insert the guests into guest, person, order, seat
$menu_stmt = $this->mysqli->prepare("SELECT id FROM menu WHERE
name=?");
$menu_stmt->bind_param('s',$menu);
//$menu_stmt->bind_result($menu_id);
$table_stmt = $this->mysqli->prepare("SELECT id FROM tables WHERE
name=?");
$table_stmt->bind_param('s',$table);
//$table_stmt->bind_result($table_id);
$seat_stmt = $this->mysqli->prepare("SELECT id FROM seat …Run Code Online (Sandbox Code Playgroud) 我有一个表,我想记录每个插入时间的每个订单的时间戳.但是,我得到时间戳的零值.
这是我的架构:
CREATE TABLE IF NOT EXISTS orders(
order_no VARCHAR(16) NOT NULL,
volunteer_id VARCHAR(16) NOT NULL,
date TIMESTAMP DEFAULT NOW(),
PRIMARY KEY (order_no),
FOREIGN KEY (volunteer_id) REFERENCES volunteer(id)
ON UPDATE CASCADE ON DELETE CASCADE)
Run Code Online (Sandbox Code Playgroud) 我有一个php文件'run.php',我正在终端上运行.在这个文件中,我有以下几行:
exec("open-crawlers $ port 2>&1",$ out,$ code); echo'hello';
我遇到的问题是终端在执行'exec'命令后挂起; 该计划没有到达第二行.