How to add this script to my home page?

Hi

I have been given this custom code by a healthcare review site which adds there widget to my site. However I have tried adding it to raw content but it doesn’t display anything.

Code: <div id="hwwidget1519"></div> <script src="https://healthwatchtorbay.org.uk/widget/js/JDJ5JDExJGU1MzdlZmQ1N2ZkNzVkMzIxNTI4ZXV1VUJxQ1Q3Rzl6VkpEcS5JOU5DdmNyckhzNEoxQVll"></script>

If you could please advise me on this I would be most grateful. Thank-you.

Hi Luke,

I tried adding the code to a Raw Content element on a local setup and it works fine:

Have you tried checking for Javascript errors on your page when you added the code to the element? To verify for JS errors, please check this link:

https://codex.wordpress.org/Using_Your_Browser_to_Diagnose_JavaScript_Errors

If you are still not able to make it work, kindly post the link to the page where you are trying to add the code.

Thank you.

Hi thanks for your help I have tried it again in a separate single row and it appears to work. So it seems it does not display when it is in a row split 1/2 and 1/2. Not sure why that is.

EDIT: I deleted the offending row and recreated it and the problem has gone, it now works. Strange, anyway thanks for your help!

Hi again,

That row might have any markup errors or syntax error that could be preventing your script to execute correctly, recreating the row might have fixed the issue. We’re glad you managed to fix it and thank you for sharing with us.

Cheers!

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.