guide - Integrating VenueStack with Your WordPress Site

This guide will walk you through adding a custom script from VenueStack to your WordPress site and setting up a registration button for your events. Follow these steps to enhance your site's functionality and allow your visitors to register for events seamlessly.

Step 1: Adding the VenueStack Script to Your WordPress Site

To ensure that the VenueStack features work correctly on your website, you'll first need to add the provided script to your site's header or footer.

Option 1: Using a Plugin

  1. Install a Header and Footer Plugin:
    • Navigate to your WordPress dashboard.
    • Go to Plugins > Add New.
    • Search for a plugin that allows you to add custom scripts to your header or footer (e.g., "Insert Headers and Footers" by WPBeginner).
    • Install and activate the plugin.
  2. Add the VenueStack Script:
    • After activation, go to Settings > Insert Headers and Footers (or the equivalent option provided by the plugin).
    • Paste the following script in the Scripts in Header section:
      htmlCopy code
      <script src="https://www.venuestack.com/scripts/embed.js" defer></script>
      
    • Click Save.

Option 2: Editing the Theme's 'functions.php' File

  1. Access Your Theme Files:
    • Go to Appearance > Theme Editor.
    • Select your active theme.
    • Locate and click on the functions.php file from the right-hand side list.
  2. Add the Following Code:
    • At the end of the functions.php file, paste the following code:
        function add_venuestack_script() {
            echo <script src="https://www.venuestack.com/scripts/embed.js" defer></script>;
        }
        add_action('wp_head', 'add_venuestack_script');
      
    • Click Update File to save your changes.

Note: Editing the functions.php file directly can break your site if not done correctly. Always back up your site before making changes.

Step 2: Adding the Registration Button

To link a registration button to a specific event, follow these steps wherever you want the button to appear (e.g., in posts, pages, or widgets).

  1. Edit the Page or Post:
    • Navigate to the page or post where you want to add the registration button.
    • Click on Edit.
  2. Add the HTML Code for the Button:
    • In the WordPress editor, switch to the Text or HTML view.
    • Paste the following HTML code where you want the registration button to appear:
      <a href="https://www.venuestack.com/e/{EVENT_ID}/checkout">Register</a>
      
    • Replace {EVENT_ID} with the actual ID of your event.
  3. Publish or Update the Page:
    • Once you've added the button, click Publish (for new pages) or Update (for existing pages).

Conclusion

You've now successfully integrated the VenueStack script into your WordPress site and added a registration button for your events. Ensure to replace {EVENT_ID} with your specific event ID to link the buttons correctly.

For any further customization or troubleshooting, consider consulting with a web developer or reaching out to the VenueStack support team.

Tell us about your event

Request Invite