【发布时间】:2015-04-09 16:52:34
【问题描述】:
我试图研究它,但我认为我的语法可能有问题。下面是尝试的代码。我需要做的是从 iframe 重定向到同一域上的另一个页面。标头:位置仅重定向 iframe,我需要重定向整个页面。从我读过的其他帖子中,这不能通过 PHP 完成,而是需要 javascript。这就是我现在直接在 PHP 中所拥有的。提前致谢。
//header("Location: http://propertytaxdfw.com/CurrentWebsite/error.php?msg=".$httpParsedResponseAr['L_LONGMESSAGE0']);
$ErrorUrl = 'http://propertytaxdfw.com/CurrentWebsite/error.php?msg=".$httpParsedResponseAr['L_LONGMESSAGE0']';
<script type="text/javascript">parent.location = '<?php echo $ErrorUrl?>';</script>
【问题讨论】:
-
你没有添加
<?php和?>标签。
标签: javascript php iframe