impress-org / givewp

GiveWP - The #1 Donation Plugin for WordPress. Easily accept donations and fundraise using your WordPress website.
https://givewp.com/
GNU General Public License v3.0
340 stars 191 forks source link

fix: ensure compatibility with the Philanthropy theme #3708

Closed marutim closed 5 years ago

marutim commented 5 years ago

Current Behavior

Currently, the Give admin section totally breaks when the philanthropy theme is activated. Philanthropy is from one of the popular theme makers themefuse.

There are no console errors suggesting any conflicts.

Expected Behavior

Give plugin should work nicely with the theme

Steps to Reproduce

  1. Activate the theme to an existing website using Give
  2. Go to any donations and you would see the Give admin section broken.

Theme file is available via internal Google Drive

Visuals

1

Related

HS Link: https://secure.helpscout.net/conversation/669048309/26085/ https://secure.helpscout.net/conversation/665257962/25736?folderId=1457790

Acceptance Criteria

Environment

The theme was even breaking the "Get system info" tool, so I have to switch to twenty seventeen theme to copy the details

### WordPress Environment ### Home URL: http://wp-give-copy.local Site URL: http://wp-give-copy.local WP Version: 4.9.8 WP Multisite: – WP Memory Limit: 256 MB WP Debug Mode: ✔ WP Cron: ✔ Language: en_US Permalink Structure: /%postname%/ Show on Front: posts Table Prefix Length: wp_ Table Prefix Length: 3 Table Prefix Status: Acceptable Admin AJAX: Accessible Registered Post Statuses: publish, future, draft, pending, private, trash, auto-draft, inherit, request-pending, request-confirmed, request-failed, request-completed, refunded, failed, revoked, cancelled, abandoned, processing, preapproval, give_subscription ### Server Environment ### Hosting Provider: DBH: localhost, SRV: wp-give-copy.local TLS Connection: TLS Connection: Server Info: Flywheel/4.1.0 PHP Version: 5.6.20 PHP Post Max Size: 1,000 MB PHP Time Limit: 300 PHP Max Input Vars: 4000 PHP Max Upload Size: 300 MB cURL Version: ❌ 7.38.0, OpenSSL/1.0.2k - We recommend a minimum cURL version of 7.40. SUHOSIN Installed: – MySQL Version: 5.6.36 Default Timezone is UTC: ✔ fsockopen/cURL: ✔ SoapClient: ✔ DOMDocument: ✔ gzip: ✔ GD Graphics Library: ✔ Multibyte String: ✔ Remote Post: ✔ Remote Get: ✔ ### Give Configuration ### Give Version: 2.2.5 Give Cache: Enabled Database Updates: All DB Updates Completed. Give Cache: Enabled Give Cache: ✔New Donation✔Donation Receipt❌New Offline Donation❌Offline Donation Instructions✔New User Registration✔User Registration Information✔Email access❌Renewal Receipt Email❌Subscription Cancelled Email❌Subscription Completed Email❌Subscription Reminder Email✔Subscriptions Email Access Upgraded From: 1.8.19 Test Mode: Enabled Currency Code: USD Currency Position: Before Decimal Separator: . Thousands Separator: , Success Page: http://wp-give-copy.local/donation-confirmation/ Failure Page: http://wp-give-copy.local/donation-failed/ Donation History Page: http://wp-give-copy.local/donation-history/ Give Forms Slug: /donations/ Enabled Payment Gateways: Test Donation, PayPal Standard, Stripe - Credit Card Default Payment Gateway: Test Donation PayPal IPN Verification: Enabled PayPal IPN Notifications: N/A Donor Email Access: Enabled ### Active Give Add-ons ### Give - Authorize.net Gateway: ✔ Licensed – by WordImpress – 1.4.3 Give - Currency Switcher: ✔ Licensed – by WordImpress – 1.2.2 Give - Form Field Manager: ✔ Licensed – by WordImpress – 1.3 Give - MailChimp: ✔ Licensed – by WordImpress – 1.4.1 Give - Manual Donations: ✔ Licensed – by WordImpress – 1.4.1 Give - Mollie Gateway: ❌ Unlicensed – by WordImpress – 1.1.2 Give - PDF Receipts: ✔ Licensed – by WordImpress – 2.3 Give - Per Form Gateways: ✔ Licensed – by WordImpress – 1.0.1 Give - Recurring Donations: ✔ Licensed – by WordImpress – 1.8.0 Give - Tributes: ✔ Licensed – by WordImpress – 1.5.0 ### Other Active Plugins ### Brizy: by Brizy.io – 1.0.34 Debug Bar: by wordpressdotorg – 0.9 Email Cop: by Ashfame – 0.1.1 Give - Fee Recovery: by GiveWP – 1.7.2 Give - PayPal Pro Gateway: by GiveWP – 1.2.0 Give - Stripe Gateway: by GiveWP – 2.1.0 User Switching: by John Blackbourn & contributors – 1.4.0 ### Inactive Plugins ### Automatic Responsive Tables: by Andrew Rockwell – 1.2 Debug Bar Post Meta: by whyisjake – 0.5.5 Give - AmeriCloud Payments: by AmeriCloud Solutions, Inc. – 1.2.0 Give - Braintree Gateway: by WordImpress – 1.1.1 Give - CCAvenue Gateway: by WordImpress – 1.0 Give - Constant Contact: by WordImpress – 1.2.1 Give - ConvertKit: by WordImpress – 1.0.1 Give - CSV Toolbox: by WordImpress – 1.0 Give - Email Reports: by WordImpress – 1.1.1 Give - Form Countdown: by WordImpress – 1.0.1 Give - Gift Aid: by WordImpress – 1.1.3 Give - GoCardless Gateway: by WordImpress – 1.2 Give - Google Analytics Donation Tracking: by WordImpress – 1.1.1 Give - Hook Helper: by Ravinder Kumar – 1.0 Give - Paytm Gateway: by WordImpress – 1.0 Give - Per Form User Role Assigner: by Matt Cromwell – 1.0 Give - Recurring Helper: by WordImpress – 1.0 Give - Zapier: by WordImpress – 1.2.1 My Custom Functions: by Space X-Chimp – 4.28 WP Filters Extras: by BeAPI – 1.0.2 ### Active MU Plugins ### Local by Flywheel Relative URL (for Live Links): by Flywheel – 1.0 ### Theme ### Name: Twenty Seventeen Version: 1.7 Author URL: https://wordpress.org/ Child Theme: No – If you're modifying Give on a parent theme you didn't build personally, then we recommend using a child theme. See: How to Create a Child Theme
nishitlangaliya commented 5 years ago

