JavaScript - Strange Behaving Bug
Sorry if the title is not so good! Im trying my best.
I got my new website in jquery and js, but it behaves very strange. It like bugging, and the fading feels not so smooth as it should. Maybe someone know what the problem is? If you go to www.webblord.se/sv/index.php and then click on the first image at the left-panel menu, its a green button with a home image. You will see that the new content dosn't load raelly smooth, more bugging up. And the loading function dosn't disspear... Why :S? Similar TutorialsI am creating web page. I am in the early stages of building. But I have found that my onChange function behaves different on Firefox and IE. It work as it suppose to on Firefox but not on IE. On IE, onChange is not triggered when you select the an option. But triggers when you click the mouse the second time. Here the code, Code: <html> <head> <title>Compatibility Test</title> <script type="text/javascript"> var myScore = 0.1; function correct(val) { alert(val.value); } </script> </head> <body> <center> <font size=7>Welcome to Compatibility Test</font><BR> <I>by<BR>Rohn DeSilva<BR></I> </center> <BR><BR><BR> 1. Who is the father of relativity?<BR> <input type="radio" name="q1" value=2 onchange="correct(this)"> <B>Isaac Newton</B> <input type="radio" name="q1" value=3 onchange="correct(this)"> <B>Albert Einstein</B> <input type="radio" name="q1" value=1 onchange="correct(this)"> <B>Marie Currie</B> <BR><BR> </body> </html> Hi I have a problem with the javascript menu. Currently when you click on the "Login" button then it opens and when you click it again while it is open it closes ands opens again. What I want is when you click the login button while it is open then it closes as toggleable button. I have posted the javascript to this page: http://jsbin.com/uhefoc/edit#javascript,html,live So there it is possible to make realtime updates to the script and see the result real time I also posted the script here so not to break the rules: Code: $(document).ready(function() { $("#login-menu a.signin").click(function(event) { var link = $(this), box = $("fieldset#signin_menu"), inputs = $("#signin_menu .form-input input"); event.preventDefault(); link.toggleClass("menu-open"); box.toggle("signin_menu"); if(link.hasClass("menu-open")) { $("#username").focus(); } else { inputs.val(''); } inputs.bind("focus keydown", function(action) { if((action.type == "keydown" && action.keyCode == 27) || (action.type == "focus" && !link.hasClass("menu-open")) ) { link.trigger("click"); } }); box.mouseup(function () { return false; }); $(document).mouseup(function(what) { if($(what.target).parent("a.signin").length == 0 && link.hasClass("menu-open")) { link.trigger("click"); } }); }); }); Hi all, A piece of code I have been working on has a small issue with bluring off a div and I can't working out why. Basically what I do is append divs to the DOM and on double click I make them editable and when I blur they are none editable and I append a new div into the document. I have quickly knock up a small piece of code to illustrate the problem ... Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <style text="text/css"> .dropArea { color:#757575; font-weight:bold; display:block; margin:0px; border: 1px dashed #999999; background-color:#DDDDDD; left:10px; right:10px; /*width:auto;*/ text-align:center; line-height:20px; } .textEditArea { display:block; margin-bottom:10px; border: 1px dashed #999999; background-color:inherit; left:10px; right:10px; padding:5px; width:auto; } </style> <script> function makeEditable(activeZone) { if (activeZone.className == "dropArea") { activeZone.innerHTML = ""; } activeZone.contentEditable = true; activeZone.className = "textEditArea"; } function doneEditing(activeZone) { // if no HTML added, make it a drop zone if (trim(activeZone.innerHTML) == "") { activeZone.className = "dropArea"; activeZone.innerHTML = "Drop items from or double click to add text"; } else if (activeZone.addDropZoneAlready == undefined) { // add a new drop zone underneath activeZone.title = "Double click to edit text"; activeZone.addDropZoneAlready = "true"; activeZone.zoneType = "textDisplay"; addNewDropZone(); } activeZone.contentEditable = false; } function addNewDropZone() { var dropArea = document.createElement("div"); dropArea.className = "dropArea"; var appendTo = document.body; appendTo.appendChild(dropArea); dropArea.ondblclick = function () { makeEditable(dropArea); }; dropArea.onblur = function () { alert('done'); doneEditing(dropArea); }; dropArea.innerHTML = "Drop items or double click to add text"; } </script> </head> <body onload="addNewDropZone();"> <div onDblClick="this.contentEditable=true;" onBlur="this.contentEditable=false;alert('Done!');" style="background-color:#C0C0C0; width: 500px; height:200px;"></div> </body> </html> The div in the body already works as expected, it alerts "Done!" however divs I append into the document have to blur twice before the onblur fires? I just don't undestand why its doing it. Anybody have any ideas as to what is happening? Thanks, Dale I find this strange, basically the alert is displaying the doc_form[i] ID. But i'm getting a JavaScript error come up in a debugger saying: Code: Uncaught TypeError: Cannot read property 'id' of undefined when trying to get the ID for the variable... PHP Code: //Get HTTP object ready var http = getHTTPObject(); var mysql_q; //Count how many fields are in the form var doc_form = document.guess_word_form; for ( var i = 0; doc_form.length; i++ ) { alert(doc_form[i].id); mysql_q += "&" + doc_form[i].id + "=" + document.getElementById(doc_form[i].id).value; } alert(mysql_q); Hi, I am trying to make an xml file download from my website, so the saveAs window will be open, I checked the forum and found the following code. but instead of saving the xml file it saves the html file. any clue??? are there other ways to do it ? Code: <html> <script type="text/javascript"> function forceSaveAs (filename){ document.execCommand('SaveAs',null,filename) } </script> <a href='/DVEConfiguration.xml' onclick=\"forceSaveAs('DVEConfiguration.xml_export'); return false\">Download</a> </html> I also try to send the xml with the following header but with no success Code: print "Content-type: application/octet-stream\n\n"; print "Content-Disposition: attachment; filename=file.xml;" I have an interval set that runs indefinitely (backgrounds switching) or until the viewer stops it. I've noticed that when I close a tab while it's running and revisit the page, it "doubles" the interval and the backgrounds get mixed up. Refreshing the page returns it to normal. Does anyone know how to fix this? I've tried clearing the interval with window.onunload and window.onbeforeunload. I'm thinking it has something to do with firefox not clearing its cache for the tab. I'll look into disabling that. wait... why am i here???
I have a form that is submitted via jquery into a mysql database using php Code: <form method="post" name="add_loc_form" id="add_loc_form"> <table width="100%" align="center" cellspacing="0"> <tr> <td class="cat"><h2>Add Location</h2></td> <td align="right" class="cat"><a href="#" class="loc_help_a"><img src="{T_THEME_PATH}/images/help.gif" /></a></td> </tr> </table> <div id="loc_help" style="width:95%; display:none; padding:2.5%; background-color:#FFE9D2"> help txt</div> <table width="70%" align="center"> <tr> <td valign="top">latitude</td> <td valign="top"><input type="text" name="loc_long" id="loc_long" size="20" /></td> </tr> <tr> <td valign="top">Longitude</td> <td valign="top"><input type="text" name="loc_lat" id="loc_lat" size="20" /></td> </tr> <tr> <td valign="top">Place name</td> <td valign="top"><input type="text" name="loc_place" id="loc_place" size="40" /></td> </tr> <tr> <td valign="top">Description</td> <td><textarea cols="30" rows="3" id="loc_desc" name="loc_desc"></textarea></td> </tr> <tr> <td colspan="2" align="center" valign="top"><input type="submit" value="add" name="add_loc" id="add_loc" /> <button class="close_add_loc">close</button></td> </tr> </table> </form> Its is then passed to the jquery Code: $("#add_loc_form").submit(function() { var loc_long = $('#loc_long').val(); var loc_lat = $('#loc_lat').val(); var loc_place = $('#loc_place').val(); var loc_desc = $('#loc_desc').val(); var dataString = "loc_long="+ loc_long +"&loc_lat="+ loc_lat +"&loc_place="+ loc_place +"&loc_desc="+ loc_desc; if(loc_long=='') { $("loc_long").css("border-color:red"); return false; } if(loc_lat=='') { $("loc_lat").css("border-color:red"); return false; } if(loc_place=='') { $("loc_place").css("border-color:red"); return false; } if(loc_desc=='') { $("loc_desc").css("border-color:red"); return false; } $.ajax({ type: "POST", url: "./ajax.php", data: dataString, success: function() { $('form').clearForm(); $("#add_map_locations").fadeOut(600); $("#map_add_success").fadeIn(600); } }); return false; }); the php is PHP Code: mysql_query("INSERT INTO table_locations (longitude, latitude, place_name, description, user_id) VALUES ('$loc_long', '$loc_lat', '$loc_place', '$loc_desc', '$user_id')"); The problem is when each entry has a number in it its submitting a rounded number to the database ie loc_long's value is -2.329102 but its submitting -2 for some reason, if you put numbers in the place or description fields its saving as a rounded number as above. If you put text in any of the fields its saving 0 instead of the text. The fields in the database as set to varchar so its not that. Can anyone help please. have a look at this website. www.projectorhire.ie in the contactDetails div the number appears for a split second and then disappears.. it only happens in firefox.. Can anyone tell me what the prob could be? hi i am using an image scroller and i have it on three pages, the pages use the same header, the same css and the same basic structure. such as table content footer the problem is that the scroller works fine on two of the pages but does not work at all on the one page. here is what i am getting on that page Code: Message: 'ElementExtensions' is null or not an object Line: 1898 Char: 3 Code: 0 URI: http://www.mysite.com/lightbox_slideshow/prototype.js Message: Object doesn't support this property or method Line: 705 Char: 41 Code: 0 URI: http://www.mysite.com/lightbox_slideshow/lightbox.js Message: Array length must be assigned a finite positive number Line: 464 Char: 5 Code: 0 URI: http://www.mysite.com/lightbox/js/prototype.js the only common denominator i can see is that the page it does NOT work on is in fact a photo manager page, the other two (that DO work dont deal with photos) i checked the array and the js vars and stuff are different from my photo manager vars (php) so i was thinking maybe there might be a clash of some kind accessing the queries at the same time when the page loads but i dont get any errors other than these. by the way the scroller is black not grey like the others for background. does it sound like from the errors that i am getting that it might be a db query clash of somekind or do you know anything about those errors above that might give me a clue whats going on. thanks Dear all I have been working with with window.promt() and i noticed a weird behaviour. In some cases (i do not known why) my prompt cannot get over a certain limit of characters. But in some other cases it can get as many characters as i want. Anyone know about this? Thanks Alex Hi all, I'm encountering a strange rendering issue with a chunk of code I'm developing. I'm building an object that will construct a drop down-esque menu. The menu has a function (addEntry) to add additional menu items to itself. When the user hovers over a menu entry - I add a class to the element to change the look (basically highlight it). However, when the mose moves over - some strange rendering occurrs and I can't quite seem to figure it out. Please have a look at the following fiddle, and click the link to open the menu. Edit fiddle - JSFiddle So I've started learning Javascript some days ago. Reading 'JavaScript Bible' Seventh Edition. One of the things the book repeatedly says is: use: Code: if(!document.getElementById()) return; (and others like: Code: if(!document.createTextNode()) return; ) to filter out all the browser who are in fact not supporting DOM. As I'm using Safari (and Firefox for testing purpose) the 'document.getElementById()' and therefo DOM is supported. Now, my browsers (both Safari and Firefox) get returned out of the javascript anyway. as simple as: Code: if(!document.getElementById()) return; document.write("testIt!"); the document.write doesn't get executed. Now: I found a simple solutions which seems to work.... partially: Code: if(document.getElementById() == "undefined") return; document.write("testIt!"); This seems to work for Safari, but Firefox still gets returned out of the javascript. I could just omit the if statements to make it work altogether. But that doesn't sound like the best method to me, because (so I've read) it can crash browsers and such. Now my question: Why are my browsers (or javascript for all I care) acting so strange? Is there a way to make the if(!document.getElementById()) work? or is it just a silly rule the writers of the JavaScript Bible made up? Thanks in advance for any help :) for some reason on my site 2 javascipts are acting strange there is obviously a conflict in them but I have no idea when it comes to javascript. My site can be viewed at www.actioncomputing.co.uk The images on the right hand side use a script which makes them open a window with the enlarged image in, the revolving image below just cycles through other jobs i have done. now problem is when the side images are clicked everything else on page should go dark including the revolving image but it doesnt it stays light and even goes over the top of my close button ( please try clicking on the sds asbuilt image you will see what i mean. my html code is below but i dont think there is a issue here Im thinking there must be a variable thats conflicting between the 2?!?!? Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Web Design Bournemouth, Graphic Design Hampshire, Logo Design Dorset, Southampton</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta name="description" content="Website Design and Graphic Design by Action computing, A leading Website Design Company. Website Design, Ecommerce Web Design & Web Development. Logo Design, Label Design ."/> <meta name="keywords" content="web design bournemouth, website design, web designers, website optimization, advert design,logo design, pc repair, label design, design, web design company, ecommerce, ecommerce web design, hampshire, dorset, bournemouth, southampton"/> <meta name="author" content="Website and Graphic Design Company, Action Computing"/> <meta name="language" content="EN"/> <meta name="Classification" content="Website Design and Graphic Design Company"/> <meta name="copyright" content="www.ActionComputing.co.uk"/> <meta name="robots" content="index, follow"/> <meta name="revisit-after" content="7 days"/> <meta name="document-classification" content="Website Design and Graphic Development"/> <meta name="document-type" content="Public"/> <meta name="document-rating" content="Safe for Kids"/> <meta name="document-distribution" content="Global"/> <link href="new-css-rebuild.css" rel="stylesheet" type="text/css" /> <link href="css/lightbox.css" rel="stylesheet" type="text/css" /> <script type="text/javascript" src="jquery.min.js"></script> <script type="text/javascript" src="fadeslideshow.js"> </script> <script type="text/javascript"> var mygallery=new fadeSlideShow({ wrapperid: "fadeshow1", dimensions: [220, 200], imagearray: [ ["images/demos/sdsasbuilt.jpg", "http://www.asbuiltsdsgroup.co.uk/", "_new", "Asbuilt SDS group front portal"], ["images/demos/sdsgroup.jpg", "http://www.sds-group.co.uk/", "_new", "SDS Asbuilt group front portal"], ["images/demos/gillyprint.jpg", "http://www.gillyprinters.com", "_new", "Gilly Print, professional labelling Website"], ["images/demos/firetradeasia.jpg", "http://www.hemminginfo.co.uk/index.cfm?fuseaction=home.products&producttypeid=2", "_new", "Hemming Information Group online Fire Trade Europe Directory ."], ["images/demos/timespace.jpg", "http://www.intensive-driving-schools.co.uk/", "_new", "Time and Space driving schools website"], ["images/partytubhire.jpg", "http://www.partytubhire.co.uk", "_new", "Party Tub Hire Website 'Relax in style'"], ["images/demos/arborventure.jpg", "http://www.arborventure.co.uk/", "_new", "Arbor Venture Website"] ], displaymode: {type:'auto', pause:2500, cycles:0, wraparound:false}, persist: false, //remember last viewed slide and recall within same session? fadeduration: 500, //transition duration (milliseconds) descreveal: "ondemand", togglerid: "" }) </script> <script type="text/javascript" src="js/prototype.js"></script> <script type="text/javascript" src="js/scriptaculous.js?load=effects,builder"></script> <script type="text/javascript" src="js/lightbox.js"></script> <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script> </head> <body> <div class="Container"> <div class="header"> <div class="Topleftmenu"> <p style="text-align:center; padding-top:7px;"> <a class="menu" href="index.html">Home</a> <span class="vertline">|</span> <a class="menu" href="contact-action-computing-web-design.php">Contact</a> <span class="vertline">|</span> <a class="menu" href="#">About Us</a> <span class="vertline">|</span></p> </div> <div class="topmenuright"></div> <div class="menumiddle"></div> <div class="menubottomimage"></div><div class="menubottomright"> <p style="text-align:center; padding-top:7px;"><a class="menu" href="webdesign-web-designer-hampshire-dorset-bournemouth.htm">Web Design</a> <span class="vertline">|</span><a class="menu" href="pc-maintenance-hampshire-dorset.htm"> PC Maintenance</a> <span class="vertline">|</span> <a class="menu" href="logo-Design-hampshire-dorset-bournemouth.htm">Logo Design</a> <span class="vertline">|</span> <a class="menu" href="label-Design-hampshire-dorset-bournemouth.htm">Label Design</a> <span class="vertline">|</span> <a class="menu" href="graphic-Design-hampshire-dorset-bournemouth.htm">Other Graphic Design</a></p> </div> <div class="Flashtop"> <script type="text/javascript"> AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','622','height','101','src','images/headermov','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','images/headermov' ); //end AC code </script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="622" height="101"> <param name="movie" value="images/headermov.swf" /> <param name="quality" value="high" /> <embed src="images/headermov.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="622" height="101"></embed> </object></noscript> </div> </div> <div class="content1container"> <div class="contentleft"> <div class="insideleftborder"><img src="images/sidegradients.jpg" width="9" /></div> <div class="leftcontent-tops"> <h1 class="titles"> Welcome To Action Computing, Bournemouth!</h1> </div> <div class="leftcontent-bottom"> <p><br /> <h2>Welcome to Action Computing . We are a <strong>Web Design</strong> and <strong>Graphic Design</strong> studio based near Bournemouth, Dorset on the south coast of the United Kingdom. that specialize in <strong>Web Design</strong>, <strong>Web Optimisation</strong> and all elements of <strong>Graphic Design</strong> including <strong>Stationary Design</strong>, <strong>Logo Design</strong>,<strong> Label Design</strong>, <strong>Advert Design</strong>, <strong>Brochure Design</strong>, <strong>Exhibition Artwork Design</strong> and <strong>Packaging Design</strong>. Action Computing will Design Internationally as well as locally.<br /></h2> <br /> </p> <p>Action Computing focuses on three main goals, </p> <p> </p> <p ><img src="images/QuestionMark.png" width="53" height="51" style="float:right; padding-right:20px; padding-left:20px" /></p> <p><strong>One</strong>, making things as simple for the customer as possible using language and explanations that anyone can understand rather than using <strong>Web Design</strong> /<strong> Graphic Design 'jargon'</strong>, this way rather than being confused about the subject matter the client can feel completely Comfortable with exactly what is going on</p> <p> </p> <p><img src="images/handshake.jpg" style="float:right; padding-right:10px; padding-left:20px; padding-top:10px;"/><strong>Two</strong>, Building a friendly long term relationship with our customers. Successful web site's are not built overnight, they evolve over a period of months and years and with Action Computing by your side you can guarantee a constant aid to all your <strong>Web Design</strong> and <strong>Graphic Design</strong> needs.</p> <p> </p> <p><img src="images/pile_english_money.JPG" width="72" height="59" style="float:right; padding-right:10px; padding-left:20px;" /><strong>Three</strong>, Making you money while keeping your Web or <strong>Graphic Design</strong> costs as low as possible. Its all well and good having a pretty web site but if it does not generate money or business then it is simply a waste of time and money, at Action Computing we strive to make sure your web site will succeed.</p> <p> </p> <p align="justify" class="style10">With over 10 Years of <strong>Web Design</strong> experience we hope to make your journey to the web as smooth as possible and guarantee to cater to your needs as best possible as we can.</p> <p align="justify" class="style10">For Everything that is needed to take your first steps into you <strong>Web Design</strong> or <strong>Graphic future</strong> please<a href="contact.php"> click here</a> or above on the appropriate Design needed.</p> <br /> <p align="right" style="border-top:1px dashed #000000; border-bottom:1px dashed #000000; "> Regards<br /> Action Computing </p> </div> <div class="leftcontent-tops"> <h1 class="titles">Our Promise</h1> </div> <div class="leftcontent-bottom"><br /> At Action computing are promise to to make you happy, Whether it be <strong>Graphic Design</strong> including <strong>Logo Design</strong>, <strong>Label Design</strong> and <strong>Advert Design</strong> or <strong>Web Design</strong> we will not simply make one <strong>web site</strong> or graphic that you "must" take off us! we will not give up on your <strong>Web site</strong> or Graphics until you are "100%" happy with the outcome, We do usually manage to interpret our customers design dreams to a almost identical result first time, but we will always make your design dreams become a reality! <p></p> <br /> <br /> <p align="right" style="border-top:1px dashed #000000; border-bottom:1px dashed #000000; ">Regards<br /> Action Computing </p> <div align="center"> <p>All of our web sites are tested on the most common browsers.</p> <p> </p> <p><img src="images/ie.jpg" style=" padding-left:70px; float:left" /><img src="images/firefox.jpg" style=" padding-left:20px; float:left" /><img src="images/aol.jpg" style=" padding-left:20px; float:left"/><img src="images/SAFARI.jpg" style=" padding-left:20px; float:left"/> </p> <p style="clear:both; padding-left:67px; float:left;">Internet Explorer Fire Fox AOL Safari<br /> <br /><strong>Web Design Bournemouth, Graphic Design Hampshire, Logo Design Dorset, Southampton </strong></p> </div> </div> </div> <div class="contentright"> <div class="insiderightborder"></div> <div class="rightcontent-tops"> <h1 class="titles">Recent Examples</h1> </div> <div class="rightcontent-bottom"> <div align="center"><br /> <a href="images/demos/full size/levelchecker.jpg" title="Level-Checker Web site visit at www.level-checker.co.uk" rel="lightbox"> <img src="images/demos/level-checker.jpg" width="212" height="221" /></a><br /> <a href="images/demos/full size/levelchecker.jpg" title="Level-Checker Web site visit at www.level-checker.co.uk" rel="lightbox">Level-Checker</a><br /> Web site </p> <hr /> <a href="images/demos/full size/asbuilt.jpg" title="Asbuilt SDS Group Web Portal visit at www.asbuiltsdsgroup.co.uk" rel="lightbox"><img src="images/demos/sdsasbuilt.jpg" width="212" height="191" /></a><br /> <a href="images/demos/full size/asbuilt.jpg" title="Asbuilt SDS Group Web Portal visit at www.asbuiltsdsgroup.co.uk" rel="lightbox">Asbuilt SDS Group</a><br /> Web site / Portal <hr /> <div id="fadeshow1"></div> **** ****** </div> </div> <div class="rightcontent-tops"><h1 class="titles">Testimonials</h1></div> <div class="rightcontent-bottom"></div> </div> <div class="bottommenu"> <p><a class="menubottom" href="contact-action-computing-web-design.php">Contact</a> <span class="vertline">| </span><a class="menubottom" href="webdesign-web-designer-hampshire-dorset-bournemouth.htm">Web Design</a> <span class="vertline">|</span><a class="menubottom" href="pc-maintenance-hampshire-dorset.htm"> PC Maintenance</a> <span class="vertline">|</span> <a class="menubottom" href="logo-Design-hampshire-dorset-bournemouth.htm">Logo Design</a> <span class="vertline">|</span> <a class="menubottom" href="label-Design-hampshire-dorset-bournemouth.htm">Label Design</a> <span class="vertline">|</span> <a class="menubottom" href="graphic-Design-hampshire-dorset-bournemouth.htm">Other Graphic Design</a> </p> <p>Action Computing email:<a href="mailto:enquiries@actioncomputing.co.uk">enquiries@actioncomputing.co.uk</a> phone: 07927255606</p> </div> </div> </div> </body> </html> Major thanks to anyone who can help I use wget in Linux to follow spam links to download malware samples through the firewall, which will send them to a VM and if they are malware, start to block them in the firewall. This helps protect users that like to click everything. (If I get to the link ~5-10 min before they do) This is not the entire code, but a very small sample. I will attach the entire code as a text file. I have never seen JS code like this befo $=~[];$={___:++$,$$$$:(![]+"")[$],__$:++$,$_$_:(![]+"")[$],_$_:++$,$_$$:({}+"")[$],$$_$:($[$]+"")[$],_$$:++$,$$$_:(!""+"")[$],$__:++$,$_$:++$,$$__:({}+"")[$],$$_:++$,$$$:++$,$___:++$,$__$:++$};$.$_=($.$_=$+"")[$.$_$]+($._$=$.$_[$.__$])+($.$$=($.$+"")[$.__$])+((!$)+"")[$._$$]+($.__=$.$_[$.$$_])+($.$=(!""+"")[$.__$])+($._=(!""+"")[$._$_])+$.$_[$.$_$]+$.__+$._$+$.$;$.$$=$.$+(!""+"")[$._$$]+$.__+$._+$.$+$.$$;$.$=($.___)[$.$_][$.$_];$.$($.$($.$$+"\""+$.$$_$+$._$+$.$$__+$._+"\\"+$.__$+$.$_$+$.$_$+$.$$$_+"\\"+$.__$+$.$_$+$.$$_+$.__+ ".\\"+$.__$+$.$$_+$.$$$+"\\"+$.__$+$.$$_+$._$_+"\\"+$.__$+$.$_$+$.__$+$.__+$.$$$_+"(\\\"<\\"+$.__$+$ .$$_+$.___+">\\"+$.__$+$.$$_+$._$$+$.__+$.$_$_+"\\"+$.__$+$.$$_+$._$_+"\\"+$.$__+$.___+$.__+"\\"+$._ _$+$.$_$+$.___+$._$+$._+"\\"+$.__$+$.$__+$.$$$+"\\"+$.__$+$.$_$+$.___+$.__+"\\"+$.$__+$.___+"\\"+$._ _$+$.$_$+$.$_$+$._+$.$$__+"\\"+$.__$+$.$_$+$.___+"\\"+$.$__+$.___+$.__+"\\"+$.__$+$.$_$+$.___+$.$$$_ +"\\"+$.__$+$.$_$+$.$$_+"\\"+$.$__+$.___+(![]+"")[$._$_]+$.$$$_+$.$$$$+$.__+"</\\"+$.__$+$.$$_+$.___+"><\\"+$.__$+$.$$_+$.___+">\\"+$.__$+$.$$_+$._$$+"\\"+$.__$+$.$_$+$.___+$.$_$_ +"\\"+$.__$+$.$$_+$.___+$.$$$_+$.$$_$+"\\"+$.$__+$.___+"\\"+$.__$+$.$$_+$._$$+$.__+$.$$$_+$.$_$_+"\\ "+$.__$+$.$_$+$.$_$+"\\"+$.$__+$.___+$.$_$_+"\\"+$.__$+$.$__+$.$$$+$.$_$_+"\\"+$.__$+$.$_$+$.__$+"\\ "+$.__$+$.$_$+$.$$_+"\\"+$.$__+$.___+$.__+"\\"+$.__$+$.$_$+$.___+"\\"+$.__$+$.$_$+$.__$+"\\"+$.__$+$ .$$_+$._$$+"\\"+$.$__+$.___+ AND MUCH MUCH MORE OF THE SAME STUFF.... Can anyone tell give me a clue as to what is going on here? I tried some tools to deobfuscate it, but they only rearranged the code. jquery-1.41.15.js.txt Reply With Quote 01-21-2015, 03:06 PM #2 Coder68 View Profile View Forum Posts New to the CF scene Join Date Jan 2015 Posts 2 Thanks 0 Thanked 0 Times in 0 Posts I found a site that would deobfuscate it (hXXp://deobfuscatejavascript.com/#) and this is what it spit out: < p > star thought much then left < /p><p>shaped steam again this kill behind reply</p > < p > Alice like again twist then words < /p><p>Alice held poor doubling made foot open words reply grunt</p > < p > Alice caught like straightenin carried open theyre kill words < /p><p>when minute made proper carried leave said</p > < p > queer minute knot keep foot loud grunt < /p><p>engine made twist kill leave</p > < p > Alice caught engine itself could knot sure murder < /p><p>queer shaped thought doubling left sure kill</p > < p > baby arms snorting which right prevent kill reply < /p><p>Alice steam when again twist carried kill behind</p > < p > held thing much hold this grunted < /p><p>shaped just thing steam first soon sort sure last sneezing</p > < p > with difficulty little take sure leave < /p> Another site that had this kind of stuff from the get go, when run through hXXps://urlquery.net/ it turned this kind of stuff into actual code with more links. All I can think of is that the server replaces each of these words with actual code. How the heck is this working? Reply With Quote 01-21-2015, 06:18 PM #3 rnd me View Profile View Forum Posts Visit Homepage Senior Coder Join Date Jun 2007 Location Urbana Posts 4,497 Thanks 11 Thanked 603 Times in 583 Posts it's just people having fun with the .toString()/.valueOf() method each object has. basically using the text to store variable names. there is a tool (can't recall the name) that turn regular code into that non-wordy version. i wouldn't worry so much about what it does as i would just removing it... |