We all know that bookmarklets are nothing but some javascript executable code that does something for us when we click on them depending on the function that they are intended for ... My question is:
For example, I have a bookmark, I don’t know, something like this:
javascript:void(window.open('http://www.pdfdownload.org/web2pdf/Default.aspx?left=0&right=0&top=0&bottom=0&page=0&cURL='+document.location.href));
As I understand it, the bookmarklet’s code (with the "& cURL =" tag) gets the URL that is in the address bar of the browser, and then do something with it to get the result. Something similar can be done with the help of a choice, changing some parameters in the bookmarklet (for example, using the "Select Search on Google Maps") and some others.
How can I “decompile” the bookmarklet to get it to get the necessary data (in this case the URL) from the form?
For example, let's say I want to use the above bookmarklet on a web page to provide a form that allows the user to enter a URL, and then click a button to get the result.
I saw other bookmarklets that get the url from "? Input =" and others from "? Url ="
How to transfer bookmarklet functions to a form?
source
share