Avada Forums Community Forum How to add code into within page editor? | Avada Theme

Tagged: , ,

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • litoid
    Participant
    Post count: 6

    Hey guys, i love Avada and i’ve been using it for years. Yet, I’ve found a block here.

    Here’s the deal:
    There’s a snippet of code i need to insert in <head> and not in <body> and i cannot do that (or i have not found a way to do it) so that it gets read before anything else gets load.

    Using [code block] element adds code into <body>
    and this code is unique per page, so i cannot use > appearance > options > advanced > code fields || because this is universal (for all pages)

    I don’t want to use an extra plugin to do this such as tracking code manager, maybe there’s a workaround within avada theme.

    Any ideas? thank you!

    conspiredminds
    Participant
    Post count: 8

    Avada Options > Advanced > Code Fields (Tracking etc.)

    litoid
    Participant
    Post count: 6

    “and this code is unique per page, so i cannot use > appearance > options > advanced > code fields || because this is universal (for all pages)”

    I’m sorry if you didn’t read that part… go read again, thanks

    • This reply was modified 1 month, 3 weeks ago by litoid.
    conspiredminds
    Participant
    Post count: 8

    You’re right! I didn’t read the entire post, sorry!

    So, do you have a unique code for each page?
    If so, putting it in the body works.

    Placing it in the head just ensures that it works for all pages.
    If you have a unique code for each page, the code block element should work just fine!

    Maybe provide some additional info? What kind of code is it?

    litoid
    Participant
    Post count: 6

    it needs to be loaded before <body> because it’s a script about tracking. sometimes it gets lost if it gets read after the content gets loaded.

    code in <head> guarantees it gets read before anything else gets loaded.

    greetings

    p.s. the code looks like this:

    <script>
    window.clickmagick_cmc = {
    uid: ‘166336’,
    hid: ‘764635962’,
    cmc_project: ‘conscientia’,
    audopt_pro: ‘on’,
    }
    </script>
    <script src=’//cdn.clkmc.com/cmc.js’></script>

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.