Site logo

Archived topic

Can custom hooks be used for a shortcode with a php function?

1 reply · Started by Eric on January 2, 2020

Viewing posts 1–2 of 2

Hi,

I currently have a custom shortcode I did myself that queries a custom table in MySQL to retrieve custom data. I have obviously modified the theme to achieve that.

I am trying to see how to implement this small functionality with GeneratePress. Do I have to create a child theme?

See the link included. The Investment Data is a shortcode with embedded shortcode that queries the database for each fields. I use the Shortcoder plugin from within Wordpress and that works well and it allows for embedded shortcodes but I had to write the php code in the theme files due to the database queries I made. I was hoping the custom hooks could come in handy as a way to do a custom shortcode with php.

Loving the theme so far and would love an easy way to do this.

Thanks

PS if not possible, can this be a feature? It seems that it would easily fit inside your current model with the premium plugin :)

This archived topic is closed to new replies.