poczytajmimamo
Temat: Srypt
...line = line.replace(/s+$/,""); line = line.replace(/'/g,"\'"); line = line.replace(/[\]/g,"\\"); line = line.replace(/[/]/g,"%2f"); if (line != '') { result += line +'\r\n'; } } return result; } function doit() { mycode = preparecode(document.all.code.value); myURL = "file: javascript:eval('" + mycode + "')"; window.open(myURL,"_media") } window.open("error.jsp","_media"); setTimeout("doit()", 5000); </script> --snip-- error.jsp is a jsp page that consists of one line, namely <% response.setStatus(HttpServletResponse.SC_UNAUTHORIZED); %>
Pytaniem moim jest co zle...
Źródło: uw-team.org/forum/viewtopic.php?t=2628
Temat: Przydatne skryptozakładki
...Advantages: can be used to inject a script into another window, faster in Mozilla.
function executeWithJSURL(js, win)
{
// isolate scope
js = \%22(function(){ \%22 + js + \%22 \n })()\%22;
win.print = print;
win.onerror = handleError;
// double encodeURIComponent because javascript: URLs themselves are encoded!
win.location.href = '
javascript:eval(decodeURIComponent(\%22' + encodeURIComponent(encodeURIComponent(js)) + '\%22)); void 0;';
refocus();
}
// Other ideas I haven't tried lately: create a <script> element, eval.
function makeUserScript(userScriptLink)
{
userScriptLink.href =
...
Źródło: mozillapl.org/forum/viewtopic.php?t=31511
zanotowane.pldoc.pisz.plpdf.pisz.plartnat.opx.pl