1

We have a totally custom theme that we have built in house, recently the WordPress updater has started saying the theme is out of date.

Update suggestion

When I investigated this supposed update it links me to a similarly named theme in the WordPress theme directory but one that is not developed by us.

Theme

We normally update our themes manually either through the filesystem or FTP. We have never submitted our theme to the WordPress directory nor do we have a mechanism or infrastructure to allow our themes to "phone home" to check for updates.

What is going on here? How do I stop it misreporting the theme update? I really want to stop this behaviour to prevent an over eager customer trying to update the theme to this one and breaking their site.

  • WordPress use the directory name of the theme to check if there is a opensource theme to update. Then you just have to rename the directory professional into something else to stop this link. – mmm Nov 8 '17 at 15:28
1

When it comes to developing your own stuff, it is always the best to make the code yours too, not just the copyright and such.

As @Rarst already pointed out, the first thing to check if the theme's folder. I faced the same issue before and changing the theme's folder fixed the issue for me.

But for future goods, you should start prefixing your code. It means that you should prefix your theme's name, functions, classes, etc ... by your or your company's name. It's less likely if someone ever will publish a theme named burgi-professional, but a general name such as professional may exist anytime.

This also applies to class names and functions to. Prefix your functions like this:

function burgi_get_theme_options( ){ ... }

So there is a lower chance of running into such issues. Same goes for CSS classes, and HTML ID attributes.

  • Rarst said to ignore folder advice altogether and do it properly instead. For the record. :D – Rarst Nov 9 '17 at 16:35
  • But that folder name saved me once :D @Rarst – Jack Johansson Nov 9 '17 at 20:07
1

WordPress infrastructure and default core code assumptions are really really unfriendly to private bespoke plugins and themes in this regard.

While "rename folder" is a common advice, it doesn't guarantee anything. First, the exact matching algorithm is private. Second, well, what if it matches with a different theme at a later time again?

The only reliable approach is to explicitly exclude your extensions from WP update checks with code. Which WP core by the way makes incredibly inconvenient to do.

Personally I got sick of this problem and eventually wrote small Update Blocker plugin to stop reinventing that wheel.

0

I was having that problem with a theme I was using and all I had to do was change the version to a reverse date such as 2017-11-08, and it never bothered me again. I did the same thing with any plugins I did not want WordPress to try to update.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.