Ucenter integration, communication failure, debugging and testing troubleshooting methods

Source: Internet
Author: User
Tags sql error

This article introduces the ucenter integration, communication failure, and debugging and testing troubleshooting methods. I hope this method will be helpful to you.

The failure is caused by the api/uc of your application. php may have errors. for example, ucenter rules. only uc. if the php file returns 1 normally, a message indicating successful communication is displayed. however, if you return an SQL error. instead of 1, it must be a failure prompt. how to test it?

The Code is as follows: Copy code

<? Php
Include_once "config/config_global.php ";
Include_once "config/config_ucenter.php ";
Include_once "uc_client/client. php ";
Echo uc_user_synlogin (2); // 1 indicates the user ID

?>
<Script type = "text/javascript">
Var obj = document. getElementsByTagName ("script ");
For (var I = 0; I <obj. length-1; I ++ ){
Document. write ("<a href =" "+ obj [I]. src + ">" + obj [I]. src + "</a> }
</Script>

The above code is saved as test. PHP file. put it in the root directory of your dz forum or ucenter and use the domain name directly. com/test. php to see if any error is prompted. of course. uc. PHP File

Error_reporting (0); comment out this sentence first. The error will be displayed more clearly. After the error is found, add this sentence. Otherwise, the communication may fail.

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.