javascript - call a method with jQuery AJAX -


html>

I try this code and call a method from my controller in the codeigniter, Click

  $ ("# blog") (function () {var url = $ (this) .attr ("href"); $ .XX ({url: "index.php / home / category ", Type:" POST ", success: function (html) {$ (" #cert-content "). Attachment (html);}});});  

Ajax could not be removed, something that I'm missing, # blog represents the ID of a link in my navigation menu, whatever link it is Works normally in

Any help please: - (

You need to stop it General link behavior from.

  $ ("# blog"). Click (function (e) {var url = $ (this) .attr ("href"); // block general Click Action e.preventDefault (); // Post $. Post Create ("index.php / home / category", // <- Request URI {url: url}, // & lt; - Any data here Attachments (html);}});});  

In addition to this, the function (html) {//

  • ; callback $ ("# right-content" Thank you for

  • See Avejh

    Comments

    Popular posts from this blog

    c# - How to capture HTTP packet with SharpPcap -

    php - Multiple Select with Explode: only returns the word "Array" -

    php - jQuery AJAX Post not working -