Javascript-android Connect to a PHP service now, how do you do it?

Source: Internet
Author: User
Everybody, go ahead, guys.
My little brother recently started practicing writing programs,
To do an Android program is to perform the existing Web service,
The Web service is probably a user account password, and can be entered into the list of the press, and print out a PDF or Excel.
If you were a former my life, how would you complete this program?
Grateful

Reply content:

Everybody, go ahead, guys.
My little brother recently started practicing writing programs,
To do an Android program is to perform the existing Web service,
The Web service is probably a user account password, and can be entered into the list of the press, and print out a PDF or Excel.
If you were a former my life, how would you complete this program?
Grateful

If the PHP service is a Web page and there are no special features, you can load the page directly WebView .

Or just follow this step roughly:

  1. Define the functionality and then determine the API that the server provides

  2. Writing Android interface and business, network connection can use the framework such as Okhttp,retrofit,androidasynchttp.

Direct access to the source code with Jsoup parsing, if the Web page data is obtained with JS dynamic, the Catch JS call API line.

With WebView, you can embed a browser directly without the hassle.

  • 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.