background preloader

Javascript

Facebook Twitter

Brainfuck beware: JavaScript is after you! | Patricio Palladino. Tl;dr I just made a tool to transform any javascript code into an equivalent sequence of ()[]{}! + characters. You can try it here, or grab it from github or npm. Keep on reading if you want to know how it works. Non alphanumeric JavaScript What do you know about non-alphanumeric XSS? The other day one of my friends asked me that question on IRC, pointing me to some articles on sla.ckers.org where they tried to create some scripts like alert(1) with non-alphanumeric characters.

As a security researcher and a penetration tester, he insisted that extending that concept to any javascript source would be really useful for bypassing IDSs, IPSs and WAFs. Alphabet Many alphabets could do the job, but just for fun, I tried to keep it as small as possible, using only the following characters: [ and ] to access array elements, objects properties, get numbers and cast elements to strings. ( and ) to call functions and avoid parsing errors. + to append strings, sum and cast elements to numbers. ! Numbers. Mario5. Download the demo project including the source - 0.99 MB Introduction In the history of computer games some games have created and carried whole companies on their shoulders. One of those games is certainly Mario Bros. The Mario character first appeared in the game Donkey Kong and became very famous within its own game series starting with the original Mario Bros. in 1983.

Nowadays a lot of spin-offs and 3D jump and runs are being produced centering the Mario character. The code of the game itself will be written in object oriented JavaScript. Background The original version of this application was developed by two students who took my lecture on "Programming Web applications with HTML5, CSS3 and JavaScript".

For this article I decided to focus on the main things of the game. The last statement sounds like a maniac writing this article. Hide Copy Code Now this does not look so nasty, but this is in fact everything that is needed to play a game of Mario with HTML5. The basic design <! History. Nick Kwiatek — Web & interaction designer + developer. Turn.js - The page flip effect for HTML5. Drag and drop table rows with JavaScript | Redips | spideR Net. REDIPS.drag was initially built to drag and drop table content. After publishing first version of REDIPS.drag, I received a lot of questions about dragging table rows also. Now is possible to drag and drop table rows as well as table content. First column and contained DIV element in this demo is a row handler, so you can try to drag table rows.

It is very easy to define a row handler. Actually, it is only needed to place DIV element to the column (first, last or any other) and to define class="drag row". This DIV element will become a row handler. Event.rowChangedevent.rowClickedevent.rowClonedevent.rowDeletedevent.rowDroppedevent.rowDroppedBeforeevent.rowDroppedSourceevent.rowMovedevent.rowNotClonedevent.rowNotMovedevent.rowUndeleted Each event handler has access to the obj and objOld objects. REDIPS.drag has a new method: rowOpacity(el, opacity, color) to change color and opacity of the source row and mini table. Happy dragging and dropping! JavaScript Drag and Drop example 3 | Redips | spideR Net. School timetable is example of how to use REDIPS.drag library. Page layout contains two tables: left table with school subjects and timetable on the right. After subject is placed to the timetable, button in the same color will be displayed next to the subject (clone object).

Drag school subjects to the timetable (clone subjects with SHIFT key) Please note two checkboxes in the upper left corner of timetable. The following code shows event.dropped() event handler (with logic for cloning DIV elements across a week). Source code (including school timetable with save/recall table using PHP and MySQL) and detailed description of library can be found on Drag and drop table content with JavaScript. Javascript in Ten Minutes (Javascript)