Why is the PHP site created under Windows IIS only able to navigate through the homepage? Ask for directions

Source: Internet
Author: User
Tags php website yii
Why is the PHP website created under Windows IIS only able to browse the homepage properly??? Ask for directions
Companies looking for the outside of the site production company to do a website (PHP, using the YII framework), the original site is renting someone else space (linux+apache+mysql), now the leader wants to put the site on its own server (windows2008), Now in our own server PHP running environment has been set up, the source of the site can only browse the home page, for the link in the home page can not be normal browsing, click on the prompt 404 error. For example: About us this link to/CATEGORY/4, but in the site root directory can not find the category directory, I am very strange that this site in the original rented space is not a problem, why to me here can not????? I am sure all Web files have been downloaded by FTP
Is it related to the YII framework and what settings do I need to make? (I do not understand the PHP and Yii framework), to ask the understanding of the direction of the maze

Share to: more


------Solution--------------------
Adjust the routing pattern for YII projects

Apache can easily support URL rewriting, and IIS is not that easy.
Need to install rewrite plug-ins, in the genuine system to install pirated plug-ins, always not very good. Although there is a lot of free, but functionally weak. And I don't know if I can meet your needs.
------Solution--------------------
Apache, too?
So, turn on URL rewriting, okay?
------Solution--------------------
I guess that's the problem with URL rewriting.
------Solution--------------------
References:

The Apache configuration does not understand, just a bit Baidu after the URL rewrite opened, now no 404 error, but will be directly linked to the original site under the domain name
For example, my local test URL is: http://192.168.1.8/, when clicked "About Us" (link "category/4"), now run to the original website domain name down HTTP://WWW.XXXXXXX.COM/CATEGORY/4
Can I modify this route so that he adapts to the current website address????

Then you modify the. htaccess file, or modify the conf.php file.
  • 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.