Grabing a data attribute of a clicked element?
<p>I have a link that opens a modal when clicked, however that element also has a data-id="#id here" attribute that I need to grab so I can pass it to my php script for processing. How can I accomplish this?</p>

<p>My JS code:</p>

<pre><code>$(document).ready(function() {
$('#edit_general').click(editModal);

});

function editModal(event)
{
var modal = $('#editModal');
modal.modal({
    show: true
});
}
</code></pre>

<p>My html:</p>

<pre><code>&lt;li&gt;&lt;a id="edit_general" href="#editModal" data-uid="&lt;?php echo $u-&gt;id; ?&gt;"&gt;Edit General&lt;/a&gt;&lt;/li&gt;
</code></pre>

<p>I tried using the this keyword but it didn't work.
How can I accomplish this?</p>
