Creating a scroll down form using java - is this the code?
I am trying to understand the code (if this is even the code) which comes from thisnext.com website. Basically it allows any user surfing any website to post recommendations. Im interested to know what does the codes me开发者_JAVA百科an.
javascript:(function() {
var x=document.getElementsByTagName('head').item(0);
var so=document.createElement('script');
var h=location.hostname.split('.');
var a=new Array();for(i=h.length-1;i>=0;i=i-1){a[a.length]=h[i];}var d=a.join('/');
var s='http://www.thisnext.com/js/bookmarklet/'+d+'/';
if(typeof so !='object') so=document.standardCreateElement('script');
so.setAttribute('src',s);so.setAttribute('type','text/javascript');
x.appendChild(so);
})();
Thank you in advance!
The script loads some sort of script (probably some sort of JSONP setup) from that site (thisnext.com). It does it by creating a new script element and then building a URL based on the current URL (the URL of the page with the script on it).
I edited the code to get rid of the "%20" characters; those are there because the script is probably set up to be used as a bookmarklet.
The direct answer to your question is "no". That script may load some other code that does what you're looking for, but that script does not do anything of the sort.
精彩评论