दान संबंधी दस्तावेज़ीकरण

स्पष्ट, चरण-दर-चरण निर्देशों के साथ दान संबंधी का अधिकतम लाभ उठाना सीखें।

Charitable Divi Integration

This guide is a technical reference for developers working with Charitable’s Divi integration. Divi integration was introduced in Charitable Pro 1.8.12.

अवलोकन

The Charitable Divi integration provides four custom modules for the Divi Builder. The integration uses Divi’s legacy ET_Builder_Module API for maximum compatibility with both Divi 4 and Divi 5.

Architecture

The integration follows a similar pattern to Charitable’s Elementor and WPBakery integrations:

  • Main Integration Class: Singleton pattern, handles detection and module registration
  • Module Classes: Each module extends ET_Builder_Module
  • Shortcode-Based Rendering: Modules leverage existing Charitable shortcodes for output
  • Computed Fields: Used for Visual Builder live previews via AJAX

Divi 4 vs Divi 5 Compatibility

The integration is built on Divi’s legacy module API (ET_Builder_Module) rather than the newer Divi 5 ModuleRegistration system. This approach was chosen for:

  • Backward Compatibility: Works with both Divi 4 and Divi 5
  • Stability: Uses a well-documented, proven API
  • Simplicity: Leverages existing shortcode infrastructure

The integration has been tested with:

  • Divi Theme 4.x
  • Divi Theme 5.x
  • Divi Builder Plugin (standalone)
  • Extra Theme

Disabling the Integration

To completely disable the Divi integration, add this constant to wp-config.php:

define( ‘CHARITABLE_DISABLE_DIVI_INTEGRATION’, true );

This prevents the integration from loading entirely, which can be useful for:

  • Troubleshooting conflicts
  • Sites not using Divi
  • Custom implementations

Module Slugs

ModuleSlugShortcode Used
अभियानcharitable_campaign[campaign id=”X”]
अभियानcharitable_campaigns[campaigns …]
दान फ़ॉर्मcharitable_donation_form[charitable_donation_form …]
दान बटनcharitable_donate_button[charitable_donate_button …]

Hooks and Filters

कार्रवाई

Module Registration

// Modules are registered on this Divi hook

add_action( ‘et_builder_ready’, [ $this, ‘register_modules’ ] );

Cache Clearing

// Campaign options cache is cleared when campaigns change

add_action( ‘save_post_campaign’, [ $this, ‘clear_campaign_options_cache’ ] );

add_action( ‘delete_post’, [ $this, ‘clear_campaign_options_cache’ ] );

add_action( ‘wp_trash_post’, [ $this, ‘clear_campaign_options_cache’ ] );

फ़िल्टर

Module Categories

// Custom category registration

add_filter( ‘et_builder_categories’, [ $this, ‘register_module_category’ ] );

Caching

The integration caches campaign dropdown options to improve performance:

  • Transient Key: charitable_divi_campaign_options
  • Duration: 1 hour (HOUR_IN_SECONDS)
  • Auto-cleared: When campaigns are saved, deleted, or trashed

To manually clear the cache:

delete_transient( ‘charitable_divi_campaign_options’ );

Visual Builder Considerations

Preview Mode

The Donation Form module displays a placeholder in the Visual Builder instead of the actual form. This is intentional because:

  1. Forms require JavaScript that may conflict with the builder
  2. Form submissions in preview mode could cause issues
  3. Performance is improved with static placeholders

The actual form renders correctly on the frontend.

AJAX Data Attributes

The Campaigns shortcode normally outputs data-shortcode-atts for AJAX pagination. In the Visual Builder context, this is stripped to prevent display issues. The integration detects the VB context and adds a preview=”1″ attribute to the shortcode.

Computed Fields

Each module uses Divi’s computed fields system for live previews:

