Automatically Rotating Images with php2Bluesky

I have a PHP application that I use to post to my X, Mastodon and Bluesky accounts. This works well but I noticed the last time I posted an image from my iPhone that while it was fine on X and Mastodon on Bluesky the image was upside down (see above and here)!

Interestingly this only happens when posting via the Bluesky API, if you upload the same from the web interface, for example, it works fine.

Enter EXIF

When you take a picture with a modern digital camera, such as an iPhone, it embeds into that … Read the rest

Posting to WordPress Microposts with php2Micropost

I have accounts on plenty of microblogging sites (Twitter, Mastodon, Bluesky and even Threads) but they are all owned and controlled by someone else. I decided that I wanted something that I could use and manage, and a quick search came up with Michael Gbadebo‘s WordPress plugin called Microposts.

I installed this and after playing around for a while, I decided that it was just what I was looking for. However, it was quite cumbersome to make a post from a mobile device when I was out and about. What I wanted was a simple … Read the rest

How to turn PHP code into a package that will work with Composer

I’ve learned a lot while developing my php2Bluesky package spurred on by my own desire to make a decent product and by suggestions from users. One such itch I needed to scratch was to take my static code and turn it into something that I could use with Composer, the de facto way of handling dependancies in PHP.

I have to admit that not everyone was thrilled about my proposed move to Composer, as many seemed to prefer not to use it and to manage updates and load the code manually. This meant that I also needed to make … Read the rest

Introducing v2 of php2Bluesky

There was an issue raised recently on my php2Bluesky library pointing out that the dimensions of images weren’t being passed and so they weren’t being displayed on Bluesky correctly. On investigation, I found this to be correct, but because of the way the code was currently implemented, I couldn’t fix it. The library needed to have control of the upload of images in order to get the dimensions and currently that wasn’t the case.

Breaking Changes Incoming

The history of php2Bluesky is that it started as a series of functions in a larger side project I was working on. I … Read the rest

A Minor Update to my Bluesky Library

A quick post to say that my Bluesky library has had a small update. This is to take into account that from version two of Clark’s library that handles the calls to Bluesky the connection method has changed. Therefore, if you have updated to version two then remember also to update the PHP2Bluesky code which can be found here.

You can read all the posts on the PHP2Bluesky library here and get in touch if you find any issues or have an enhancement suggestion.… Read the rest

ChatGPT as a Replacement Programmer

When I left university I did so with a good grounding in several programming languages such as Cobol, Fortran and Pascal. Then, at my first job, I was given training in the language Application Master, part of ICL’s VME operating system. One of the things I was told about Application Master was that it was a “fourth generation language (4GL)” and that this would be the last generation that required a developer to write the code.

This was the late eighties and until very recently we have been still waiting for this transition to happen.

ChatGPT has Entered

Read the rest