Hi I seem to be getting an error in dreamweaver on the last line of this script, it has appeared since I added some Jquery initialisation code to the head, but I cant seem to see where the error actually is as according to dreamweaver the closing script tag is the error.
<script src="./ui/media/js/jquery-1.6.2.min.js" type="text/javascript"></script>
<script src="./ui/media/js/jquery.dataTables.min.js" type="text/javascript"></script>
<script src="./ui/media/js/ZeroClipboard.js" type="text/javascript"></script>
<script src="./ui/media/js/TableTools.js" type="text/javascript"></script>
<!-- TinyMCE -->
<script type="text/javascript" src="./jscripts/tiny_mce/tiny_mce.js"></script>
<script type="text/javascript">
tinyMCE.init({
mode : "textareas",
theme : "simple",
editor_selector : "mceSimple"
});
tinyMCE.init({
mode : "textareas",
theme : "advanced",
editor_selector : "mceAdvanced",
theme_advanced_buttons1 : "bold,italic,underline,separator,strikethrough,justifyleft,justifycenter,justifyright,justifyfull,bullist,numlist,undo,redo,link,unlink,Name,Rep,Date",
theme_advanced_buttons2 : "",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
plugins : 'inlinepopups',
setup : function(ed) {
// Add a custom button
ed.addButton('Name', {
title : '[Name]',
class : 'namebutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{name}');
}
});
ed.addButton('Rep', {
title : '[Rep]',
class : 'repbutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{createdby}');
}
});
ed.addButton('Date', {
title : '[Date]',
class : 'datebutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{datesent}');
}
});
</script>
<!-- /TinyMCE -->
<script src="./ui/media/js/jquery-ui-1.8.16.custom.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready( function() {
$('#dashboard').dataTable({
"bJQueryUI": true,
"bInfo": true,
"bAutoWidth": true,
"bFilter": true,
"bLengthChange": true,
"bPaginate": true,
"bProcessing": true,
"bSort": true,
"sPaginationType": "full_numbers",
"aaSorting": [[ 6, "desc" ]],
"iDisplayLength": 5,
"bLengthChange": false
});
});
</script>
You are missing two closing braces in your tiny mce code to close the tinyMCE.init
and the setup: function(ed) {
:
<script type="text/javascript">
tinyMCE.init({
mode : "textareas",
theme : "simple",
editor_selector : "mceSimple"
});
tinyMCE.init({
mode : "textareas",
theme : "advanced",
editor_selector : "mceAdvanced",
theme_advanced_buttons1 : "bold,italic,underline,separator,strikethrough,justifyleft,justifycenter,justifyright, justifyfull,bullist,numlist,undo,redo,link,unlink,Name,Rep,Date",
theme_advanced_buttons2 : "",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
plugins : 'inlinepopups',
setup : function(ed) {
// Add a custom button
ed.addButton('Name', {
title : '[Name]',
class : 'namebutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{name}');
}
});
ed.addButton('Rep', {
title : '[Rep]',
class : 'repbutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{createdby}');
}
});
ed.addButton('Date', {
title : '[Date]',
class : 'datebutton',
image : 'img/example.gif',
onclick : function() {
// Add you own code to execute something on click
ed.focus();
ed.selection.setContent('{datesent}');
}
});
}
});
</script>
<!-- /TinyMCE -->