Slack Call Summary

Participants: @nishitlangaliya , @ravinderk Topic: Discussion regarding https://github.com/impress-org/give/issues/3708 Result: I found that Philanthropy theme is removing our wp-content/plugins/give/assets/dist/css/admin.css in their theme 'philanthropy-parent\theme-includes\hooks.php' line no 6879 by making our filter give_load_admin_styles false. So currently moving this issue to blocked and will discuss about this on tomorrow call.

nishitlangaliya commented 5 years ago

@DevinWalker , I found that in philanthropy-parent\theme-includes\hooks.php' line no 6396 they have written '_the_core_filter_fix_give_plugin_assets' function for https://github.com/WordImpress/Give/issues/466 this issue to avoid conflict with theme.

kevinwhoffman commented 5 years ago

@nishitlangaliya has confirmed that removing or commenting out the following lines should restore the Give styles:

philanthropy-parent\theme-includes\hooks.php at line 6874:

if ( ! function_exists( 'the_core_give_load_admin_styles' ) ) :
    function the_core_give_load_admin_styles() {
        return false;
    }
endif;
add_filter( 'give_load_admin_styles', 'the_core_give_load_admin_styles' );
kevinwhoffman commented 5 years ago

@mathetos @marutim Please follow up with the customer to let them know that the Philanthropy theme is removing Give styles as the result of a CSS conflict from two years ago. This old issue explains why they felt the need to remove Give styles.

Today I reached out to the ThemeFuse developers in a new issue to ask them to allow Give styles to be enqueued. In the meantime, removing or commenting out the action above should restore Give styles.

marutim commented 5 years ago

@kevinwhoffman @nishitlangaliya Thanks Guys.

I will follow up with the user and share the details with them.