5

This is my website: http://www.stustu.co.uk..

I want to create an app that can pull down the listings from this website and display the entries in the form I want; enable users to manage their online accounts conveniently within the app; post new entries. Basically, a similar app to Amazon and eBay.

But I've no clue about how to query the information from the website in the app... The website itself is WordPress based (quite simple, therefore), and my initial thought was to find some API from WordPress. I did find the official WordPress app, which comes with the source code, but it helps little as its code mainly deals with blogging.

So here's my question:

  1. What are the normal ways a web developer would use on the server side to achieve my aim?
  2. Is that achievable for WordPress?
  3. If not, are there workarounds?

I'm a new self-taught developer, sorry that the question is a bit broad.

Matt Ball
  • 332,322
  • 92
  • 617
  • 683
L__
  • 786
  • 1
  • 7
  • 15

2 Answers2

2

The most common approach when you're trying to communicate between an app and a website is to use a web service. Popular architectures include using REST or SOAP to communicate with your server.

This video will teach you how to use REST interface properly on your Android application, while in this link you will find that using SOAP has its disadvantages over REST especially on Android(or mobile in general).

I personally recommend using REST APIs with responses in JSON format for your web service. Twitter did the right thing with their own rest api, and you can structure yours similarly.

Other links you will be finding useful as you develop your application:

google-gson

jackson JSON

http://blogs.developerforce.com/developer-relations/2011/02/rest-api-android-awesome.html

Sorry about not answering your question about Wordpress, as I never had the opportunity to use it. For my apology, have this potato.

Community
  • 1
  • 1
josephus
  • 8,148
  • 1
  • 35
  • 53
1

How much experience do you have with android? If you have none you should go find the getting started tutorials on the developer site and complete a few of them to familiarize your self with the structure of an android application before you attempt something like this.

The next thing to consider is: does your site look and act nicely on mobile? If so do you want your application to simply be a dedicated browser that pulls up your site? Or do you want to create the entire application natively? In the latter case you'll have to build (or find) some sort of APIs that allow you to tie in to the functionality of your site from within the java in the application.

My experience is mostly on Android so I cannot suggest any strategies or examples for how you'd go about setting up your APIs. But I do know if you attempt to build something that sophisticated natively on android with little experience you'll likely get frustrated early.

FoamyGuy
  • 45,328
  • 16
  • 118
  • 151