1

I would like to display the URL preview entered by the user like skype app in . For example if i am entering a youtube url in the skype app to other person , it is automatically displaying the thumbnail preview of that URL entered by the user.

https://www.youtube.com/watch?v=QUgRDYehv0M

When i have entered above url means.. Skype automatically showing the thumbnail preview of that link like below:

enter image description here

Like skype i would like to do in android. Whenever if user enters any url means.. i need to show the preview of an url..

https://play.google.com/store/apps/details?id=com.leocardz.link.preview&feature=search_result

Refered above app.. anyother help or guidance will be helpful.

Phantômaxx
  • 37,901
  • 21
  • 84
  • 115
Rotomac17
  • 239
  • 3
  • 16
  • 3
    Hey Rotomac you can find from here. https://github.com/LeonardoCardoso/Android-Link-Preview?utm_source=android-arsenal.com&utm_medium=referral&utm_campaign=2755 – Mehul Patel Jan 10 '18 at 09:08
  • Possible duplicate of [How do I create url preview in android?](https://stackoverflow.com/questions/34917503/how-do-i-create-url-preview-in-android) – Akshay Jan 10 '18 at 09:53

1 Answers1

1

You can import the library using Gradle :

Simply add the repository to your build.gradle file:

repositories {
    jcenter()
    maven { url 'https://github.com/leonardocardoso/mvn-repo/raw/master/maven-deploy' }
}

And you can use the artifacts like this:

dependencies {
    compile 'org.jsoup:jsoup:1.8.3' // required
    compile 'com.leocardz:link-preview:1.2.1@aar'
}

You can refer this link for more details.

Mitesh Shah
  • 192
  • 4
  • 16