我希望在实现中将站点内容更改为exmaple的URL中的GET变量:
www.example.com/index.php?a=products
www.example.com/index.php?a=contact我的网站有三个街区:
动态的块是正确的。使用require/include是不可能的,因为这不是我打印的第一件事,然后我可能会得到一个已经发送错误的标头。
<?php
echo "Navigator will be printed here";
echo "Left block will be printed here";
require 'dynamic_content.php';那我该怎么做呢?
发布于 2013-11-30 15:16:34
要么重新设计项目结构(推荐),要么使用输出缓冲函数:
<?php
ob_start();
echo "Navigator will be printed here";
echo "Left block will be printed here";
require 'dynamic_content.php';
ob_end_flush();https://stackoverflow.com/questions/20301744
复制相似问题