Loading a page into a div on click

Loading a page into a div on click

Im trying to make jquery load a php page into a new div so that the user may edit the language settings, then hide the div again.

The code below looks right to me but it doesnt seem to work. Rather than loading with ajax it follows the fail safe link.

Firefox2.0 tells me "missing ) after argument list
[Break on this error] $('a#edit_EN').click(funtion{$('#editlang').load('admin-editlang.php', {id: edit..."

IE7 is kind enough to say char 31, which is the closing bracket after function... So its saying its missing it, in the exact position that it can be found.... strange.

Anyone got any ideas??

<script src="../lib/jquery.js" type="text/javascript"></script>
<script src="../lib/jquery.form.js" type="text/javascript"></script>


<a target="blank" href="editlang.php?id=EN">

<script type="text/javascript">
$(document).ready(function() {

$('a#edit_EN').click(funtion(){$('#editlang').load('admin-editlang.php', ({id: edit_EN}));});
// return false to prevent normal browser submit and page navigation
return false;
});
</script>
    • Topic Participants

    • mark