• I have hooked into the normal WP theme update process for enabling one-click updates to my theme which is not hosted at wordpress.org, but a recent update (3.7 I believe) has broken my update process, apparently because the URL from which I’m hosting the update does not pass some sort of check. (The URL is indeed valid, and the code which works in WP 3.5 no longer works in the recent two versions.) I have not yet installed a fresh version of 3.6 and 3.6.1 to see if the update works there, but based on the release notes, it looks like the additional security checks to the update process were probably added in 3.7.
    I have searched and searched and cannot find where this new check is happening, so I’m hoping that someone can point me in the right direction.

    When I attempt to update my theme:

    • WP reports that it is downloading my theme from a URL that resolves correctly if I copy/paste into a browser.
    • It displays the message “Download Failed. A valid URL was not provided.”
    • The update process exits without downloading anything or modifying any files.

    Any assistance finding where this error is thrown, what URL check my theme “repository” URL is failing, or any other help tracking this down would be greatly appreciated!

Viewing 3 replies - 1 through 3 (of 3 total)
  • I have hooked into the normal WP theme update process for enabling one-click updates to my theme which is not hosted at wordpress.org

    Can you elaborate on this, please? The update process is for themes hosted on wordpress.org only.

    Thread Starter Robert.Vidrine

    (@robertvidrine)

    My code uses the filter pre_set_site_transient_update_themes to add my theme info. Is there something wrong with doing this?

    There may not be a critical reason why my theme could not be hosted on wordpress.org, but it is only relevant to academic sites located at Wake Forest University. It doesn’t include a lot of features that would be required of a general purpose theme. (It does not include much support for basic blogging features, since it is used almost solely for academic department websites.)

    Moderator bcworkz

    (@bcworkz)

    Nothing wrong in that it’s for your institution’s sites and it worked. As with many hacks that leverage something that was unintended, it eventually breaks.

    Submitting for inclusion on wordpress.org is certainly one option, the requirements are minimal, but certain functionality is required.

    I wonder what commercial themes do. Roll their own update code? For minimal functionality I don’t think that’s too involved. Just be sure it can’t be leveraged to upload something from anywhere but the official source. You O/S may offer another option, Linux has apt-get update among other possibilities.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Theme update no longer works: "A valid URL was not provided"’ is closed to new replies.