jQuery Error - Not a valid function.

jQuery Error - Not a valid function.

Getting $(this).attr("id").val is not a function error with the code below.

  1. $(document).ready(function() {       

                $('.AdminDisableClick').click(function() {
                   enabledisable($(this).attr("id").val());
                });

                function enabledisable (id) {
                    $.post("/Admin/AdminEnableDisable", { TemplateId: id }                   
                )}
           
            });









I know it has to do with enabledisable($(this).attr("id").val());



I'm trying to pull the value from the DOM.
  1. <a id="49" class="AdminDisableClick" href="#">

Being relatively new at jQuery, I don't know what is wrong and how to fix it. Any help would be appreciated.