Welcome To Snipplr


Everyone's Recent PHP Snippets



1 ... 7 8 9 10 11 ... 152
Introduction: Pin Based login is a mechanism to authenticate user, by sending one time valid pin to user's phone. This implementation makes use of a mOTP API for sending one time pin, via Missed call and thus eliminates any cost involved with the...
0 395 posted 8 years ago by motp
In this article I would like to share how to make a sortable index view with Laravel 4. Let’s assume you have an index view with a table. Like this example for a table that contains posts.
0 403 posted 8 years ago by CreativePunch
Creating a nested array from items with parent IDs. This is useful for when you have a website working with multiple categories with parent categories. But it can be applied anywhere, really!
0 678 posted 8 years ago by CreativePunch
Generates a random string of a given length and character set.
0 360 posted 8 years ago by wyattstorch42
Save this script on your localhost and run it whenever you need to generate a "hamburger icon" of a specific size and color. Just tell it the dimensions and bar color and it will output a mathematically perfect hamburger icon as a transparent PNG, wh...
0 344 posted 8 years ago by wyattstorch42
In this tutorial I will go over implementing Full-Text search in Laravel 4 . Those who have used Laravel 3 in the past may remember that there used to be support for FULLTEXT indexes. This functionality has been removed in Laravel 4 but can still ea...
0 382 posted 8 years ago by CreativePunch
Function to check existence of value in multidimensional array.
0 464 posted 8 years ago by Sadeveloper
List of prime numbers between two number
0 435 posted 8 years ago by Sadeveloper
Count number of files on a ftp server
0 565 posted 8 years ago by Sadeveloper
This PHP function lets you reorder records on a table when you have a field used for save the position. If you have a field with position when you are editing records you probably want, for example, to move a record from position 5 to position 2, but...
0 544 posted 8 years ago by ginoplusio
This PrestaShop support module is used to manage ticket system. By using this plugin you can manage customers queries and complaints easily.This add-on allows to your customers to submit tickets with different format attachment files. Admin can also...
0 364 posted 8 years ago by AlastairBrian
Positioning the normal metaboxes in WordPress admin (like Excerpt, Author etc.) before the WYSIWYG editor
1 260 posted 8 years ago by tkujawa
Write request data to a log file
0 440 posted 8 years ago by dmertl
Examine a date and return false if it's in the past, or true for the future. Slightly more complicated than it needs to be, however there's an easy tutorial with full explanation if you follow the attached link.
0 576 posted 8 years ago by gromitski
I created myself an install file using PHP. What this file does is creates folders and puts in each folder the corresponding file from the zip. Afterwards these files are moved to other folders which are already created or will be created by the inst...
0 281 posted 8 years ago by PLATANIUM
I created myself an install file using PHP. What this file does is creates folders and puts in each folder the corresponding file from the zip. Afterwards these files are moved to other folders which are already created or will be created by the inst...
0 311 posted 8 years ago by PLATANIUM
Sometimes using small code snippets is faster than implement the official api. Using mini bots class is faster to get Instagram data.
0 532 posted 8 years ago by ginoplusio
Sometimes fake users use temporary emails account. Block them within email validation function.
1 471 posted 8 years ago by ginoplusio
While the Pinnacle Cart API can handle some of this, I found it easier to query the database directly. This PCProduct class was developed for integrating Pinnacle Cart with WordPress with the following methods: - get_product($id) - get_product_by...
1 479 posted 8 years ago by crypticsoft
Simple PHP functions to validate url, email address and ip, functions will return TRUE for valid data and FALSE for invalid data.
0 514 posted 8 years ago by codingforever99
En Hosting Gratis, ellos ponen código de rastreo y publicidad anadiendolo en tus paginas webs, aveces estos códigos interfieren en consultas tipos webservice cuando el formato debe ser xml o json
0 388 posted 8 years ago by thescorpion
Gets all of a Wordpress post meta data in an array without specifying a key
1 331 posted 8 years ago by web_la
A function to create passwords for new users or password resets.
0 318 posted 8 years ago by luckygreentiger
An attempt for a semi-random salt in a stored password. It's not stored in the database so I believe it would be harder to discover. Samples should be changed.
0 311 posted 8 years ago by luckygreentiger
Compact Privacy Policy allowing cookies to be used in an iframe without being blocked by the host website. See link for further details.
0 349 posted 8 years ago by gromitski
Simple PHP Backdoor Shell // http://www.example.com/shell.php?cmd=dir
0 1207 posted 8 years ago by shopsplash
Truncates the given string at the specified length.
1 424 posted 8 years ago by JoshChris
0 344 posted 8 years ago by santamartastudio
Bare outline for a PHPUnit test case
0 248 posted 8 years ago by steroidmonkey
1 ... 7 8 9 10 11 ... 152