-
AuthorPosts
-
March 7, 2018 at 12:08 pm #922885
Hi guys,
I know this problem has already been treated in previously but I still need some support.
I’m using the latest enfold version and I followed this: https://kriesi.at/documentation/enfold/adding-a-widget-area-to-the-header/
but when I created the header widget no matter wjat content I used it didn’t appear on the page (I checked the source and there was nothing there).
I placed my script then on the google analytics code container in the enfold options. The script now work but it places the content at the bottom of the page, while I would like it to be just after the menu and before page content.Is the a way using either og the strategies to place the my script where I want it?
(I’m not using a child theme, as I couldn’t complete the activation because after copying the child-theme folder in the themes folder I doesn’t becaome visible in the wordpress themes page….that’s another problem :|)Thank you for your help.
Regards!
FedericoMarch 7, 2018 at 1:27 pm #922969Hey Federico,
You can try using this construct:
function addCustomScript(){ ?> <script> // your code goes here </script> <?php } add_action('ava_after_main_menu', 'addCustomScript');
This code should go into your child theme functions.php.
Best regards,
Victoria- This reply was modified 6 years, 8 months ago by Victoria.
March 7, 2018 at 5:04 pm #923132Thank you Victoria. Can I place it on the enfold functions.php directly? (as I wrote I couldn’t activate the child theme)
March 7, 2018 at 5:14 pm #923145I tried the code on the enfold functions.php but the content didn’t become visible on the site.
March 7, 2018 at 10:55 pm #923415Hi,
Please create a pastebin with the code you added so we can review.
Best regards,
BasilisMarch 20, 2018 at 12:33 am #929440This reply has been marked as private.March 21, 2018 at 5:21 am #930268Hi federicotriana,
This part
https://cl.ly/1C2N3b111C3e has to be on the page where you want to add the widget, not in this script.So put this the div where you need it and the rest in the functions.php and let us know how that worked for you.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.