How to Make an Image Submit Button in CakePHP

Pass an image file name to FormHelper::submit() and CakePHP renders an image input. For better styling and accessibility, wrap an image in a button instead.

Pass an image file name to FormHelper::submit() and CakePHP renders an image input. For better styling and accessibility, wrap an image in a button instead.

A shared navigation element needs to know which page it is on. You can pass that in as a variable, or let the element read the current controller and action itself.

Use .is(":checked") or .prop("checked") in jQuery, or the checked property in plain JavaScript. Here is how to test one checkbox, read its value and react when it changes.

The way you set a page title in CakePHP has changed three times. This covers pageTitle, title_for_layout, and the view block approach used since CakePHP 3.

IGIT Related Posts With Thumb Images was my second WordPress plugin. Here is how related posts with thumbnails work, and a lightweight code version you can drop into any theme.

In 2010 I released IGIT Follow Me On Twitter Button, my first WordPress plugin. Here is how to add the same kind of follow box today with a few lines of code and no third-party scripts.

Nivo Slider made jQuery slideshows easy in 2010, but it has not kept up. A few lines of CSS now do most of the job, and Swiper or Splide cover the rest.
The old trick of posting your cPanel password to a backup form no longer works. Today you call cPanel's UAPI with an API token, from a cron job or PHP, and send the archive off the server.

When another script also wants the $ variable, jQuery.noConflict() hands it back. Here is how it works, the wrapper pattern that keeps your code short, and why WordPress needs it by default.
PHP's mail() fails on XAMPP and WAMP out of the box. The quickest fix for development is a local mail catcher like Mailpit; for real delivery, use PHPMailer over authenticated SMTP.