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

Clean Install of Compat plugin #5

Closed
wants to merge 10 commits into from

Conversation

bahiirwa
Copy link
Collaborator

This is a rough Idea I had for closing #3. We could build on this.

The only restrictions I see are if a user has file write permissions locked. In which case, that user can not auto install plugins unless they provide FTP logins to CP.

Closes #3.

@bahiirwa bahiirwa added the help wanted Extra attention is needed label Dec 26, 2019
Copy link
Contributor

@timbocode timbocode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As per Slack discussion, use WP_Filesystem instead of PHP functions.

@bahiirwa
Copy link
Collaborator Author

As per slack, we should have a new approach implemented.

@bahiirwa bahiirwa closed this Dec 26, 2019
@bahiirwa bahiirwa reopened this Dec 27, 2019
@bahiirwa
Copy link
Collaborator Author

bahiirwa commented Dec 27, 2019

I have been testing this on local server and online. The plugin unmistakably identifies that woo is installed or files exist on server but which ever way I rewrite the conditional for installing, cc-compat-woo still installs but properly throws the notice.

Screenshot (37)

Screenshot (38)

Of course if it was named woocommerce\woocommerce.php there is no way it would install. File error would pop up on installation trial. same folder names and files can not exist on any OS.

@timbocode
Copy link
Contributor

Just one quick observation.

Function display_wc_message() is still trying to deactivate 'cc-compat-woo/cc-compat-woo.php'

@bahiirwa
Copy link
Collaborator Author

Good catch. However, it doesn’t run. I was trying to merge the gist shared and current files.

@timbocode
Copy link
Contributor

OK. I also noticed that you reference 'includes' in one place and 'inc' in another:

include_once dirname( __FILE__ ) . '/includes/UpdateClient.class.php';
$link = WP_PLUGIN_DIR . "/cc-compat-woo/inc/functions.php";

Same reason?

@bahiirwa
Copy link
Collaborator Author

I missed the folder from merging #6

@bahiirwa bahiirwa closed this Dec 27, 2019
@bahiirwa
Copy link
Collaborator Author

This logic is no longer needed as the code is in the cc repo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants