Welcome To Snipplr

Everyone's Recent Snippets Tagged javascript

1 2 3 4 5 6 7 ... 47
JavaScript is the only option, if you want to have the ability to clear all form fields. Yes, HTML form has Reset method, but if the form has initial values, then Reset will return the form to the initial state instead of clear input fields. This exa...
0 220 posted 8 years ago by laxman2021
The marquee will stop when you hover the cursor over it. It will restart when you move the cursor away from it.
1 218 posted 8 years ago by o0110o
generischer Handler für die Eventausgabe in der Konsole....
0 188 posted 8 years ago by dejot
jsHint happy class template for javascript
1 221 posted 8 years ago by XtreamIT
How to insert the less preprocessor script in WordPress Websites and Blogs
0 223 posted 8 years ago by ecksteing
This function will compress any text-based content.
1 173 posted 8 years ago by o0110o
Set the desired date within the function. Make some images and label them "1.jpg, 2.jpg, 3.jpg, etc...". That's how it's done.
1 185 posted 8 years ago by o0110o
javascript arrays up and down
2 163 posted 8 years ago by kutyadog
Emulates the StringBuilder() function found in .NET Languages
0 120 posted 8 years ago by jswaringen
this is how to instantiate a dropdown shadow using js code, works in IE10 and windows store apps. Important for when you want use templates.
0 298 posted 8 years ago by Syllogism
Logging In with InstaLib
0 169 posted 8 years ago by kreativemente
Obtener el último video favorito de un usuario de youtube
0 131 posted 8 years ago by alexdw
With jQuery and SPServices, we have very powerful tools for accessing and manipulating Sharepoint data and precisiely contolling the presentation, entirely from the client side. But such solutions generally need to be either hard-coded into pages or...
0 335 posted 8 years ago by rumremix
Simple code example that allows you to pull a time stamp / timestamp to attach to end of URL for GET POST calls
0 255 posted 8 years ago by kutyadog
Code from https://snipt.net/geekyjohn/get-url-param/ updated so that most jslint issues are resolved, and updated the return to use a guard condition instead of a separate if statement.
1 343 posted 8 years ago by pmw57
Use this snippet in Linux shell to install RVM and set it up for use with Sprockets.
0 191 posted 8 years ago by symsec
Standard hasClass, addClass, and removeClass functions, reworked so that jsLint is happier about them, and fixed the removeClass function so that things are trimmed after removing a class name.
2 293 posted 8 years ago by pmw57
Simulate the $_GET array from php in javascript to get url parameters this way: url= http://localhost/?var1=example $_GET['var1'] will return "example" Just copy and paste the code.
2 276 posted 8 years ago by sergiazow
Comprueba la existencia de una cadena de texto en un input con javascript. (LA impresion del input está en CAKEPHP)
0 157 posted 8 years ago by serialk89
Original by dvdrtrgn
0 280 posted 8 years ago by guilhermehn
This send any value via POST to a PHP page. It is done with AJAX, so the POST return can be used on the same page as the submit
0 295 posted 8 years ago by rickygri
This javascript function takes the URL of the target page and an associative array of name/values paires and POSTs the data to the supplied URL by dynamically creating a form and then submitting it.
0 555 posted 8 years ago by rickygri
The following javascript allows your to embed a video as a overlay on any HTML page. The script needs to be added in the head or external file, and the div tag needs to be placed on the page where you want the video image to show up. Another optio...
0 194 posted 8 years ago by ptlrikin
In this section we're going to explore the decorator - a structural design pattern that promotes code reuse and is a flexible alternative to subclassing. This pattern is also useful for modifying existing systems where you may wish to add additional...
0 152 posted 8 years ago by timsommer
The Factory Pattern suggests defining an interface for creating an object where you allow the subclasses to decide which class to instantiate. This pattern handles the problem by defining a completely separate method for the creation of objects and w...
2 155 posted 8 years ago by timsommer
When we put up a facade, we present an outward appearance to the world which may conceal a very different reality. This was the inspiration for the name behind the facade pattern. The facade pattern provides a convenient higher-level interface to a l...
0 126 posted 8 years ago by timsommer
The Command pattern aims to encapsulate method invocation, requests or operations into a single object and gives you the ability to both parameterize and pass method calls around that can be executed at your discretion. In addition, it enables you...
0 157 posted 8 years ago by timsommer
1 2 3 4 5 6 7 ... 47