Welcome To Snipplr
Everyone's Recent Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
A simple widget for displaying a single post in a dynamic sidebar. Originally developed to accommodate a WP user who wanted full control of which posts were displayed and what order they were on a certain page.
0
1612
posted 13 years ago by chasecrawford
Gets "src" attributes from all "img" tags in RSS entries descriptions
0
3834
posted 13 years ago by alces
This script informs your visitor that a given page may be reached only from the page that you specify. Paste this code before the ending <head> tag on the page:
1
2724
posted 13 years ago by apphp-snippets
One of the important things about user input is to verify that the user has supplied the email that you have requested. The function below allows you to verify email address with easy.
1
3177
posted 13 years ago by apphp-snippets
The function that closes window is very useful when you use a pop-up window on your page, because it allows the visitor to easily close the window. You can also do it several ways: to use a button, a text link or make the window closes automatically...
1
2921
posted 13 years ago by apphp-snippets
This table is based on the ISO 2 letter (Alpha-2 code, ISO 639-1) and 3 letter (Alpha-3 code, ISO 639-2) Standard Codes for the Representation of Names of Languages.
0
2626
posted 13 years ago by rwt
Shell script written in bash which displays a menu giving the you ability to add, edit, modify, and delete users.
1
4680
posted 13 years ago by dego89
You may perform this work with two ways: pass it directly like described in sample #1 or use an anonymous function like its shown in sample #2.
0
2062
posted 13 years ago by apphp-snippets
This function allows you to pass two variables that represent ID of two elements on your page. What you click on one of them it hide it and shows another one.
1
1551
posted 13 years ago by apphp-snippets
Most today's web browsers like Firefox (Ctrl+D), Opera (Ctrl+T) and IE (Ctrl+D) provide a keyboard shortcuts to enable users bookmark their favorite pages. But if you want to provide your visitors with a "Bookmark this page" link they can click you m...
1
18147
posted 13 years ago by apphp-snippets
The snippet below was pulled from code that loads a list of names pulled from Active Directory into a listbox. This code will execute when the user double clicks on a name in the list box (lstResults) and stores it in a variable to be passed to anoth...
0
1853
posted 13 years ago by mattvbiggs
myEls should be the selector statement for whatever elements you want to effect. The example wraps every 3.
1
2284
posted 13 years ago by adambundy
Uses CSS3 attributes and psuedo elements to create a simple play button for web interfaces.
0
2858
posted 13 years ago by devowhippit
Use below SQL code and replace references within the theme files.
0
1713
posted 13 years ago by ihatetomatoes
You can use JavaScript window.location to redirect a visitor to a required page. You may have seen this feature used by sites with full page ads, or to redirect visitors to the site's new domain name. You can add also a timer to the script that will...
2
3152
posted 13 years ago by apphp-snippets
This example of code shows how to do a simple POST request in PHP to another web server by using a socket connection.
0
3483
posted 13 years ago by apphp-snippets
You need a copy of your model and relations (ObjectStorage properties).
In this example there is a model Product with property ProductAddition (1:n relation).
0
1697
posted 13 years ago by FazzyX
Reads CBC news RSS with fancy-prints its in table, splitting news description by image & text.
0
3899
posted 13 years ago by alces
Use this plugin:
http://wordpress.org/extend/plugins/members/
Settings are here:
http://justintadlock.com/archives/2010/07/10/meta-capabilities-for-custom-post-types
http://codex.wordpress.org/Function_Reference/register_post_type
Gravity Fo...
0
1226
posted 13 years ago by ihatetomatoes
With increasing of popularity of WordPress script, Gravatars have become a really quite popular. Now you may easy integrate them into your own script as they provide a very easy to use API.
0
1340
posted 13 years ago by apphp-snippets
based on the NappScrollViewExtended module (it is good but couse my app some problem)
0
1549
posted 13 years ago by boardmain
Usually when you're using different CSS files on your site, they might take a quite long to be loaded. Using this PHP code, you can compress them into a single file with no unnecessary white spaces or comments. Why we need to compress multiple CSS fi...
0
1615
posted 13 years ago by apphp-snippets