Ask how to jump based on conditions

Source: Internet
Author: User
I would like to know how to jump to a website based on the visitor's access conditions. For example, a visitor directly enters the website to jump to www.a.com, and a visitor searches for the website to go to www. B .com. I would like to ask how to implement it. for beginners, php only understands a little basic syntax ------ solution ------------------ only by clicking the link to get the path. in most cases, the user's access location cannot be correctly determined.
Now you want to jump to a website based on the visitor's access conditions.
For example, a visitor directly enters the website to jump to www.a.com, and a visitor searches for the website to go to www. B .com.
How can I implement it? for beginners, php only understands a little basic syntax.

------ Solution --------------------
You can only obtain the path by clicking the link.
In many cases, the user's access address cannot be correctly determined, that is, the access condition you mentioned.

You don't need to worry about it later.

------ Solution --------------------
Are you talking about redirection?
PHP code
Header ("laocation: http://www. B .com ");
------ Solution --------------------
Use jquery to obtain the values in the input box, and then determine if else. if the values meet the requirements, use header ("location: // http .......)

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.