code翻译:ASP.NET Server.Transfer的在PHP [英] Code Translation: ASP.NET Server.Transfer in PHP

查看:174
本文介绍了code翻译:ASP.NET Server.Transfer的在PHP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将如何在PHP中做到这一点?

How would I do this in PHP?

Server.Transfer("/index.aspx")

(添加';'为C#)

(add ';' for C#)

编辑:

要具有的URL保持与以前相同是很重要的;你知道,谷歌。在我的情况,我们有一堆的,我们要转移.html文件,它是在客户端的地址栏并没有改变重要的。

It is important to have the URL remain the same as before; you know, for Google. In my situation, we have a bunch of .html files that we want to transfer and it is important to the client that the address bar doesn't change.

推荐答案

据我所知PHP不会有一个真正的转移能力,但你可以通过使用包括()或要求(得到完全相同的效果),如所以:

As far as I know PHP doesn't have a real transfer ability, but you could get the exact same effect by using include() or require() like so:

require('/index.aspx");

这篇关于code翻译:ASP.NET Server.Transfer的在PHP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