General :  K-Meleon Web Browser Forum
General discussion about K-Meleon 
Running Java Script Bookmark
Posted by: The Dave
Date: December 18, 2009 03:39PM

Can any assist me in setting up K-Melon to run the following bookmark - this bookmark works in Mozilla, SeaMonkey, Google Chrome, Flock, Opera, Orca.
Thanks, Dave

javascriptsad smileyfunction()%7Bvar%20a%3Ddocument.createElement(%22script%22)%3Ba.type%3D%22text%2Fjavascript%22%3Ba.src%3D%22http%3A%2F%2Fwww.spockholm.com/mafia/unframe-beta.js%3F%22%2BMath.random()%3Bdocument.getElementsByTagName(%22head%22)%5B0%5D.appendChild(a)%7D)()%3B

Options: ReplyQuote
Re: Running Java Script Bookmark
Posted by: JujuLand
Date: December 18, 2009 08:23PM

Here is a 'translation' of this function:

javascript function(){var a=document.createElement("script");a.type="text/javascript";a.src="http://www.spockholm.com/mafia/unframe-beta.js?"+Math.random();document.getElementsByTagName("head")[0].appendChild(a)})();

A word in the URL is strange for me : mafia

As I don't really understand what it does, I surelly don't test it ... I don't like a function that create a script, and probably take it and execute it.

Virus ? trojan ?
No confiance ...

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc





Edited 3 time(s). Last edit at 12/18/2009 08:26PM by JujuLand.

Options: ReplyQuote
Re: Running Java Script Bookmark
Posted by: desga2
Date: December 20, 2009 12:42PM

I think this is a bookmarklet to obtain Facebook IDs.
Look his main page.

K-Meleon in Spanish

Options: ReplyQuote
Re: Running Java Script Bookmark
Posted by: disrupted
Date: December 20, 2009 05:16PM

yes it sounds like it's face book gift sending thing so probably safe.. it could very well be injectable in a macro but the js gets dirty when copied..needs to be cleaned first and i don't really know how..all those %22 and %20 need to be removed and replaced by white space i think or what's equivalent slashes etc it will never work when dirty and give hiccups inside the macro

Options: ReplyQuote
Re: Running Java Script Bookmark
Posted by: disrupted
Date: December 20, 2009 05:32PM

never mind, found an easy way to clean it up..

click this:tongue sticking out smiley

http://www.google.co.uk/search?hl=en&q=javascript:function%20get_id_from_game%28%29%7Btry%7Bvar%20content%3Ddocument.getElementById%28%27app10979261223_content_row%27%29%3Bvar%20as%3Dcontent.getElementsByTagName%28%27a%27%29%3Bfor%28i%3D0%3Bi%3Cas.length%3Bi%2B%2B%29%7Bif%28as%5Bi%5D.innerHTML%3D%3D%27Profile%27%29%7Bmatch%3D%2F%5B%3B%26%5Duser%3D%28%5Cd%2B%29%2F.exec%28as%5Bi%5D.href%29%3Bif%28match%29return%20match%5B1%5D%3B%7D%7D%7Dcatch%28err%29%7B%7Dtry%7Bvar%20content%3Ddocument.getElementById%28%27app_content_16421175101%27%29.innerHTML%3Breturn%2F%5B%3F%3B%26%5Dopponent_id%3D%28%5Cd%2B%29%2F.exec%28content%29%5B1%5D%3B%7Dcatch%28err%29%7B%7Dreturn%20null%3B%7Dfunction%20get_id_from_fb%28%29%7Bfunction%20f%28expr%29%7Btry%7Breturn%2Fid%3D%28%5B0-9%5D%2B%29%2F.exec%28eval%28expr%29%29%5B1%5D%3B%7Dcatch%28e%29%7Breturn%20null%3B%7D%7Dreturn%20f%28%22document.getElementById%28%27profileimage%27%29.parentNode.innerHTML%22%29%7C%7Cf%28%22document.getElementById%28%27profile_name%27%29.parentNode.innerHTML%22%29%7C%7Cnull%3B%7Dfunction%20get_id%28%29%7Breturn%20get_id_from_fb%28%29%7C%7Cget_id_from_game%28%29%3B%7Did%3Dget_id%28%29%3Bif%28id%29%7Bmatch%3D%2Fgift_key%3D%28%5B0-9a-f%5D%2B%29%2F.exec%28document.body.innerHTML%29%3Blocation.href%3D%27http%3A%2F%2Fheartrate.se%2Fgive%2F%27%2Bid%2B%27%2F%27%2B%28match%3F%27with_key_%27%2Bmatch%5B1%5D%3A%27%27%29%3B%7Delse%7Bkey%3Ddocument.getElementById%28%27app10979261223_gift_key%27%29.value%3Bif%28key%29%7Blocation.href%3D%27http%3A%2F%2Fheartrate.se%2Fgive%2Fwith_key_%27%2Bkey%3B%7Delse%7Balert%28%27ERROR%3A%20Could%20not%20find%20id%20or%20gift%20key.%20You%20should%20use%20this%20bookmarklet%20either%20from%20the%20Mafia%20Wars%20profile%20page%20of%20a%20friend%20with%20wishlist%20items%2C%20or%20from%20your%20own%20gifting%20page.%27%29%3B%7D%7D&btnG=Google+Search&meta=

Options: ReplyQuote
Re: Running Java Script Bookmark
Posted by: disrupted
Date: December 20, 2009 06:00PM

this seems to be working but i can't be sure because i'm not a wise guy or know what site exactly where it should work, please test and see

save this macro kmm in you k-meleon\macros folder
http://kmext.sourceforge.net/macros/sendmafiaagift.kmm

restart kmeleon and select send mafia a gift from your bookmarks menu (will require bookmarks to be enabled)




Options: ReplyQuote
Re: Running Java Script Bookmark:cool:
Posted by: sopan
Date: February 11, 2011 03:30PM

Quote
JujuLand
Here is a 'translation' of this function:

javascript function(){var a=document.createElement("script");a.type="text/javascript";a.src="http://www.spockholm.com/mafia/unframe-beta.js?"+Math.random();document.getElementsByTagName("head")[0].appendChild(a)})();

A word in the URL is strange for me : mafia

As I don't really understand what it does, I surelly don't test it ... I don't like a function that create a script, and probably take it and execute it.

Virus ? trojan ?
No confiance ...

A+


Options: ReplyQuote


K-Meleon forum is powered by Phorum.