tags:

views:

30

answers:

2

hi i am new to iphone. what i need is i have to place a url as a string eg:http://stackoverflow.com by selecting the string it self open in a web brosewr how can i done this. post some code or link thank u.

A: 

To open A url use (in Objective-C) [[UIApplication sharedApplication] openURL:[NSURL URLWithString:URLHere]];

puckipedia
i think u r are not getting my point. for example there is five line of text in that text when i click selected text that will hyperlink to url how can i done this
MaheshBabu
A: 

Add a textView control onto your NIB file. Put whatever content (you mention 5 lines of text) you want in here. In the properties for this control, under the "Detection" section, click "Links". Then, any URL links in this text will be automatically highlighted in blue, and when your users tap on it they will be taken to that URL in the browser.

Your question could have been a little clearer - I only got what you were after because of your previous comment on puckipedia's answer...

h4xxr