Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

uninstall.php Requires PHP v5.3+ #334

Closed
jaswrks opened this issue Sep 24, 2014 · 6 comments
Closed

uninstall.php Requires PHP v5.3+ #334

jaswrks opened this issue Sep 24, 2014 · 6 comments
Assignees
Milestone

Comments

@jaswrks
Copy link

jaswrks commented Sep 24, 2014

I noticed this review at WordPress.org.
https://wordpress.org/support/topic/i-can-not-uninstall#post-

A user writes...

Once activated it and after of the message about the old PHP version, I tried to remove, but after clicking "Remove" the screen goes blank. I've tried other browsers and nothing happens. :(


When I setup the uninstall.php file I forgot about this scenario. The uninstall.php file will get pulled in by WordPress even when/if the plugin is not running due to a lack of PHP v5.3+.

In short, if you install QC to try it out, but cannot use it because your server is lacking PHP v5.3+, deletion of the plugin will cause an error (e.g. blank screen) because the uninstall.php is being loaded, and it requires PHP v5.3+.


Possible Solution

  • Move the existing code to an uninstall.inc.php file.
  • Use uninstall.php as a stub that checks for PHP v5.3+.

Support threads referencing this issue

@jaswrks
Copy link
Author

jaswrks commented Sep 24, 2014

A second look at this issue. The uninstall_on_deletion option in QC defaults to a 0 value (disabled). This means the problem I reported above should not occur, since one cannot change the option value when/if the plugin cannot be run to begin with. However, I still think a stub for the uninstaller is in order. Just to avoid the potential for this to occur.

@jaswrks
Copy link
Author

jaswrks commented Sep 24, 2014

ha! A third look. The uninstall_on_deletion flag, while still at a 0 value, would not prevent the uninstall.php file from being loaded. It only prevents the uninstall routines from running once loaded. So, again, best to include a stub for the uninstaller.

@raamdev raamdev added this to the Future Release milestone Sep 25, 2014
@raamdev
Copy link
Contributor

raamdev commented Sep 25, 2014

Interesting. Thanks for catching this and opening the issue. This seems like a pretty annoying bug. I'm adding it to the Future Release milestone to be worked on in the next development cycle.

@jaswrks
Copy link
Author

jaswrks commented Oct 1, 2014

@raamdev This has been resolved by the PRs I submitted earlier.

@raamdev
Copy link
Contributor

raamdev commented Oct 2, 2014

@jaswsinc PRs have been reviewed and merged. Thank you very much! :)

@raamdev
Copy link
Contributor

raamdev commented Oct 2, 2014

Next release changelog:

  • Bug Fix: Fixed a bug with the uninstaller whereby attempting to uninstall after receiving a notice that PHP 5.3+ is required would result in a blank screen and require manual removal of the plugin. See #334.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants