Welcome To Snipplr
Everyone's Recent Snippets Tagged php
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
Shows the sub pages of a parent page, and also the parent page as a link.
1
884
posted 14 years ago by davebowker
Create an excerpt from the main copy, removing any image or other HTML tag markup so it will be clean. In this case the length is 160 characters, change that number to change the length of the excerpt
0
634
posted 14 years ago by cessnajumpin
I wrote this really quick and dirty script to paginate a very large chunk of text. A client site was setup with the understanding their about page would consist of 5-6 paragraphs but their biography ended up being 60 paragraphs. At the end of the d...
0
737
posted 14 years ago by aristoworks
This is a simple function that will return an array of all the dates corresponding to the day 'Monday' for a given year. It's pretty simple and may not be the cleanest way but it works for my purpose.
0
964
posted 14 years ago by aristoworks
This is a tutorial I've found for integrate Facebook Connect function with your web community.
1
990
posted 14 years ago by ginoplusio
Detect if the user is browsing from and iPhone (or iPod) to server up specific content. For example, iPhone users can receive youtube video content instead of vimeo, etc.
1
832
posted 14 years ago by ericschweichler
Class has simple interface to download any file from a server without displaying the location of the file.
2
1139
posted 14 years ago by Almorca
This is a class/demonstration for creating dynamic properties and storing them in an array
1
665
posted 14 years ago by mpcircuitry
Place in your functions.php file and call it in your theme like this:
<?php>
1
1139
posted 14 years ago by afj176
Modified version of the script created by Dave Stevens, Enables the user to input their credentials on a webpage rather than having to change the actual php script code.
Changes: Changed $user,$pass,$term
This is a modified script, the original...
0
960
posted 14 years ago by jonathonmaguire
I’ve made this class that can use normal session variables, or cookies. This class can use cookies in two ways: store a single variable in each cookie, or pack many variables, encrypt, and store them into cookies.
Now I always use this class whe...
2
1006
posted 14 years ago by ginoplusio
Before:
`
Array
(
[0] => Array
(
[total_sessions] => 24
[study_type_id] => 1
)
[1] => Array
(
[total_sessions] => 24
[study_type_id] => 2
)...
0
673
posted 14 years ago by iloveitaly
This is the first version of my PHP DB connection class using ODBC
0
1158
posted 14 years ago by mpcircuitry
an easy-to-use function to connect to your del.icio.us account and perform a query.
query commands can be found on their api help: http://delicious.com/help/api
1
697
posted 14 years ago by stephanepericat
This is the code to make a simple gallery really fast, with php, jquery and a dir full of pictures.
2
1543
posted 14 years ago by ginoplusio
I whipped this up after finding that my worst fears were true, pathinfo is slow. Top that with in_array and you've got your self some heavy code. Nothing like regex to speed things up.
This little code checks the extension of a path to see if it i...
0
678
posted 14 years ago by Oldarney