'; html += '
Please enter a title
'; Obj.innerHTML = html; document.body.appendChild(Obj); return; } if (!error){ // Need to make sure the parent window refresh //jQuery('input#parent_url').val(parent.window.location.href); document.formEdit.submit(); // Redirect this form } } function toggleEditor(id) { if (!tinyMCE.getInstanceById(id)){ jQuery('#mainContent div.mceToolbarTop').remove(); tinyMCE.execCommand('mceAddControl', false, id); jQuery('.mceEditor').height(jQuery('.mceEditor').height() + 29); jQuery('#fulltext').height(jQuery('#fulltext').height() + 29); jQuery('.mceEditorIframe').height(jQuery('.mceEditorIframe').height() + 29); // Begin replace the {readmore} tag // var content = tinyMCE.getContent(); content = tinyMCE.regexpReplace(content, '{readmore}', '
' , 'gi'); tinyMCE.setContent(content); // End replace the {readmore} tag // } else { jQuery('#fulltext').height(jQuery('#fulltext').height() - 29); // Begin replace the read more image // var content = tinyMCE.getContent(); content = tinyMCE.regexpReplace(content, '
]*>]*>
', '{readmore}','gi'); tinyMCE.setContent(content); // End replace the read more image // var bold = 'b'; var underline = 'u'; var italic = 'i'; var strike = 's'; var ul = 'ul'; var ol = 'ol'; var li = 'li'; var bquote = 'b-quote'; var code = 'code'; tinyMCE.execCommand('mceCleanup'); tinyMCE.execCommand('mceRemoveControl', false, id); jQuery('#mainContent').prepend('
' + bold + underline + italic + strike + ul + ol + li + bquote + code + '
'); } } var yPos; jQuery().ready(function(){ // Initialize Google Gears jQuery('#newtag').autocomplete("http://allsib.info/index2.php?option=com_myblog&no_html=1&task=ajaxtaglist", {minChars:2, matchSubset:1, cacheLength:10, selectOnly:1 }); myblog.bindAddedTag(); myblog.bindAssignTag(); jQuery('#apDiv1').hide(); //myblog.initTooltip(); if(typeof(parent.editWindowTitle) == 'function'){ parent.editWindowTitle(''); } // simple Accordion jQuery('#editor-tools').accordion(); var yPos = jQuery(window).height(); // Set the height of the div structure, minus 34, the height of the title bar yPos = yPos-jQuery('#header').height(); jQuery('#container').height(yPos); // Set the height of the text area, minus extra 34 for the word count area yPos = yPos-110; jQuery.each(jQuery.browser, function(i, val) { if(i=="mozilla") yPos = yPos+38; }); jQuery('#sidebar1').height(yPos); //jQuery('#mainContent').height(yPos); yPos = yPos + 66 - 40; jQuery('#fulltext').height(yPos); setTimeout("jQuery('.mceEditorIframe').height(yPos);jQuery('.mceEditor').height(yPos);", 50); setTimeout("tinyMCE.execCommand('mceAddControl', false, 'fulltext');",10); setTimeout('cntWord()', 1000); testTitle(); jQuery("#title").bind("focus", testTitle).bind("blur", editorFocus).bind("click", titleClick); // Show the error message });