Giter Site home page Giter Site logo

Comments (9)

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Are you using the master branch of the update checker or a release version? There's a GitHub-specific bug that has already been fixed in master but I haven't tagged a new release yet.

Try opening the "update now" link in a new tab (middle-click or right-click and select "Open In a New Tab"). This way you'll get more details about the update installation process. Are there any error messages? On that note, are there any recent entries in your PHP error log?

from plugin-update-checker.

loremuelgadrinab avatar loremuelgadrinab commented on May 23, 2024

I have move my plugin code into my server directory. now I am using the "Self-hosted Plugins".

this is inside my json-api.json file in my server:

{
"name" : "My Plugin",
"version" : "1.3.1.3",
"author" : "My Name",
"download_url" : "http://mysite.com/plugin-directory/myplugin.zip",
"sections" : {
"description" : "some text here"
}
}

in my myplugin-function.php I have this code:

require 'plugin-update-checker/plugin-update-checker.php';
$myUpdateChecker = PucFactory::buildUpdateChecker(
'http://mysite.com/plugin-directory/myplugin.zip/json-api.json',
FILE
);

now when I click the update now button to open in new tab it says:

Downloading update from http://example.com/plugins/my-cool-plugin.zip…
Download failed. Not Found

I have no idea why it goes like this, I have checked all the files and code; even in my local codes works and update successfully. but in my live code didn't work.

I am alsp wondering why it link into "http://example.com/plugins/my-cool-plugin.zip" where I have set the code in json-api.json into "http://mysite.com/plugin-directory/myplugin.zip" ??

please help, I am almost done with it

from plugin-update-checker.

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Maybe you used that URL (http://example.com/plugins/my-cool-plugin.zip) in json-api.json before, and the update checker still has that old version of the file cached? By default, it only checks for changes every 12 hours or so. Go to the "Plugins" page and click the "check for updates" link under your plugin entry. That will force it to refresh the cache.

I would also recommend installing the Debug Bar plugin. You can find a lot of useful debugging information in the "PUC (your-plugin-slug)" section of Debug Bar.

from plugin-update-checker.

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Any news on this?

from plugin-update-checker.

alessandrobellesia avatar alessandrobellesia commented on May 23, 2024

I had a similar problem. In my case the website and the repository had the same domain.
You can try to disable the wordpress http-get external domain security feature adding this line to your plugin:

add_filter( 'http_request_host_is_external', '__return_true' );

from plugin-update-checker.

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Yes, that's a known issue with hosting updates on the same domain. Maybe I should add a similar workaround to the library itself...

from plugin-update-checker.

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Update: Should be fixed in 7a29fda.

from plugin-update-checker.

alessandrobellesia avatar alessandrobellesia commented on May 23, 2024

Great! Thank you!

from plugin-update-checker.

YahnisElsts avatar YahnisElsts commented on May 23, 2024

Well, I guess it's fixed, sort of? @loremuelgadrinab , if it still doesn't work for you, feel free to comment/reopen the issue.

from plugin-update-checker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.