Hello, i need a script that has an input feild and the input is URL's. when a go button is clicked the url open in an inline frame. if you could write in a Back/Forward Script that'd be great.
PS. if it isnt conceivable please tell me.
Hello, i need a script that has an input feild and the input is URL's. when a go button is clicked the url open in an inline frame. if you could write in a Back/Forward Script that'd be great.
PS. if it isnt conceivable please tell me.
Its doable... at a rough guess (not tested this script)Originally Posted by boxxertrumps
your iframe would be something like thisHTML Code:<input type="text" name="url" id="url"> <input type="button" onclick="showurl">
and the Javascript code would look likeHTML Code:<iframe name="theiframe" id="theiframe">
for the forward and back i think this will workCode:function showurl(){ if (document.getElementById('url').value != ""){ theiframe.location = document.getElementById('url').value; } else { alert('No URL Entered'); } }
not tested any of that tho going off memoryHTML Code:<a href="Javascript:;" onclick"theiframe.history(-1);">
Close but, with several errors, try:
Note: The back link will take you to the previous page in the history stack (if any) if there is nothing to go back to in the iframe. By launching the above page as a new window, that should eliminate that possibility.Code:<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd"> <html> <head> <title>Mini Browser</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <script type="text/javascript"> function showurl(){ if (document.getElementById('url').value != "") theiframe.location.href = document.getElementById('url').value; else alert('No URL Entered'); } </script> </head> <body> <input type="text" id="url"><br> <input type="button" onclick="showurl();"><br> <iframe name="theiframe"></iframe><br> <a href="javascript:void(0);" onclick="history.go(-1);return false;">Back</a> <a href="javascript:void(0);" onclick="history.go(1);return false;">Forward</a> </body> </html>
- John________________________
Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate
Hey try this out: http://captninsano.tripod.com/browser.html
Recently Updated!!![]()
(Works in FF 1.5 IE 5-6 but unfortunately not in OperaHas an extra feature{shows history when Ctrl is pressed})
If you are searching for something like that then I can provide you the code(freely distributable with appropriate credits). If you are not searching for something like that then it's not a problem at all.![]()
The stop and refresh buttons can get you into trouble in FF and also cancel the history list feature in that browser. The page jumps from left to right when using the history and individual entries in the history reveal feature do not each have their own line.Originally Posted by shachi
- John________________________
Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate
The jumping page was made on purpose(so as to make it look like FF) and by the way I didn't get how can i get into trouble if I use the stop and refresh buttons??Originally Posted by jscheuer1
And can you also tell me why "history reveal feature do not each have their own line" I would try to show it in a single line if it is not correct.
![]()
The history lines could probably be fixed easily enough, if you are using an element's innerHTML to write them out, simply by inserting <br> tags after each entry after you append it. A nice touch would be to construct the list in such a way as to make each item a link to itself, with the target being the iframe.Originally Posted by shachi
I would think that Stop and Refresh should either be skipped or work as in a browser. If I hit Stop in the browser and then refresh, the page I was loading reloads and the history remains intact, neither of those happened.
These things could probably be achieved with (a) session cookie(s).
With the jumping history, to make it like FF (IE does this too) you could use an iframe or scrolling division (probably best) or frame to contain the history. This would make it more like those browsers are when their history buttons are clicked.
I realize that when designing something like this that there often is a tendency not to try and 'push the envelope' on the features when testing but, these thing will be done, as a matter of course, by individuals using the design.
Overall, I should mention that the design looked nice but, with its reliance on javascript and the fact that at best, it merely duplicates what the user has before them to begin with, I wonder about its usefulness. These reservations apply to this thread in general but, it is an interesting exercise.
I wonder why the OP wanted something like this to begin with.
- John________________________
Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate
The Internet Does Care... and here's the finished product.
MY PAGE!
Nice glad the JS code worked,... well once it got the bugs taken out lol like i said was coded from memory and didnt have chance to check it overOriginally Posted by boxxertrumps
It was just made as an experiment(you know it as you helped me making it) not in a way to give some facilities to people(because I knew that people would already have a browser to see one like that). And I still don't know how to make cookies(as I am just a beginner).Originally Posted by jscheuer1
But anyways if you wish then you can make some changes in it too.
![]()
If you wish
Bookmarks