Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [inne][XML]Serwisy Łebowe SOAP.Jak napisać klienta ?
hop
post
Post #1





Grupa: Zarejestrowani
Postów: 14
Pomógł: 0
Dołączył: 4.03.2009

Ostrzeżenie: (0%)
-----


Witam i pozdrawiam

Mam pewną książkę jest w niej opisany dostęp do serwisu Łebowego Amazon.W książce jest między innymi taki tekst:

Cytat
Web services are getting a lot of hype. In the end, however, they are simply an HTTP request and response whereby each may be carrying XML data. So using a Web service from Cocoa is simply a matter of being able to send HTTP requests and receive responses. It also may require generating and parsing XML.


i jest kawałek programu:
Kod
// Get the string and percent-escape for insertion into URL NSString *input = [searchField stringValue]; NSString *searchString =
[input stringByAddingPercentEscapesUsingEncoding: NSUTF8StringEncoding];
NSLog(@"searchString = %@", searchString);
// Create the URL (Long string broken into several lines is OK) NSString *urlString = [NSString stringWithFormat:
@"http://ecs.amazonaws.com/onca/xml?"
@"Service=AWSECommerceService&"
@"AWSAccessKeyID=%@&"
@"Operation=ItemSearch&"
@"SearchIndex=Books&"
@"Keywords=%@&"
@"Version=2007-07-16", AWS_ID, searchString];
NSURL *url = [NSURL URLWithString:urlString]; NSURLRequest *urlRequest = [NSURLRequest requestWithURL:url
cachePolicy:NSURLRequestReturnCacheDataElseLoad timeoutInterval:30];


Teraz moje pytanie: Czy w ten sposób można wywołać odpowiedź kaźdego serwisu, przy pomocy tego przydługiego adresu URL wpisanego np. w przeglądarce?
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 25.12.2025 - 02:28