tags:

views:

180

answers:

5

Basically, I'm looking to create a simple music playlist platform but in the form of webpages. Users create playlist, add songs to it, and other users can view these playlists.

But the website must use SOAP to send and retrieve data. How is this possible? Is this possible?

+2  A: 

SOAP is designed to enable computers and programs to talk to each other. You would be a sadist to make users interact directly with a website via SOAP ;)

If your want your site to allow users to submit their data with custom clients (not web browsers) for example, a music player that automatically uploads playlists to a website, then SOAP might be a perfectly good protocol for the player and your site to communicate said data.

Your site can take advantage of pre-written SOAP implementations such as Apache Axis, as suggested by ajborley, and then the client side (e.g., a music player plugin) might need to be your own implementation.

Mike Atlas
I think what he means is he wants to implement a SOAP client as part of a larger web application.
Ryan Lynch
I am looking for users to submit their data using web browsers. Initially it was going to be done in visual basic but it is easier for me to make it look "prettier" by making a website, but it has to use SOAP.
weedave
Is it a homework project? You really don't need to use SOAP if the client is a human using a web browser.
Mike Atlas
(Unless the server only accepts SOAP as an input method in which case you'd have to use something like Ryan Lynch's solution on this page)
Mike Atlas
Yeah it's a university assessment. We can just have the client being a windows executable but I don't know how to make it look nice, and the lecturer has said it can be a website if we want.
weedave
I think you'll find that implementing SOAP in a win client to be easier than implementing it in a web page (eg with JavaScript or Flash) as there is complete built-in support for speaking SOAP in things like the .NET framework.
Mike Atlas
PS. Looking nice doesn't mean much if it doesn't work!
Mike Atlas
Fair point, I think I'll work on getting it to work using VB then look into making it a webpage.
weedave
+2  A: 

If you want to use SOAP, a good place to start would be with Apache Axis which is a Java-based SOAP/WSDL framework - Axis also has the advantage of supporting RESTful services, which is perhaps more what you want.

To get started you want to:

  1. Define your playlist data structures that will be passed around by your services and stored in your system
  2. Define the service interface - what are the list of operations you want the service to be able to do? What would be the inputs and outputs to each operation?
  3. Decide what your storage is going to be - flat file, DB, etc, and what is going to be stored & how.
  4. Implement it! If you're doing SOAP you'll want WSDL, XML schemas and service and client implementations.

If you want your user interface to be Web browser based, but still must use SOAP, then you will need to create an HTML presentation layer that contains a SOAP client, that itself calls your SOAP service. For the HTML/SOAP client layer, you could use use one of the SOAP libraries for PHP or Javascript or something like Java servlets or JSPs.

ajborley
A: 

SOAP can play a good role in the infrastructure of a complex back-end implemented in different technologies. I had experience developing client-side application which communicated to back-end in SOAP through a tiny JSON2SOAP server-side front-end. I doubt this is neccessary in your case though.

Sergey Ilinsky
+1  A: 

If you want to implement a Javascript solution on the client, you'll need to write some client code to make the requests and parse the returned xml. Google 'javascript soap client' and you'll find code and tutorials, like this jQuery plugin. If you use something like Flash on your page, it already has classes that you can use to abstract the interface to the remote service in your application. The server side part of it really depends on what you are using there, so you'll have to look at the documentation for your server / framework for how to go about setting up a SOAP service.

Ryan Lynch
I'm using VB code on the server side, would I still be able to use javascript? Googling that brought up a lot of useful examples. :)
weedave
SOAP is the interchange format, so as long as your service can parse SOAP requests and send SOAP responses, and you client can do the opposite, the specific implementation of either one is independent of the other.
Ryan Lynch
+1  A: 

ASP.net with Visual Studio makes creating and consuming web services pretty simple. Someone mentioned javascript. You may want to create a web service as part of a website, then let the site create javascript proxy methods for interacting with the web service or services.

This page was helpful when I did something like this

http://www.asp.net/AJAX/Documentation/Live/Tutorials/ConsumingWebServicesWithAJAXTutorial.aspx

Josh Warner-Burke