Mastodon and verifying websites

Mastodon is all the rage at the moment as Twitter is driven into the ground in full public view by new overlord, Elon Musk. I’m not going to go into the pros and cons of Mastodon here but looking at one specific thing that is different to Twitter – the automatic validation of websites.

Getting your verification link

In the profile section Mastodon allows you to record up to four pieces of metadata. This can be anything you want, such as location or pronouns, and you can also record your website addess here too. You can put any link … Read the rest

The failed Kickstarter that’s still a partial success

There is much to like about UK plugs – for a start they never fall out of sockets under the weight of the plug as so many US chargers seem to but they are big and bulky. This was something that Mu looked to address with their innovative folding charger.

Back in February 2018 Mu launched a Kickstarter campaign to deliver the “World’s Thinnest 45W International Fast Charger” which was successfully delivered August 2019.

In October 2019 Mu were back on Kickstarter again this time to bring to market the “Next Generation 63W Dual USB Type-C Wall Charger”. What happened … Read the rest

PiHut Advent Calendar

When I was a lad my advent calendar was a bit of carboard with a Christmas scene printed on it with numbered doors that folded back to reveal a Christmas image. There was no chocolate or other delight behind the door and this bit of cardboard religiously came out every Christmas.

How times have changed and now advent calendars are clearly big business. I don’t normally do advent calendars but when I saw this one advertised from the PiHut I thought that I would give it a go.

It arrived this morning and while I knew that it was going … Read the rest

/usr/bin/git-receive-pack: stale NFS file handle Error

What do you do when you want to commit some work, you go to do a git push and what you get back is the following?

fatal: protocol error: unexpected 'Error running git: fork/exec /usr/bin/git-receive-pack: stale NFS file handle'

At first I spent ages doing a search and checking various Stack Overflow questions to see whether I could find a fix. All sorts of things were suggested and I looked into before I remembered that a push in my case was to a remote origin. The third party service BitBucket. When I had a look at their status page the … Read the rest

The controller/method pair you requested was not found.

A very quick Codeigniter tip this week which will hopefully save you hours of tearing your hair out.

As you can see from the image above I have been writing a command line function and was getting the following error:

The controller/method pair you requested was not found.

This was incredibly confusing as the name I was giving on the command line matched that on the controller – or so I thought. What I actually had in the controller was this:

class kanboard extends CI_Controller {

Turns out that Codeigniter3 expects controller names to have leading caps so changing the … Read the rest

Automatically auditing User Actions with CodeIgniter

One important action you might want to carry out is auditing what actions users have taken in your application. Having this knowledge is useful for working out which functions are being used and in what order. Sometimes users reach functionality in a way you might not have imagined when writing your code. Of course this is also very useful for carrying out support too.

MY_Controller

Fortunately it is very easy to record actions without too much coding and even better you don’t need to add the call to audit into everyone of your functions making a retrofit of user auditing … Read the rest

What to do when your Scanner is no longer Supported

If you are a regular reader of this blog then you will know that I am a fairly early adopter for new technologies regardless of whether they are hardware or software. Sometimes that works well, other times not so much.

I’ve had and loved a Fujitsu Scansnap S1500M for many years now and have happily been scanning my paperwork into Evernote with it. However, more recently I had been getting dire warnings from MacOS that at some point in the future the Scansnap software would stop working. With the arrival of MacOS Catalina that day arrived and instantly (albeit with … Read the rest

Applying .gitignore Change to a Repository

A great feature of git is the ability to mark certain file and folders as being excluded from the repository which is done via entries in the .gitignore file.

One issue I regularly have is when things change and I need to update the .gitignore file and I always forget how to apply that change. That’s because it is something that isn’t obvious or something that I do regularly. Fortunately it is incredibly easy to achieve and here’s how…

How to apply .gitignore changes

Assuming that you have already edited and made your changes to .gitignore the next this to … Read the rest

Styling Codeigniter form error messages

As I get more and more deeply involved in using Codeigniter for my projects I discover bits and pieces that I think might be useful to others.

Today is a very quick tip about styling the error messages that are thrown on a form. Looking at the statement that you have in your view it isn’t immediately obvious how you apply any styling to this at all.

The answer, strangely, is to apply the look and feel through a call to set_error_delimiters in your controller and not in the view. The function takes two parameters: the html code that should … Read the rest