In php, enter an address to display the content of another website. the address must also be the address I just entered, online, etc.

Source: Internet
Author: User
In php, enter an address to display the content of another website, and the address is also the address I just entered, online and other php environments

I want to enter www.xy.com to directly display the content of the website of the other party (www.a.com/key/a). the displayed address is www.xy.com I just entered.
How can this be achieved? do you need to modify the preparation file,
Thanks.


Reply to discussion (solution)

Use the framework.

To rewrite a URL, you must change the server configuration file.

Use html iframe tags
Http://www.w3school.com.cn/tags/tag_iframe.asp

------------------------------------------------------ AutoCSDN signature file ------------------------------------------------------

Code Farm ?? A farm where coders sow codes and graze ideas!

Use curl functions

This is not a matter of PHP, but of server software.

Apache can be rewritten using rewrite.

Either use the iframe of html

On the html page of www.xy.com, write:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.