Welcome to MainelyDesign.com

Photos of Rockland, Maine. Summer 2009.

A blog mostly about web design

This is the personal blog of Kevin Wentworth.  Topics covered here are web programming, design and internet marketing.

Fixing Warning: the ECDSA host key for 'github.com' differs from the key for the IP address

Posted on 09/10/2023 at 07:01 amViewed 2,791 times

Host Key Differs Warning from Github When you run git fetch and you get this warning: Warning: the ECDSA host key for 'github.com' differs from the key for the IP address '' Offending key for IP in /username/.ssh/known_hosts:7 Matching host key in /username/.ssh/known_hosts:9 This is a pretty simple fix: ssh-keygen -R github.com...

CakePHP 3 - Getting List of Column Definitions from a Table (like schema())

Posted on 12/26/2018 at 02:48 pmViewed 10,601 times

You may come from a time when using $this->ModelName->schema() would give you the details of a table's column defintions.  Not in CakePHP 3.  I found this manual way of achieving the same thing: // insert into begin of the controller file use Cake\Datasource\ConnectionManager; $db = ConnectionManager::get('default'); // Create a schema...

Change Order of Loaded Behaviors in CakePHP 3

Posted on 09/14/2018 at 09:33 amViewed 5,770 times

Turns out it's really easy to change the order of how behaviors are loaded in CakePHP 3.  Wait, I'm actually sort of lying.  You can't change the order of loaded behaviors. (BOO!).  In previous versions of Cake this was a problem... however, with the fully implemented Events subsystem in Cake3, all you need to do is change the priority of the...

CakePHP 3 - Accept JSON Header Only Working When Debug False

Posted on 05/29/2018 at 09:20 amViewed 6,181 times

Strange thing... when you have debug disabled you may find that your application works fine when dealing with json routes without the extension.  Instead of accessing /posts.json, you would access /posts and send an Accept: application/json header and the same thing is achieved. Debug On - Json View Templates Don't Load - Same Accept Header I...

Remove All Events from Google Calendar (Reset Calendar)

Posted on 05/23/2018 at 09:29 pmViewed 20,518 times

I've been doing a lot of programming with the Google Calendar API lately and ran into an issue when I was ready to "go live" with the site.  The Google Calendar was loaded with tons of test data!  I searched around and found plenty of sites giving the same answer.  The problem with the answer- it was incomplete.  If you want to reset a calendar...

Read More Posts.

Meet Site Avenger - Hosted Content Management System

Powered By: Site Avenger | Site Production: Saco Design