‘__campaign_preview’ => [

    ‘type’                => ‘computed’,

    ‘computed_callback’   => [ ‘Charitable_Divi_Campaign_Module’, ‘get_campaign_preview’ ],

    ‘computed_depends_on’ => [

        ‘campaign_id’,

    ],

],

When a user changes a setting in the Visual Builder, Divi calls the computed callback via AJAX to refresh the preview.

CSS Selectors

Module Container Classes

ModuleContainer Class
अभियान.et_pb_charitable_campaign
अभियान.et_pb_charitable_campaigns
दान फ़ॉर्म.et_pb_charitable_donation_form
दान बटन.et_pb_charitable_donate_button

Common Element Selectors

/* Campaign titles */

.et_pb_charitable_campaign .campaign-title,

.et_pb_charitable_campaigns .campaign-title { }

/* Progress bars */

.campaign-progress,

.progress-bar { }

/* Donate buttons */

.donate-button,

.charitable-button { }

/* Form fields */

.charitable-donation-form input[type=”text”],

.charitable-donation-form select { }

Debugging

Enable WordPress Debug Mode

// wp-config.php

define( ‘WP_DEBUG’, true );

define( ‘WP_DEBUG_LOG’, true );

Common Issues

Modules not appearing in builder:

  • Verify Divi theme/plugin is active: function_exists( ‘et_setup_theme’ )
  • Check that Charitable is fully loaded before Divi initializes
  • Look for PHP errors in wp-content/debug.log

Styling not applying:

  • Clear Divi’s static CSS cache: Divi → Theme Options → Builder → Advanced → Static CSS File Generation
  • Check CSS specificity; Divi uses high specificity selectors
  • The integration uses !important on advanced field CSS for this reason

Campaign dropdown empty:

  • Ensure campaigns exist with “Published” status
  • Check if the transient cache needs clearing
  • Verify post_type_exists( ‘campaign’ ) returns true

Preview not updating:

  • Check browser console for JavaScript errors
  • Verify AJAX requests are completing (Network tab)
  • Ensure computed_depends_on includes the field being changed

Detection Methods

The integration uses multiple methods to detect Divi:

// Check for Divi Builder plugin

class_exists( ‘ET_Builder_Plugin’ )

// Check for Divi functions

function_exists( ‘et_setup_theme’ )

function_exists( ‘et_builder_should_load_all_module_data’ )

// Check for Divi/Extra theme

in_array( get_template(), [ ‘Divi’, ‘Extra’ ] )

Visual Builder Detection

// Frontend Visual Builder

isset( $_GET[‘et_fb’] )

// Backend builder

isset( $_GET[‘et_pb_preview’] )

// AJAX context (for preview rendering)

defined( ‘DOING_AJAX’ ) && DOING_AJAX

Extending the Integration

Adding Custom Fields to a Module

To add fields to an existing module via a child theme or plugin, you would need to extend the module class:

class My_Custom_Campaign_Module extends Charitable_Divi_Campaign_Module {

    public function get_fields() {

        $fields = parent::get_fields();

        // Add custom field

        $fields[‘custom_field’] = [

            ‘label’           => ‘My Custom Field’,

            ‘type’            => ‘text’,

            ‘option_category’ => ‘basic_option’,

            ‘toggle_slug’     => ‘main_content’,

        ];

        return $fields;

    }

}

Note: This requires re-registering the module, which is an advanced customization.

Custom Module Category Icon

The Charitable category icon is set via CSS injection rather than Divi’s icon property (which doesn’t support custom SVGs for categories):

li.charitable.et_pb_folder::before {

    content: ” !important;

    background-image: url(‘path/to/icon.svg’) !important;

    background-size: contain !important;

}

Version History

VersionChanges
1.8.12Initial Divi integration release

सहायता

For issues specific to the Divi integration:

  1. Check this documentation for known solutions
  2. Enable WP_DEBUG and check for errors
  3. Test with a default Divi layout to rule out theme conflicts
  4. Contact Charitable support with debug information

