我應該做重定向到另一個網頁?我在評論中有失敗的嘗試。重定向到另一個頁面PHP
case 6:
//$redirectLocation = "http://www.productionportugal.com/blog";
// header'Location: ' . $redirectLocation); assume it like homepage
//include '/blog/index.php';
//include 'blog/index.php'; database error
//ini_set('include_path', '/blog');
//set_include_path('/blog');
// include_path=".:/blog" white page
// include="/blog/index.php"
// $redirectLocation = "http://www.productionportugal.com/blog";
require_once dirname(__FILE__) . '/Blog.php';
$_blog = new Blog();
$menuL = $_blog->getMenu();
$conteudo = "<div class='container' id='blogMenu'>
<div class='titulo'>$nome
<div class='btn-group'>
<a href='#' data-toggle='dropdown' id='dropdownBlog'>
<span class='caret'></span>
</a>
<ul class='dropdown-menu' aria-labelledby='dropdownBlog' role='menu'>
$menuL
</ul>
</div>
<a class='sprite leftS' id='prevLatestBlog'></a><a class='sprite rightS' id='nextLatestBlog'></a></div>
</div>";
$conteudo .= $_blog->getALL();
break;
我試過這個,但它指派的功能,如主頁$ website =「http://www.productionportugal.com/blog」; header(「Location:」。$ website); –
嘗試寫這樣的:標題(「位置:http://www.productionportugal.com/blog」);你會得到什麼錯誤? – itay
它會假設像一個網頁的鏈接,我要的就是按一下按鈕,然後轉到外部頁面。 –