Please help me understand why the following jquery select is returning an element rather than the expected object. Thanks. 

&lt;div class="partner-tab partner-tab-opaque remove4" id="tab-5"&gt; &lt;a href="#"&gt;
    &lt;img class="blink" src="../skin/images/logo_endicia.png"&gt;
    &lt;/a&gt;
&lt;/div&gt;


code

$("&lt;a href=\"#\" /&gt;")
    .on("click", {
    "partnerId": pid
}, function (e) {
    return showPartnerSettings(e);
})
.appendTo("#footer #tab-" + pid);

// $("&lt;a href=\"#\" /&gt;")[ &lt; a href = ​"#" &gt; ​ &lt; /a&gt; ]


Error:


  Uncaught TypeError: Object[object Object] has no method 'on'


Here's the whole function:

$(document).ready(function () {

    showPartnerTabs = function (flashUSPS) {
        $.post("&lt;?=$this-&gt;baseUrl('partner/ajaxgetactive')?&gt;", {}, function (data) {
            var partner = data.partners;
            //alert((data.partners).length);
            /* $("#footer .partner-tab").remove();*/
            var remove = 1;
            var doc = $(document);


            for (var id in data.partners) {


                if (partner[id].toggle_value == "on") {
                    remove++;
                    logo = partner[id].logo_file;
                    var pid = parseInt(id) + 1;

                    $("&lt;div class=\"partner-tab partner-tab-opaque remove" + remove + "\" id=\"tab-" + pid + "\" /&gt;")
                        .appendTo("#footer");

                    $("&lt;a href=\"#\" /&gt;")
                        .on("click", {
                            "partnerId": pid
                        }, function (e) {
                            return showPartnerSettings(e);
                        })
                        .appendTo("#footer #tab-" + pid);

                    var logochck = "tab-" + pid;
                    //alert(logochck);
                    if (flashUSPS &amp;&amp; logochck == 'tab-5') {

                        $("&lt;img class='blink' src='../skin/images/" + logo + "' /&gt;")
                            .appendTo("#footer #tab-" + pid + " a");
                    } else {
                        $("&lt;img src='../skin/images/" + logo + "' /&gt;")
                            .appendTo("#footer #tab-" + pid + " a");
                    }

                    //$("&lt;/div&gt;").appendTo("#footer");
                }

                /*
            else
            {

                $("&lt;div class=\"partner-tab partner-tab-opaque remove" + remove + "\" id=\"tab-" + pid + "\" /&gt;")
               .appendTo("#footer");

                $("&lt;a href=\"#\" /&gt;")
                    .on("click", { "partnerId": pid }, function(e){ return showPartnerSettings(e); })
                    .appendTo("#footer #tab-" + pid);       
                $("&lt;img src='../skin/images/" + logo + "' /&gt;")
                    .appendTo("#footer #tab-" + pid + " a");
                //$("&lt;/div&gt;").appendTo("#footer");  
            } 
            */
            }
            //alert($(".remove2").length);
            if ($(".remove2").length &gt; 1) {
                $($(".remove2")[0]).remove();
                $($(".remove3")[0]).remove();
                $($(".remove4")[0]).remove();
            }
        }, "json");
    }

    $(".Partnerconnection ul li .controls .toggle-switch").on("click", null, function () {
        $(this).showPartnerTabs();
    });

    showPartnerTabs(&lt;?=$flash?&gt;);
});


As I mentioned in a comment, this function worked fine until I changed the function declaration from '$.fn.showPartnerTabs()...' to 'showPartnerTabs()...'. Does this help?


Question: What is the likelihood of ever discovering the graviton?
Answer: This depends on graviton energy and wavelength.

Given a source of a beam of high-frequency gravitons with high luminocity, it would not be difficult to detect one. 

The problem is that nature has little sources of high-energy gravitons.