I know that I can put a link in a UITextView such as "http://stackoverflow.com/" and have it auto detected. I want to know if there is a way to set the UITextView so that the link appears as "Visit StackOverflow" in the UITextView, or if I have to use a UIWebView to do that. I'm fairly sure that I have to use a UIWebView, but I want to make sure.
As far as I'm aware you can't do that, and from reading other posts it appears that there is an undocumented method, but that would get you app rejected (http://stackoverflow.com/questions/2454067/display-html-text-in-uitextview). Why not simply use a web view? As that is what it is designed for! ;)
Jonathan
Related
I am building an app, and would like to create this feature.
"By using our services, you agree to our terms of service"`
This label/text should also be localisable in Japanese and German,
and when the user clicks on Terms of Service, the app should launch a webview to an external website.
I've tried UILabel and ActiveLabel, but they don't seem to be able to localise/translate.
Anyone have any ideas or suggestions?
Thanks and appreciated.
I've tried UILabel and ActiveLabel, but they don't seem to be able to
localise/translate.
ActiveLabel is merely a subclass of UILabel and I use it the same case with you for a tappable labels that opens up a UIWebView, therefore you can just pass a localised string to your activeLabel object easily.
For more information on how to do localisation, there are tons of resources here on Stackoverflow, Youtube, and Google.
Sample: https://www.youtube.com/watch?v=IV1x9FgQ5v0
I am working at chatApplication where i need to enable the phone number and link detection while magnifying property set to no like whatsApp and iMessage do. What component should i use for that?
go with the textview. because it'll be also possible with textview to detect number and link. webview also good option.
but as you mention, you want to make chat Application than if you also want to provide the functionality for select,copy,etc. than Textview is the good one.
I've seen this used in some apps and I can't seem to figure out how it's done - there seems to be nothing to set. When I set the url to share, it doesn't pop up automatically either, and I can't find any reference to it anywhere on the Internet which makes me feel like an idiot. Any possibilities? It's not urgent anyway I'm just curious. Thanks.
Screenshot of iOS Device with the UIActivityViewController visible with the URL bar:
http://twitter.com/SunburstEnzo/status/617736706402484224/photo/1
Edit: I can't believe I need 10 reputation to show you my problem.
There's no built-in way to do this. However, there's a third-party component named JDSActivityVC which enables you to achieve this effect.
It's just a subclass of UIActivityViewController that adds a custom UIView with an UILabel.
I have one doubt that how exactly GIF images loaded into Custom keyboard and user can send it. I am new in iOS so want some link which i can refer and will be helpful for me.
Read Apple docs for this, especially this one https://developer.apple.com/library/ios/documentation/General/Conceptual/ExtensibilityPG/Keyboard.html is a good strating point
You can set any UIView as the view for the keyboard layout, so an UIImageView is suitable for your purpose. The real difficulty in custom keyboarding is the management of events. As you are new to iOS dev, I would like to encourage you to try much simpler things first.
I have this help page I want to add to my application, but I'm not sure of how to format it. At the moment it's just an image in a scrollview, but surely there's a better way?
Many apps use a WebView to display formatted text. You can then use CSS to style your content as needed.
You could use NSAttribuatedString + RTLabel to display it (or of cause the default cheat of a UIWebView).
To display RichText (NSAttribuatedString use one of these).
http://www.cocoacontrols.com/platforms/ios/controls/rtlabel
https://github.com/Cocoanetics/NSAttributedString-Additions-for-HTML
http://www.cocoanetics.com/2011/01/uiwebview-must-die/
https://github.com/AliSoftware/OHAttributedLabel
https://github.com/mattt/TTTAttributedLabel
Use webview to and with webservices so u can change it later so on