Welcome To Snipplr
Everyone's Recent PHP Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
Source: http://www.websitedesignby.com/programming/wordpress-website-development-work-flow-wp-config-php/
0
1033
posted 14 years ago by chrisjlee
PHP
Activating the Post Thumbnail feature in Wordpress but not showing anything if there is no image to display
I looked everywhere trying to find some code that could show me how to display the post thumbnail if there is an image, but to display absolutely nothing if there isn't an image to display (most just either added an image or there was a broken image...
1
3392
posted 14 years ago by bdnnikki
A quick snippet of the PHP/Wordpress code behind my archive page, mainly for @andypoppins :D
0
676
posted 14 years ago by psdesignuk
Dear php coders,
Here's a code block that you can use in your projects to get shorter long urls.
Also recommend these articles about [ozon tedavisi](http://www.denizliozon.com) here.
Have a nice coding.
0
1083
posted 14 years ago by jackoder
the LIBXML parameter is what this snippet is about. Also this is one way to retrieve XML without having a XML-declaration prepended <?xml>
1
883
posted 14 years ago by iroybot
Embed Drupal 6 block anywhere with proper block HTML IDs and classes.
0
719
posted 14 years ago by phpdiva
This will let you define individual templates for posts within specific categories. Simply name your post file like: single-SLUG.php
0
579
posted 14 years ago by creativelifeform
catches the first image of a post so you can display it however you like within the loop
0
594
posted 14 years ago by creativelifeform
this is all the actions needed for auth and the users login/register system
0
602
posted 14 years ago by sevennbsp
this is the entire app_controller code with auth setup and use in it.
0
611
posted 14 years ago by sevennbsp
Another common use of Auth component variables is to allow access to certain methods without the user being logged in (by default Auth restricts access to every action except the login and logout methods).
0
726
posted 14 years ago by TioSolid
cleanly display the memory used so you know when your going over, especially useful for memory hog drupal sites.
1
718
posted 14 years ago by electblake