JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/dot-luv/jquery-ui.css">
<a href="http://www.google.com" class="link_class">link 1 </a>
<a href="http://www.google.com" class="link_class">link 2 </a>
<a href="http://www.google.com" class="link_class">link 3 </a>
JavaScript
$.fn.jquery_plugin = function(options) {
options = options || {};
return this.filter('a').bind('click', function() {
var content = options.content || $(this).attr('href');
return javascript_plugin ({ 'content': content });
}).end();
};
javascript_plugin = function (options) {
return alert(options.content);
};
$('.link_class').jquery_plugin();