Well my problem is this, I have a website of a real estate company.
It has a Sidebar on the right with buttons to enter the different sections,
the "main" part which is the one on the left and occupies 70% of the screen is where a display of all the houses for sale is made, called by the onclick=""
method which in turn executes a function < strong> JQuery + AJAX
which is the following:
function cargarDoc(url) {
$.ajax({
url : url,
dataType: "text",
success : function (data) {
$(".1").html(data);
}
});}
And the html code is the following:
<aside>
<div class="widget">
<p class="s" href="" onclick="cargarDoc('aptoarriendo.php');cargarDoc2('aptoventa.php');"><i class="fa fa-building-o"></i>Apartamentos</p>
<p class="s" href="" onclick="cargarDoc('casaarriendo.php');cargarDoc2('casaventa.php');"><i class="fa fa-home"></i>Casas</p>
<p class="s" href="" onclick="cargarDoc3('calle11con12.html')"><i class="fa fa-home"></i>LOL</p>
</div>
</aside>
So far so good, the list of houses is added successfully in the main section as seen in the following image:
Then, when doing Hover in a house, a button is displayed that says "Information" and the idea is that when you click, the onclick=""
method updates that main section, with another html file that shows detailed information of the house, but, as much as I add the onclick=""
with its respective function, absolutely nothing happens when clicking.
To test, I also put a "LOL" button which for some reason, if you update the section as you should do the button of the image.
My theory is that Sidebar works by being a separate section that will be updated, and in the section itself does not work because it could not update itself. Let's see if someone hits the spot.
Thank you very much in advance and greetings!