I am getting a "Missing ) after argument list" on two different sets of commands in the same script - they are part of Dreamweaver MX's files, so i am not sure how they got altered - thanks for the help!
function canAcceptComman d()
{
// Make sure the focus is in the BODY of the document.
var retVal = false;
if (dw.getFocus() == 'document' && dw.getDocumentD OM().getFocus() == 'body') {
retVal = true;
}
if (dw.getFocus(tr ue) == 'html' || dw.getFocus() == 'textView') {
// var fontFamily = arguments[0];
// if (fontFamily != "0Font")
retVal = true;
}
if (dw.getDocument DOM() && dw.getDocumentD OM().getParseMo de() != 'html') {
retVal = false;
}
return retVal;
}
function isCommandChecke d()
{
// if (dw.getFocus(tr ue) == 'html' || dw.getFocus() == 'textView')
// return false;
var bChecked = false;
var fontFamily = arguments[0];
if (dw.getDocument DOM() == null)
return false;
if (fontFamily == "0Font")
{
return dw.getDocumentD OM().getFontMar kup('face') == '';
}
else
{
return dw.getDocumentD OM().getFontMar kup('face') == fontFamily;
}
return bChecked;
}
function canAcceptComman d()
{
// Make sure the focus is in the BODY of the document.
var retVal = false;
if (dw.getFocus() == 'document' && dw.getDocumentD OM().getFocus() == 'body') {
retVal = true;
}
if (dw.getFocus(tr ue) == 'html' || dw.getFocus() == 'textView') {
// var fontFamily = arguments[0];
// if (fontFamily != "0Font")
retVal = true;
}
if (dw.getDocument DOM() && dw.getDocumentD OM().getParseMo de() != 'html') {
retVal = false;
}
return retVal;
}
function isCommandChecke d()
{
// if (dw.getFocus(tr ue) == 'html' || dw.getFocus() == 'textView')
// return false;
var bChecked = false;
var fontFamily = arguments[0];
if (dw.getDocument DOM() == null)
return false;
if (fontFamily == "0Font")
{
return dw.getDocumentD OM().getFontMar kup('face') == '';
}
else
{
return dw.getDocumentD OM().getFontMar kup('face') == fontFamily;
}
return bChecked;
}
Comment