Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/252.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
重定向标头函数以替换轮询;“谢谢你”;页面已使用PHP就位_Php_Jquery_Html_Function_Header - Fatal编程技术网

重定向标头函数以替换轮询;“谢谢你”;页面已使用PHP就位

重定向标头函数以替换轮询;“谢谢你”;页面已使用PHP就位,php,jquery,html,function,header,Php,Jquery,Html,Function,Header,我已经有了一个PHP民意测验,但我已经将它设置为在每次提交民意测验后有多个(10),而不是说“谢谢你,诸如此类”。。。我想直接进入下一个投票问题 这就是我所拥有的 投票已经有一个功能,在“谢谢”页面上有一个“继续下一次投票”按钮,我想删除这个按钮和页面,让它直接自动进入投票。我能想到的最好的办法就是头球向前 转发到下一次轮询的按钮示例: <a href="<?php the_return_to_url(); ?>">Next</a> 在不修改原始功能的情况

我已经有了一个PHP民意测验,但我已经将它设置为在每次提交民意测验后有多个(10),而不是说“谢谢你,诸如此类”。。。我想直接进入下一个投票问题

这就是我所拥有的

投票已经有一个功能,在“谢谢”页面上有一个“继续下一次投票”按钮,我想删除这个按钮和页面,让它直接自动进入投票。我能想到的最好的办法就是头球向前

转发到下一次轮询的按钮示例:

 <a href="<?php the_return_to_url(); ?>">Next</a>

在不修改原始功能的情况下:

function the_return_to_url() {
global $requested_poll_id;
global $VALID_POLLS;
$poll = $VALID_POLLS[$requested_poll_id];

if(!empty($poll->returnToURL)) {
    echo $poll->returnToURL;
} else {
    vote_die("ERROR: Return to URL not defined for this poll.");
}

}
<?php
ob_start();
the_return_to_url();
header('Location: http://'.ob_get_clean());
die();
?>

Ahhh,非常感谢。我尝试了一些验证,比如header('Location:the_return_to_url());诸如此类
<?php
ob_start();
the_return_to_url();
header('Location: http://'.ob_get_clean());
die();
?>