अभी भी प्रश्न हैं? हम मदद के लिए यहाँ हैं!

अंतिम बार संशोधित:

चैरिटेबल में नया क्या है

नवीनतम अपडेट देखें
🔔 हमारे नवीनतम अपडेट प्राप्त करने के लिए सदस्यता लें
📧 ईमेल के लिए सदस्यता लें

ईमेल सदस्यता

हमारे न्यूज़लेटर में शामिल हों

हम आपको स्पैम नहीं भेजेंगे। हम केवल तभी ईमेल भेजते हैं जब हमें लगता है कि यह वास्तव में आपकी मदद करेगा। आप किसी भी समय सदस्यता समाप्त कर सकते हैं!

गिवडब्ल्यूपी माइग्रेशन नया

GiveWP के लिए व्हाइट ग्लोव माइग्रेशन सेवा

अपने फ़ंडरेज़िंग प्लेटफ़ॉर्म को GiveWP से Charitable पर स्विच करने के बारे में सोच रहे हैं, लेकिन अपना डेटा खोने का जोखिम नहीं उठाना चाहते या स्वयं एक जटिल तकनीकी सेटअप को संभालना नहीं चाहते? Charitable की व्हाइट ग्लोव माइग्रेशन सेवा में शामिल हैं:

👥 निर्दोष डोनर मैपिंग: शून्य डेटा हानि के साथ अपने पूरे समर्थक डेटाबेस को सुरक्षित रूप से स्थानांतरित करें।

📊 पूर्ण वित्तीय इतिहास: निरंतर, सटीक रिपोर्टिंग के लिए हर ऐतिहासिक लेनदेन को सावधानीपूर्वक संरक्षित करें।

🔄 निर्बाध आवर्ती दान: अपने आने वाले राजस्व को बाधित किए बिना या अपने दाताओं को अपनी जानकारी अपडेट करने की आवश्यकता के बिना सक्रिय स्थायी सब्सक्रिप्शन को सुरक्षित रूप से स्थानांतरित करें।

💳 शून्य गेटवे व्यवधान: स्ट्राइप, पेपाल, या किसी अन्य GiveWP-संगत प्रोसेसर का उपयोग करना जारी रखें जिसे आप पहले से ही पसंद करते हैं।

🚀 विशेषज्ञ तकनीकी सेटअप: जब हमारी टीम आपके फ़ॉर्म को इंस्टॉल और कॉन्फ़िगर करने का भारी काम संभालती है तो आराम करें—साथ ही, योग्य उपयोगकर्ताओं को Charitable Pro का पूरा साल पूरी तरह से मुफ़्त मिलता है।

अधिक जानने के लिए इस पृष्ठ पर जाएँ

ऑटोमेशन सुधार

📢 नई सुविधा अलर्ट: ऑटोमेशन कनेक्ट 2.0 यहाँ है! 🚀

अपने फ़ंडरेज़िंग डेटा को Mailchimp, Slack, या Google Sheets जैसे टूल से जोड़ने के बारे में सोच रहे हैं, लेकिन डेवलपर को काम पर नहीं रखना चाहते या कस्टम कोड नहीं लिखना चाहते? Charitable के नए ऑटोमेशन ऐडऑन में है:

⚡ 17 इवेंट ट्रिगर: डोनर के पहले उपहार, नवीनीकरण भुगतान, या अभियान मील के पत्थर तक पहुंचने के लिए तुरंत वेबहुक फायर करें।

🎯 स्मार्ट कंडीशनल लॉजिक: केवल तभी डेटा भेजने के लिए 11 फ़ील्ड में शक्तिशाली AND/OR लॉजिक का उपयोग करें जब यह आपकी सटीक शर्तों को पूरा करता हो, जैसे न्यूज़लेटर ऑप्ट-इन।

📊 कस्टम पेलोड नियंत्रण: डोनर, दान और अभियान मेटाडेटा में 80+ क्लीन डेटा फ़ील्ड में से चुनें ताकि आपके ऐप्स को वही मिले जिसकी उन्हें आवश्यकता है।

