Welcome To Snipplr
Everyone's Recent Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
PHP
Wordpress - Show link to the next and previos brother of the current page, and a link to the page parent
Must be placed after the_post()
1
4190
posted 15 years ago by Overdeath
Must be placed after the_post() so make sure you verify that if you place it in the sidebar.
0
1976
posted 15 years ago by Overdeath
I found this awesome function that allows you to easily remove duplicate values.
4
2560
posted 15 years ago by chrisaiv
I know this code isn't perfect (and there's a spot where it kind of repeats itself), but I figured I'd share anyway.
NOTE: This code assumes that you are programming in CodeIgniter and you have uploaded a file and posted to a Controller which then...
2
1254
posted 15 years ago by polarbear
PCRE that matches any kind of YouTube URL and catches its video ID. It supports three kinds of URL: the classic (?v=), the AJAXed one (#!v=) and the short version (youtu.be). It also supports international URLs.
Tested with Javascript and PHP.
1
2774
posted 15 years ago by nkm
Removes trailing slashes from URLs, forces all urls to index.php
0
1214
posted 15 years ago by mattkenefick
If this command seems to run forever, it's because there may be parts of the site that generate an infinite series of different URLs. You can solve this in many ways, the simplest being to use the -l option to specify how many links “away†from t...
1
1297
posted 15 years ago by alemani