Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1092715

    Hello,
    Thank you for past help with Enfold – I have been using/buying Enfold for about 5 years. I build everything in Enfold, the platform has come a long way, even though it was already way ahead of all others. So, thank you!

    Okay, now my question –

    I want to embed a particular .js effect from something I found on GitHub. It is basically a couple of .js files, a custom CSS file, and an example .html. I want the example .html page to show in a section within a page on my enfold site. I can’t seem to make it work… I am not a newbie, as I have HEAVILY customized over two dozen Enfold sites. I have figured out a LOT through the forums, and by trial and error. I am STUCK!

    I have included the GitHub effect and login details for my site in private. Please keep these parts private (private parts, lol) because of competitors.

    Thank you so much in advance!

    • This topic was modified 5 years, 7 months ago by jellyfish007.
    #1093408

    Please help – if anyone is available. I really appreciate it! Also, please let me know if my question was too vague, or mis-stated. Thank you!

    #1093463

    Hi,

    Thank you for using Enfold.

    This thread should help you implement that script.

    // https://kriesi.at/support/topic/trying-to-add-js-particles-background-via-enfold-theme/

    If you want it in a color section, just follow this short guide.

    // https://kriesi.at/support/topic/trying-to-add-js-particles-background-via-enfold-theme/page/2/#post-901857

    Best regards,
    Ismael

    #1093668

    Ismael, thank you for your long-time contributions and support to the Enfold community – I actually already read over this post you refer to; I have (in the past) implemented particle.js in a Enfold site. This current file/script I am working on is different. Would you please take a look a the file I sent in private before and confirm this? I also gave login credentials to my site. I would greatly appreciate your assistance.

    Thank you again for everything you do and continue to do!

    Sincerely

    #1093833

    Would you please offer additional instruction and/or assistance? I would greatly appreciate it, Ismael

    #1094007

    Hi,

    Sorry about that. I misread “particular” as “particle”, so I assumed you’re referring to that old “particle.js” script. We’ll give you an update once we learn more about that script.

    Best regards,
    Ismael

    #1094012

    Hi,

    UPDATE: You need to load the following js files.

    <script src="//cdnjs.cloudflare.com/ajax/libs/zepto/1.1.2/zepto.min.js"></script>
    <script>window.Zepto || document.write('<script src="scripts/vendor/zepto.min.js"><\/script>')</script>
    <script src="scripts/wtf.js"></script>
    <script src="scripts/main.js"></script>
    

    Copy the css code in the child theme’s style.css file or the Quick CSS Field. And then make sure that the following markup exists in the page.

    <article>
    <div id="output">
    		            <noscript>
    <dl>
     	<dt>What the fuck! You don't even have JavaScript enabled!</dt>
     	<dd>You need to enable it to see all the fucking cool shit on this website...</dd>
    </dl>
    </noscript></div>
    <a id="generate" href="#" title="Hit me again!"></a>
    		    </article>
    

    // https://github.com/soulwire/WTFEngine/blob/master/index.html

    You can put that in a code or text block. If I am not mistaken, the script will render something in the “#output” container once you hit the “#generate” link or button.

    Best regards,
    Ismael

    #1094763

    Thank you! Sorry for the delay – was working on another project. I will try these instructions in the next couple of days. i really appreciate your help! I apologize also for being confusing.

    #1095185

    Hi,

    Thanks for the update. FYI, you can use the wp_enqueue_script function to load the js files.

    // https://developer.wordpress.org/reference/functions/wp_enqueue_script/

    And the wp_enqueue_style function for the css, but you can just include the css code in the child theme’s style.css file or the Quick CSS field.

    // https://developer.wordpress.org/reference/functions/wp_enqueue_style/

    Best regards,
    Ismael

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