iphone - How to extract a value of a string which is there in url -


i have url , want extract part of string.

the url in similar format this: www.google.com?id=10&jkhsds=fg.php.

i want extract value of id. how this?

if create nsurl object, so:

nsurl *url = [nsurl urlwithstring:@"http://www.google.com"]; 

you can use methods of nsurl object whatever need, e.g. scheme, host, port, path, , query.

see here:

http://developer.apple.com/library/mac/#documentation/cocoa/reference/foundation/classes/nsurl_class/reference/reference.html


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -