Embedding Chatbot in Wordpress
# 🤝help
p
I want to embedd a Chatbot on my own Website in Wordpress, but I don't have the Business Plan to use Plugins. Is there any Possibility to add the Bot on my Website without using some Plugins? I've already tried to add it on some Sections, but it will only appear within a div and I want it to appear on the bottom right corner of the screen on the website. Somehow I cannot find any solution on the internet for this... Thanks.
r
I use WordPress all the time but never on WordPress.com so I don't really know the limitations. But I do know that most of the themes I use have a way to include scripts in header or footer.
p
So, how do you use it in wordpress.org? Could you send me a example Theme you know has a way to include scripts?
r
Hmmm well I guess all the themes I use are paid themes. Kadence, Divi, Genesis, Beaver Builder all have it. I also have one site where I just made my own plugin for this. But I'm assuming you can't create your own plugin. Can you edit functions.php?
p
I tried to edit functions.php but I cannot find it. I am software developer but never actually worked with WordPress, so I know around nothing😅 but I could try creating own plugins.. but assuming you would sell a Botpress Bot to someone with a WordPress website. Is the person then forced to get the Plug-in?
r
If the theme doesn't have an interface for adding scripts to header or footer, you would have to either edit theme files (bad,) set up a child theme (ok but not great), add code to functions.php, or install a plugin that enables this functionality. This is the total code needed either in functions.php or in a separate plugin: function enqueue_custom_scripts() { // Enqueue the first script wp_enqueue_script( 'botpress-inject', 'https://cdn.botpress.cloud/webchat/v0/inject.js', array(), '1.0', true ); // Enqueue the second script with the "defer" attribute wp_enqueue_script( 'botpress-config', 'https://mediafiles.botpress.cloud/9223b195-3517-489e-b0cc-0bb9c7f72749/webchat/config.js', array(), '1.0', true ); } add_action( 'wp_enqueue_scripts', 'enqueue_custom_scripts' );
3 Views