🚀 प्री-बिल्ट प्लेटफ़ॉर्म टेम्प्लेट: Zapier, Make.com, n8n, HubSpot, और Slack के लिए तैयार टेम्प्लेट के साथ स्क्रैच से सेटअप छोड़ें।

🛡️ विश्वसनीय डेवलपर टूल: हस्ताक्षरित HMAC-SHA256 पेलोड, पूर्ण वर्डप्रेस फ़िल्टर और स्वचालित पुनः प्रयास लॉग के साथ अपने वर्कफ़्लो को पावर दें।

ऑटोमेशन सुधार

🔌 चैरिटेबल ज़ैपियर से जुड़ता है: 7,000+ ऐप्स से कनेक्ट करें और अपने धन उगाहने को स्वचालित करें

दान डेटा को मैन्युअल रूप से अकाउंटिंग शीट में कॉपी करने या नए दाता साइनअप को ट्रैक करने से थक गए हैं? अपने प्रशासनिक कार्यों को ऑटोपायलट पर रखें। चैरिटेबल अब आधिकारिक तौर पर ज़ैपियर पर है, जो आपको अपने धन उगाहने को सीधे अपने पसंदीदा टूल के बाकी हिस्सों में प्लग करने का एक शक्तिशाली, नो-कोड तरीका प्रदान करता है।

हर दान, दाता साइनअप, और अभियान मील का पत्थर अब निर्बाध रूप से एक स्वचालित वर्कफ़्लो को ट्रिगर कर सकता है।

नई क्या है:

♾️ 7,000+ ऐप्स से कनेक्ट करें: अपने चैरिटेबल अभियानों को Google Sheets, QuickBooks, Slack, Mailchimp, HubSpot, Notion, Airtable, और हजारों अन्य जैसे रोजमर्रा के सॉफ़्टवेयर के साथ ब्रिज करें।

⚡ 12 शक्तिशाली ट्रिगर: संपूर्ण दान जीवनचक्र को कवर करने वाले स्मार्ट ऑटोमेशन ट्रिगर का उपयोग करके गहन वर्कफ़्लो बनाएं—जिसमें नया दान, नया दाता, सदस्यता रद्द, और अभियान लक्ष्य तक पहुंचना शामिल है।

📋 पूर्व-निर्मित एक्शन टेम्प्लेट: हमारे पूर्व-निर्मित टेम्प्लेट संयोजनों के साथ तीन मिनट या उससे कम समय में शुरुआत करें, जैसे कि Google शीट में सीधे नए दान लॉग करना या Gmail के माध्यम से कस्टम दाता स्वागत ईमेल भेजना।

🚫 किसी कोड की आवश्यकता नहीं: किसी जटिल वेबहुक या कस्टम PHP स्क्रिप्ट की आवश्यकता नहीं है। बस अपना ट्रिगर चुनें, अपना ऐप चुनें, अपने फ़ील्ड मैप करें, और ज़ैपियर को भारी काम करने दें।

एडमिन समय के घंटों को बचाने के लिए तैयार हैं? आज ही ऑटोमेशन कनेक्ट एडऑन के साथ चैरिटेबल प्रो प्राप्त करें और अपना पहला ज़ैप लॉन्च करें!

सुधार भुगतान

🚀 पेपैल कॉमर्स का परिचय: एक कनेक्शन, दान करने के छह तरीके

दानकर्ता जब किसी कारण का समर्थन करते हैं तो आधुनिक, लचीले भुगतान विकल्पों की उम्मीद करते हैं। यदि वे आपके दान फ़ॉर्म पर अपनी पसंदीदा विधि नहीं देखते हैं, तो वे अक्सर बिना कुछ कहे चले जाते हैं। पेपैल कॉमर्स के साथ, हम आपके अभियानों में एक पूरी तरह से आधुनिक चेकआउट अनुभव ला रहे हैं।

