WordPress.org

Ready to get started?Download WordPress

Forums

Can you hook a shortcode into an area using functions.php? (2 posts)

  1. mattmikulla
    Member
    Posted 6 months ago #

    Is it possible to hook into a template area and add a shortcode within the functions.php file.

    I'm trying to avoid adding the shortcode within the template file.

    For example, I'm trying to add a social sharing widget in my single product WooCommerce page.

    This would normally be easy with default plugin functionality but I need to use WooCommerce Conditional Content and it duplicates the social sharing block when a new content block is added to a product page.

  2. mattmikulla
    Member
    Posted 6 months ago #

    I should note that I'm not trying to create my own shortcode. The social sharing plugins all have there own.

    Everything I'm finding out there is information on creating a new shortcode within functions.php.

Reply

You must log in to post.

About this Topic

Tags

No tags yet.