Quantcast
Viewing all articles
Browse latest Browse all 7

Answer by Carlo for How can I store user feedback related to any part of a web page?

I kinda like the 2nd solution, but i'd attach the function not to some html entities, but to a well defined div something like:

$(document).ready(function() {
    $("div .commentable").each().bind("dblclick", function(e) {
        $("#feedback_form").show();
});
});

So you just need to wrap all the elements you want to be commentable in <div class="commentable"> .. </div>

With the first solution, if you want the feedback in every place of your page, not only specified elements, JQuery can help you

jQuery(document).ready(function(){
   $().click(function(e){
      alert(e.pageX +', '+ e.pageY);
   }); 
})

See the JQuery doc for more info.


Viewing all articles
Browse latest Browse all 7

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>