PhpTips.im - Everything about php - Download CMS, find tips and tricks, code snippetz, classes and more and more...
Bookmark this page !
   

Articles

    Home » Articles » PHP Snippets
Browsing PHP Snippets RSS RSS

   Pages :   0     1     2     3     4     5     6     7     8     9     10     11     12     13     14     15     16     17     18     19     20     21     22     23     24     25     26     27     28     29     30     31     32     33     34     35     36     37     38     39     40     41     42     43     44     45     46     47     48     49     50     51     52     53     54     55     56     57     58     59     60     61     62     63     64     65     66     67     68     69     70     71     72     73     74     75     76     77     78     79     80     81     82     83     84     85     86     87     88     89     90     91     92     93  
Get IP Address
Published on : 08.05.2010 Category : PHP Snippets Viewed : 28 times.
[code] function getIP() { $ip=""; if (...
Read More »

Simple class example in PHP5
Published on : 08.05.2010 Category : PHP Snippets Viewed : 30 times.
[code] class myClass{ protected $message;  public function __construct...
Read More »

Php header content type
Published on : 08.05.2010 Category : PHP Snippets Viewed : 33 times.
[code] header("Content-type:application/vnd.ms-word");header("Content-Disposition:attachment;filename=test.doc...
Read More »

Data in Formato Italiano
Published on : 08.05.2010 Category : PHP Snippets Viewed : 24 times.
[code] function data_ita($data){ $pieces = explode(...
Read More »

Display extra posts on pages following home
Published on : 08.05.2010 Category : PHP Snippets Viewed : 26 times.
This is designed to show 10 posts on each of the pages after the home/blog page when the home page only shows 5 (because if you just use postsperpage=10 without the offset you will lose the most recent posts numbered 6-10 in between the first and secon home/blog paged). You can tweak it to different numbers, but you'll need to change the maths (10 * ($page - 1) - 5) to suit. [code] ...
Read More »

Add search bar to Thesis nav
Published on : 08.05.2010 Category : PHP Snippets Viewed : 36 times.
[code] function add_search_nav() {?> <li class="search"><?php thesis_search_form(); ?></li><?php...
Read More »

Convert Shorthand Date to Long Form
Published on : 08.05.2010 Category : PHP Snippets Viewed : 27 times.
Frequently I like to make data more user friendly, so while I make it easy for them to add a date as a shorthand format (mm/dd/yyyy) I like to return it as something easier to digest (Day of Month in Year, etc). This is the simplest way to do that I've found [code] list($day...
Read More »

PHP Autoloader with spl_autoload
Published on : 08.05.2010 Category : PHP Snippets Viewed : 51 times.
Autoload for PHP that enables the definition of namespaces and folders in a list that is used in the spl_registered function for any number of unknown values. This specific function can be used with Joomla! 1.5 since it reload's Joomla!'s autoload class at conclusion.[code]<?phpclass TamkaAut...
Read More »

Upload file
Published on : 08.05.2010 Category : PHP Snippets Viewed : 32 times.
[code] $target_path = "uploads/"; $target_path = $target_path . basename...
Read More »

Print recursive in pre-formatted tags
Published on : 08.05.2010 Category : PHP Snippets Viewed : 29 times.
[code] <?php/** * Wraps content in <pre> tags. Useful for using with arrays of data. *&nb...
Read More »

 

 Members
Log In !
Email Address :

Password :


Change my passowrd !
Sign Up !
We have : 3 members.
Latest member : albans
 
 Last Posts
 
 Advertising
 
©PhpTips.im 2010
Powered by PikaCMS.
Quick Links :
Home | Browse all articles | Downloads | Terms of Use
RSS RSS 2.0 : Articles | Downloads ATOM : Articles | Downloads