How to enable WordPress Debug Mode in 60 seconds

If you are a WordPress developer or if you just installed a misbehaving plugin you will need to enable WordPress’s debug mode in order to figure out what made your site get into the dreaded blank white page (unlike Windows WordPress has a White-Screen-Of-Death). So here’s the quick step-by-step guide to get you going:

Step by Step

  1. Connect via FTP to your site (use FileZilla which is free, if you don’t have an FTP client already installed) or just open your text editor if you are running local.  (15 seconds)
  2. Browse to WordPress home directory, and open wp-config.php for editing. (10 seconds)
  3. Hit Ctrl-Endor scroll to the bottom of the document, locate the line that says define(‘WP_DEBUG’, false);  – you can find it a few lines before the end of the file. (15 seconds)
  4. Change false to true and Save. (15 seconds)
  5. Refresh the page and you should be able to see the errors.  (5 seconds)

 

Total: 60 seconds.

 

Its recommended you don’t run this option on a live production site but if you really must, make sure you turn if back off when you are done. Alternatively you can enable the debug log to be sent to a file instead of the browser by also adding the following line in your config file:

define(‘WP_DEBUG_LOG’, true);

This will cause the error messages to be saved in a file called debug.log in the wp-content sub-folder of your installation. Again make sure this file is protected because by default anyone from the web can access it in the particular folder.

 

And if my instructions are not detailed enough you can look at the long version on the WordPress codex.

WooCommerce PDF Product Catalog Plugin v1.0.8

Has only been one and a half months since I published the PDF Catalog for WooCommerce plugin on CodeCanyon and since then I released 5 versions. Most feature additions came after requests from users who purchased the plugin.

The latest release 1.0.8 which went online this week and includes:

  • Support for high-res JPEG image embedding (the site’s admin can choose the resolution of images used based on a predefined list). Also added a slider to choose the JPEG compression quality coefficient.
  • User role restrictions – a highly requested feature which allows the admin to choose which WordPress User Roles have access to download the store catalog.
  • Enabled PDF Subsetting in TCPDF. The admin can still pick to disable it. Essentially this only embeds the required ligatures from the font in the PDF file. For UTF8 encoded catalogs cuts down the file size by about 300k depending on language and amount of text.
  • Ability to Hide ‘HIDDEN’ products. As weird as this might sound some users wanted to be able to see products in PDF for which they set their visibility to Hidden in the Product editor.

The plugin can still be downloaded from here.

PDF Product Catalog for WooCommerce – my new plugin

The idea for this plugin came to me after a request from a client for whom I developed a WordPress / WooCommerce based online store. The client wanted to have downloadable price lists in PDF format for each product category. His original plan was to generate the PDFs manually offline and upload them to the site but obviously there was a better way. So after doing some research and tests on some PHP classes for generating PDF files I made a polished WordPress plugin and published to CodeCanyon.

At the time of writing it has the following features:

  • Widget for PDF Download Buttons
  • 5 PDF Catalog Templates included.
  • Create your own PDF templates in HTML.
  • Generate per Category PDF and/or Complete Store catalog.
  • 4 pages of admin options to fine tune your catalog content and design.
  • Tested with stores with more than 1000 products.
  • Pure PHP Solution (no need to install any plugins / does not use external services).
  • Hide / Show catalog elements (e.g. SKU, descriptions, prices).
  • Upload your own logo.
  • Support for UTF8 catalogs (non-latin characters in PDF)
  • Customize catalog text.
  • Include product images in catalog.
  • Support for product variations.
  • Customize colors from Admin Panel.
  • Hyperlinks in PDF for each product
  • Caching for increased performance (catalogs are only generated once)
  • Automatic page numbering.
  • Header / Footer on each page.
  • Send PDF to browser or force download option.
  • Customise which categories appear in catalogs.
  • Full Documentation included.
  • Tested with WordPress 3.8, 3.8, 3.9 and WooCommerce 2.1.x

Thanks to comments I received on CodeCanyon I got ideas for other features, especially integration with other WooCommerce plugins which hopefully I’ll manage to implement soon.

The plugin can be purchased here for 15USD.