hi i am a new programer
i want to replace the content of current php page from another php page using ajax without refreshing page.
the content to be replaced is in div’s.
both pages (current and another) has same div’s
HTML Div’s are:
<div class="category-container">
<div class="category-image"></div>
<div class="category-desc"><a href="#">#</a><p>text</p></div>
<div class="rating5" >Editors' rating: </div>
<div class="category-download-btn"><a href="#">Download</a></div>
<div class="category-buy-btn"><a href="#">Buy</a></div>
</div>
can anyone tell me how i can do it. it will be a great help.
also can you provide me ajax code not jquery.
thanks.
Have a look at jQuery’s
load, the section on loading page fragments:To get the div content on another page into an analogous div on the current page, use something like: