As of PHP 7.2 create_function() has been deprecated because of its usage of eval() – which in itself is a security hole. Even though applications that use create_function() may still work, you should replace it with an anonymous function instead.
PHP
PHP Code To Get ASIN From Amazon US Product URL
Quick PHP code snippet to extract an Amazon product ASIN code or ISBN number from any Amazon US product URL. Works via a regular expression and the “preg_match” function.
Working With AJAX In WordPress
AJAX has become THE way to build user friendly and dynamic websites. With AJAX, you can update the contents of a page without doing a full page reload. Most websites need this behavior. Read this post to learn how to implement AJAX on WordPress sites.
Two Useful Restrictions To Place On Non-Admin WordPress Accounts
Code snippets to restrict authors and contributors of multi-author WordPress websites. The first piece of code prevents them from seeing content assigned to other users. The second ensures that users can only see post counts of their own content.
How To Echo Into A Variable Using PHP Output Buffering
“Echo” is a very handy PHP language construct used to output one or more strings. But echo writes to output directly. So it isn’t very straightforward to save the output of echo into a variable for later use. To do this, you need PHP output buffering.
Code Snippets To Integrate WooCommerce With The Genesis Framework
When integrating WooCommerce with the Genesis theme framework, you will very likely encounter a number of layout and/or styling issues. This article provides short code snippets and instructions to help you resolve the issues in no time.