The best solution to this problem: First, create a Textview.
<TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/link" android:layout_alignParentBottom="true" android:layout_alignParentEnd="true" android:text="@string/developed_by_bracecodes"/>
Then add the text to the text view from strings.xml as shown below:
<string name="developed_by_bracecodes"><a href="http://www.bracecodes.com">Developed by Bracecodes</a> </string>
NB: don't forget to add http: // in front of your link
Then add these lines to your Java code:
TextView link = findViewById(R.id.link); link.setMovementMethod(LinkMovementMethod.getInstance());
Good coding! Thanks!
source share