Luis Gerardo Runge
Luis Gerardo Runge

Reputation: 107

Jquery .load in wordpress

I'm trying to load a webpage into a div using this:

<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>

    <script type="text/javascript">
    $(document).ready(function() 
    { 
    $("#easyCSAT") 
    .load("https://easycsat.com/clients/?rmp=c55a4817b37ceb7af899bb761450b3dd") });

And then, I show the content in the div:

<div id="easyCSAT"></div>

That work in all webpage that I tested (even in different domains) but no in Wordpress, can anyone support me?

Am I doing something wrong? Do I need to change my code?

Thanks in advance

Upvotes: 0

Views: 34

Answers (1)

gaetanoM
gaetanoM

Reputation: 42054

In Wordpress you can use the form:

jQuery(document).ready(function( $ ) {
   $("#easyCSAT")
      .load("https://easycsat.com/clients/?rmp=c55a4817b37ceb7af899bb761450b3dd")

});

You can take a look to this article

Upvotes: 1

Related Questions