Alex Budurovici

Freelance developer London

Marketing vanity urls

Sometimes I just have to write simple redirect rules, that will help the marketing teams track their vanity urls via google analytics campaigns. So, if you ever asked yourself: How to track traffic to websites from printed leaflets and posters How to use Google Analytics to asses printed marketing campaigns How to create vanity urls how…

Continue Reading

Using array_filter and strpos to filter by a keyword inside a multidimensional array

I once needed to query the wordpress database of QueAprendemosHoy, to find all the users that have a theme related permission, and I used the following query: The results in an array format, were the following: In order to only show the theme related permissions, and removing all others, array_filter is what I needed to use: As I’m iterating through…

Continue Reading

direct subdomain at Cloudflare, and duplicated content issue with google

Don’t know how many of you had realized this problem so far, but having at cloudflare, that serves a live non-cached of the site, can create some duplicate content issues at google, and that’s never good. Well, the best and easiest solution that I found, was to redirect `robots.txt` to a `robots.php` (or what ever language…

Continue Reading

git tips and tricks

How do I change the author of the commits? Whilst I was going through the log of my commits for a repository, I had noted some inconsistencies with the author of my commits, and I decided to try and fix that by setting the author and the email values to universal values. To do so, I…

Continue Reading

Lazy loading images

During the rebuild of my Videouri project, I was/am constantly looking for the best approach of writing and serving all the modules involved, including loading front-end assets. My quest, at a certain point, was to find a way of optimizing the load of the images (plenty of them). First thing that came into my head was to server…

Continue Reading