एक एकल एकीकरण का आनंद लें जो आपके फ़ॉर्म को अपग्रेड करता है, दान को निर्बाध बनाता है, और आपको हर एक दान को कैप्चर करने में मदद करता है।

नई क्या है:

🔌 एक-क्लिक कनेक्शन: गंदे एपीआई कुंजी और डेवलपर दस्तावेज़ों को छोड़ें। बस "पेपैल से कनेक्ट करें" पर क्लिक करें, अपने व्यवसाय खाते में साइन इन करें, और आपका आधुनिक फ़ॉर्म पांच मिनट से भी कम समय में लाइव हो जाएगा।

💳 देने के छह तरीके: अपने समर्थकों को पेपैल बैलेंस, वेन्मो (यूएस), पे लेटर फाइनेंसिंग, प्रमुख क्रेडिट/डेबिट कार्ड, एप्पल पे (सफारी), और गूगल पे (क्रोम) सभी एक ही फ़ॉर्म से तुरंत एक्सेस दें।

🔄 लचीला आवर्ती दान: मासिक दान का पूरी तरह से समर्थन करता है। पेपैल सब्सक्रिप्शन एपीआई (पेपैल के अंत में स्वचालित रूप से संभाला जाता है) या वॉल्ट + क्रॉन (सीधे आपकी साइट पर सुरक्षित रूप से संभाला जाता है) के बीच चयन करें।

💬 अनुकूल त्रुटि रिकवरी: कोई और भ्रमित करने वाले ब्राउज़र अलर्ट नहीं। यदि कोई भुगतान अस्वीकृत हो जाता है, तो दानकर्ताओं को सादे-भाषा, इनलाइन संदेश दिखाई देते हैं जो उन्हें समस्या को ठीक करने और अपना उपहार पूरा करने के तरीके के बारे में मार्गदर्शन करते हैं।

पेपैल के लिए तैयार हैं, आधुनिक? चैरिटेबल प्रो 1.8.15+ (या चैरिटेबल लाइट 1.8.11+) में अपडेट करें और आज ही अपना खाता कनेक्ट करें!

अभियान नया

⏳ अभियान काउंटडाउन: तात्कालिकता को बढ़ाएं और दान बढ़ाएं

तात्कालिकता धन उगाहने वाले सबसे शक्तिशाली उपकरणों में से एक है! अभियान काउंटडाउन से मिलें—एक लाइव, वास्तविक समय टाइमर जो टालमटोल को तत्काल उदारता में बदलने के लिए बनाया गया है।

अभियान_काउंटडाउन_एनीमेशन

नई क्या है:

⏱️ लाइव, रियल-टाइम तात्कालिकता: लाइव-अपडेटिंग विज़ुअल काउंटडाउन के साथ अपने अभियान की समय सीमा तक दिनों, घंटों, मिनटों और सेकंडों को खूबसूरती से ट्रैक करें।

🎨 आपके लुक के अनुरूप: बॉक्स्ड बॉर्डर्ड टाइल्स या एक साफ, सिंगल-लाइन इनलाइन डिस्प्ले के बीच चुनें। फ़ॉन्ट और डीप कलर कंट्रोल्स के साथ तुरंत अपने थीम से मिलान करें।

🛠️ कहीं भी रखें: कैंपेन बिल्डर फ़ील्ड, एक समर्पित गुटेनबर्ग ब्लॉक, या एक साधारण शॉर्टकोड का उपयोग करके कहीं भी काउंटडाउन ड्रॉप करें।

🚨 स्मार्ट समाप्ति क्रियाएं: अंतिम स्थिति पर पूर्ण नियंत्रण—टाइमर को स्वचालित रूप से एक कस्टम संदेश से बदलने, इसे शून्य पर फ्रीज करने और बहुत कुछ करने के लिए चुनें।