Troubleshooting of Wecenter installation errors on SAE-PHP source code

Source: Internet
Author: User
Let's take a look at an example of how to handle Wecenter errors installed on SAE. I hope this article will help you. Let's take a look at an example of how to handle Wecenter errors installed on SAE. I hope this article will help you.

Script ec (2); script

Today, I actually want to build a community dedicated to building a community for Zephir/Phalcon/Yaf/Docker/Swoole, specifically for the PHP framework of C language and C Language extension, at the beginning, I was very happy. I directly built wecenter and said on the official website that support SAES. I was so confident that the results would not work. I am so confident that mysql does not support host: port? Just modify it.
0x01

Modify system \ Zend \ Db \ Adapter \ Mysqli. php, search for // Suppress connection warnings here., and add the following code above:

The Code is as follows:
// Fix the connection error BUG of SAE add by widuu
If (defined ('in _ SAE ')){
$ Host = $ this-> _ config ['host'];
$ This-> _ config ['host'] = strstr ($ host, ':', true );
$ Port = trim (strstr ($ host ,':'),':');
}
// End by widuu

Modify system \ Zend \ Db \ Adapter \ Pdo \ Abstract. php and search for the Code:

The Code is as follows:
Return $ this-> _ pdoType. ':'. implode (';', $ dsn );

Then replace it with the following:

The Code is as follows:

// Fix the connection error BUG of SAE add by widuu
If (defined ('in _ SAE ')){
$ Host = $ dsn ['host'];
$ Dsn ['host'] = strstr ($ host, ':', true );
$ Dsn ['Port'] = 'port = '. trim (strstr ($ host ,':'),':');
}
// End by widuu
Return $ this-> _ pdoType. ':'. implode (';', $ dsn );
0x02

The pseudo-static mode does not work. Do you know that it is best to look at the official API and convert the pseudo-static mode to the following:

Name: Your Application name
Version: Your version
Handle:

The Code is as follows:
-Rewrite: if (! -D &&! -F) goto "/index. php? % {QUERY_STRING }"

Now, I want to update the Phalcon stuff tomorrow. I also want to update the YAF knowledge. Of course, I will take it one by one. Then Zephir.

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.