1

I'm developing a browser for android. I simply need to create one search editbox with a history button.

When the user clicks 'history' button, up to five recent visited webpages should be presented.

I don't know where to start... Because I have no idea on how to do this...

franzlorenzon
  • 5,845
  • 6
  • 36
  • 58
sanjay
  • 2,590
  • 17
  • 55
  • 88

2 Answers2

1

You don't need a custom browser for that. You can embed a WebView in your app.

http://developer.android.com/reference/android/webkit/WebView.html

In this, you can get last 5 pages from History using JavaScript and display those URLs.

Shamit Verma
  • 3,839
  • 23
  • 22
0

You should check WebView in android

http://developer.android.com/reference/android/webkit/WebView.html

If you want to customize it , extend webview class and you can go ahead from there.

sat
  • 40,138
  • 28
  • 93
  • 102
  • thanks for ur reply..But i just wanna know how to retrieve last 5 visited web pages?& even when i click any one i've to go to that page.. – sanjay Mar 15 '11 at 10:53
  • For that you will have to use Content providers of Browser , some examples suggests that you have to use bookmark content provider and extract bookmarks http://stackoverflow.com/questions/2577084/android-read-browser-history . This might help you. Once you get bookmarked url , its easy to launch that website using loadUrl API of webview. – sat Mar 15 '11 at 10:58