Tag Archives: php

Fix “Post Types Order” plugin error with HTTPS

The WordPress Plugin Post Types Order by NSP CODE is helpful in as it allows you to Order Posts and Post Types Objects using a Drag and Drop Sortable javascript capability But unfortunately the plugin does not work with wordpress … Continue reading

Posted in Tech Tips, Web Development | Tagged , , , , , | Leave a comment

PHP Auto Generate Status Header: function

PHP Function to Auto Generate Status Header This is from the CodeIgnitor Common Functions Library. It is very useful: // ———————————————————————— /** * Set HTTP Status Header * * @access public * @param int the status code * @param string … Continue reading

Posted in Web Development | Tagged , , , , | Leave a comment

Fake Sendmail for Mac (linux)

When developing in PHP perhaps you need to set up a sendmail that just outputs things to text. No need to setup delivery via SMTP. Just create an executable ruby script somewhere, for example: /usr/bin/fake-sendmail.sh with following content: $ touch … Continue reading

Posted in Tech Tips, Web Development | Tagged , , , , | 1 Comment

Heredocs and Nowdocs in PHP

A here document (also called a here-document, a heredoc, a here-string or a here-script) is a way of specifying a string literal in command line shells including all the Unix shells (sh, csh, ksh, Bash and zsh) and the Windows … Continue reading

Posted in Tech Tips, Web Development | Tagged | Leave a comment

The PHP Object Expands in PHP5

Starting with PHP 5, the object model was rewritten to allow for better performance and more features. This was a major change from PHP 4. PHP 5 has a full object model. Among the features in PHP 5 are the … Continue reading

Posted in Tech Tips, Web Development | Tagged , | Leave a comment

Good Practices in PHP

Here are a few tips for those of you who’d like to write good code in PHP: Set up a Development Server Set up a development server or sandbox. Don’t write, test, or develop code on a production server. If … Continue reading

Posted in Tech Opinion, Tech Tips, Web Development | Tagged , | Leave a comment

Complete list of built-in PHP functions

Phar PharData PharException PharFileInfo abs acos acosh addcslashes addslashes aggregate aggregate_info aggregate_methods aggregate_methods_by_list aggregate_methods_by_regexp aggregate_properties aggregate_properties_by_list aggregate_properties_by_regexp aggregation_info apache_child_terminate apache_get_modules apache_get_version apache_getenv apache_lookup_uri apache_note apache_request_headers apache_reset_timeout apache_response_headers apache_setenv apc_add apc_cache_info apc_clear_cache apc_compile_file apc_define_constants apc_delete apc_fetch apc_load_constants apc_sma_info apc_store apd_breakpoint apd_callstack … Continue reading

Posted in Web Development | Tagged | Leave a comment

Using json_encode() and json_decode() in PHP4

I use json_encode() a lot for AJAX calls. Teamed with jQuery’s $.getJSON(), it’s too convenient not to use. Unfortunately, json_encode() doesn’t come standard until PHP 5.2. To add insult to injury, many current *nix distros don’t include PHP 5.2 in … Continue reading

Posted in Web Development | Tagged , , | 6 Comments