Using Favicon With Bookmarklets -


i have bookmarklet webservice. bookmarklet link's code :

(spaces added readability)

javascript: void((function () {     var e = document.createelement('script');     e.setattribute('type', 'text/javascript');     e.setattribute('src', 'http://www.girmiyor.co.cc/bookmarklet.js');     document.body.appendchild(e) })()) 

and want add favicon bookmarklet link. found this post it.

they give example javascript code adding favicon

javascript:’<!doctype html><html><head><title>hello world</title><link rel=”icon” type=”image/png” href=”http://www.tapper-ware.net/devel/js/js.bookmarklets/icons/next.png” /></head><body>hello world</body></html>’; 

i want use method on bookmarklet code. have combine codes. isn't work.

readability version :

javascript: void((function () {     document.write('<html><head><link rel=\'shortcut icon\' href=\'http://www.girmiyor.co.cc/favicon.ico\'/></head></html>');     var e = document.createelement('script');     e.setattribute('type', 'text/javascript');     e.setattribute('src', 'http://www.girmiyor.co.cc/bookmarklet.js');     document.body.appendchild(e) })()) 

original version :

javascript:void((function(){document.write('<html><head><link%20rel=\'shortcut%20icon\'%20href=\'http://www.girmiyor.co.cc/favicon.ico\'/></head></html>');var%20e=document.createelement('script');e.setattribute('type','text/javascript');e.setattribute('src','http://www.girmiyor.co.cc/bookmarklet.js');document.body.appendchild(e)})()) 

i think got totally wrong example. don't need document.write html tags directly. suggest read again article , understand branching does.

i'm sorry if i'm not more specific, repeat same that's on article linked.


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -