//============================================================================= function doMouseOut(cmdButton) { cmdButton.style.cursor = ""; if (!cmdButton.disabled) { if (cmdButton.className == "entry-button-small-hover") { cmdButton.className = "entry-button-small"; } else { cmdButton.className = "entry-button"; } window.status = ""; return true; } } //============================================================================= function doMouseOver(cmdButton, strMessage) { cmdButton.style.cursor = "hand"; if (!cmdButton.disabled) { if (cmdButton.className == "entry-button-small") { cmdButton.className = "entry-button-small-hover"; } else { cmdButton.className = "entry-button-hover"; } window.status = strMessage; return true; } } //============================================================================= function doShowHint(intHintID) { // new alert method ala PEH 10.24.06 var browser=navigator.appName if (browser=="Microsoft Internet Explorer"){ var pLineBreak = "\n"; } else { var pLineBreak = " "; } var hint_text=""; switch (intHintID) { case 1: hint_text = "Page Title:\n\nThis is the word or words that will appear in big letters on the top of the web page to introduce"+pLineBreak+"the content for the page.\n\nExample: About Fred's Hardware"; break; case 2: hint_text = "Navigation Title:\n\nThis is the word or words that will appear in navigation bar area of all pages of your website. "+pLineBreak+"Please keep the wording as brief as possible.\n\nExample: About Us"; break; case 3: hint_text = "External URL:\n\nOnly enter a full website address in this box if you want your Navigation Title to link to either an external"+pLineBreak+"web page (outside of your site) or link to a specific E-store page on your site.\n\nExample: http://www.yahoo.com\n\nIf you use this feature to link to an external website, please click the circle below for Yes next to"+pLineBreak+"\"Open in new Window?\" This will open the external website page in a new, separate window. "+pLineBreak+"That way, visitors don't leave your website in order to go to the destination website.\n\nNOTE: If you enter anything in this box, then you would NOT enter any text or images into the"+pLineBreak+"Body editor as it will not appear. "; break; case 4: hint_text = "Search Engine Keywords:\n\nThese are the words that are hidden in the code of your web page that would most likely be typed in"+pLineBreak+"by people looking for your site on the major search engines. Type in as many words as you would"+pLineBreak+"like, minimum 10 words, with the most relevant words at the beginning of the list, and be sure to not"+pLineBreak+"list the same word twice. Also, do not separate the words by any punctuation.\n\nExample: garden gardening gardener azalea roses horticulture"; break; case 5: hint_text = "Search Engine Description:\n\nThis is a single sentence or two, used by major search engines, that specifically describes the main purpose"+pLineBreak+"of your page. It is hidden in the code of your web page.\n\nExample: Fred's Hardware offers the best products, service, and prices for gardeners in Toledo Ohio."; break; case 6: hint_text = "Alternative Text:\n\nThis is a brief description of the picture's image content.\n\nExample: Fred and Sally at the circus."; break; case 7: hint_text = "Upload Image from hard drive vs. from online:\n\nWith PD-go!, you can upload images from your hard disk drive that you have prepared for the web,"+pLineBreak+"or you can link to an image on the internet by typing in its full address.\n\nExample of online image link: http://www.pd-go.com/pdgo/rudyhome2.jpg"; break; case 8: hint_text = "HTML Title:\n\nThis consists of the words that will appear at the very top of your website visitor's browser window. "+pLineBreak+"It tells the visitor the name of the page that they are seeing. However, the primary use of this"+pLineBreak+"feature is that if your site visitor saves this page to their browser's \"Favorites\" list, then the HTML"+pLineBreak+"Title will be the words that appear in their Favorites list bookmarking this page.\n\nThe HTML Title can either be the same, or different, than your \"Page Title\" or your \"Navigation Title.\" "+pLineBreak+"Also, search engine promotion specialists recommend that in order to improve your chances at good"+pLineBreak+"search engine promotion, the HTML Title content should be something descriptive.\n\nExample: \"Bob's Hardware | Providing quality building and construction materials to Podunk Florida\"\n\nNOTE: You don't need to use the quotes like we did here."; break; } alert(hint_text); // old method below //strLink = "http://www.pd-go.com/admin/index.php?action=hint-view&HintID=" + intHintID; //objPreview = window.open(strLink, "preview", "width=400,height=200,status=no,menubar=no,toolbar=no,resizable=no,scrollbars=yes"); } //============================================================================= function formatCurrency(num, blnHideSymbol) { if (!num) num = 0; num = num.toString().replace(/\$|\,/g, ''); if(isNaN(num)) num = "0"; sign = (num == (num = Math.abs(num))); num = Math.floor(num * 100 + 0.50000000001); cents = num % 100; num = Math.floor(num / 100).toString(); if(cents < 10) cents = "0" + cents; for (var i = 0; i < Math.floor((num.length - (1 + i)) / 3); i++) num = num.substring(0, num.length-(4 * i + 3)) + "," + num.substring(num.length-(4 * i + 3)); return (((sign) ? "" : "-") + (blnHideSymbol ? "" : "$") + num + "." + cents); } //============================================================================= function formatCurrencyNullable(num, blnHideSymbol) { if (num.length == 0) return ""; if (!num) num = 0; num = num.toString().replace(/\$|\,/g, ''); if(isNaN(num)) num = "0"; sign = (num == (num = Math.abs(num))); num = Math.floor(num * 100 + 0.50000000001); cents = num % 100; num = Math.floor(num / 100).toString(); if(cents < 10) cents = "0" + cents; for (var i = 0; i < Math.floor((num.length - (1 + i)) / 3); i++) num = num.substring(0, num.length-(4 * i + 3)) + (blnHideSymbol ? "" : ",") + num.substring(num.length-(4 * i + 3)); return (((sign) ? "" : "-") + (blnHideSymbol ? "" : "$") + num + "." + cents); } //============================================================================= function parseQueryString(str) { var args = new Object(); var link = str.split("?"); if (link.length > 1) { str = link[1]; var query = str.charAt(0) == "?" ? str.substring(1) : str; if (query) { var fields = query.split("&"); for (var f = 0; f < fields.length; f++) { var field = fields[f].split("="); args[unescape(field[0].replace(/\+/g, " "))] = unescape(field[1].replace(/\+/g, " ")); } } } return args; } //============================================================================= function trim(x) { var theString = x; if (theString.length > 0) { if (theString.charAt(0) == " ") { return trim(theString.substring(1,theString.length)); } else if (theString.charAt(theString.length - 1) == " ") { return trim(theString.substring(0,(theString.length - 1))); } else { return theString; } } else { return theString; } } //============================================================================= function doValidateSession(p_strFunction) { window.open("http://www.pd-go.com/admin/index.php?action=validate-session&function=" + p_strFunction, "objSessionValidation", "directories=no,height=200,location=no,menubar=no,resizable=no,scrollbars=no,status=no,titlebar=no,toolbar=no,width=300"); } //=============================================================================