1// JC 02/08/2004 contains all JavaScript functions from Resources.asp 2 3function openPage(url) { 4 var width = 500; 5 var height = 415; 6 var popup = new PopupNewPageWithNav( url, "newwindow", 100, 100, width, height); 7 popup.open(); 8} 9 10function PopupNewPageWithNav(url, name, x, y, width, height) { 11 this.url = url; 12 this.name = name; 13 this.x = x; 14 this.y = y; 15 this.width = width; 16 this.height = height; 17 18 this.status = true; 19 this.toolbar = true; 20 this.location = true; 21 this.scrollbars = true; 22 this.resizable = true; 23 this.dependent = false; 24 25 this.open = PopupWindow_open; 26} 27 28function body_onLoad() { 29 30 // Add validation to hidden field that ensures no emails are entered in Email Documents to me fields 31 try 32 { 33 document.page.checkdomainfieldcheck.validate = _checkdomain_fieldsempty; 34 } catch (err) { } 35 36 // Set the validation rules for the checkdotcom form 37 try 38 { 39 document.checkdotcom.name.validate = validateDataEntered; 40 document.checkdotcom.name.mandatory = true; 41 document.checkdotcom.name.text = ".com Check availability now:"; 42 } catch (err) { } 43 44 // Set the validation rules for the checkdotcomau form 45 try 46 { 47 document.checkdotcomau.name.validate = validateDataEntered; 48 document.checkdotcomau.name.mandatory = true; 49 document.checkdotcomau.name.text = ".com.au Check availability now:"; 50 } catch (err) { } 51 52} 53 54function _checkdomain_fieldsempty() 55{ 56 var dotcomvalue = document.checkdotcom.name.value; //.replace(/^\s*(.*)\s*$/, '$1'); 57 var dotcomauvalue = document.checkdotcomau.name.value; //.replace(/^\s*(.*)\s*$/, '$1'); 58 59 if ( (!dotcomvalue || dotcomvalue == "") && (!dotcomauvalue || dotcomauvalue == "") ) 60 return true; 61 62 alert( 'You have clicked the \'Continue\' button whilst there are entries (even if only \'invisible\' spaces) in either or both of the \'Check availability now:\' domain name fields above. If you want to use either or both of the domain name \'Check availability now:\' functions, you must do so by clicking on its (or their) associated \'GO\' button(s) above. Alternatively, if you do not want to use (or again use) either or both of the domain name \'Check availability now;\' functions, but instead simply want to continue to the next page, you must first remove (delete) all entries (even \'invisible\' spaces) from the \'Check availability now\' domain name fields above, and then click on the \'Continue\' button.' ); 63 64 if( !(!dotcomvalue || dotcomvalue == "") ) 65 { 66 document.checkdotcom.name.focus(); 67 document.checkdotcom.name.select(); 68 } 69 else 70 { 71 if( !(!dotcomauvalue || dotcomauvalue == "") ) 72 { 73 document.checkdotcomau.name.focus(); 74 document.checkdotcomau.name.select(); 75 } 76 } 77 78 return false; 79} 80 81function _checkdotcom_continue( theForm ) 82{ 83 // Works for both availability checking forms as they both use a name field 84 85 var successful = true; 86 var elements = theForm.elements; 87 for (var i = 0; successful && i < elements.length; i++) { 88 if (elements[i].validate) { 89 successful = elements[i].validate(); 90 } 91 } 92 93 if( successful ) 94 { 95 // Open the window for the results. 96 openDotComCheck(); 97 return true; 98 } 99 else 100 { 101 return false; 102 } 103} 104 105function _checkdotcomau_continue( theForm ) 106{ 107 // Works for both availability checking forms as they both use a name field 108 109 var successful = true; 110 var elements = theForm.elements; 111 for (var i = 0; successful && i < elements.length; i++) { 112 if (elements[i].validate) { 113 successful = elements[i].validate(); 114 } 115 } 116 if( successful ) 117 { 118 // Open the window for the results. 119 openDotComAuCheck(); 120 return true; 121 } 122 else 123 { 124 return false; 125 } 126} 127 128function PopupNewPage(url, name, x, y, width, height) { 129 this.url = url; 130 this.name = name; 131 this.x = x; 132 this.y = y; 133 this.outerWidth = width; 134 this.outerHeight = height; 135 this.width = width; 136 this.height = height; 137 138 this.status = true; 139 this.toolbar = false; 140 this.location = false; 141 this.scrollbars = true; 142 this.resizable = true; 143 this.dependent = false; 144 145 this.open = PopupWindow_open; 146} 147 148function PopupNewPageWithNav(url, name, x, y, width, height) { 149 this.url = url; 150 this.name = name; 151 this.x = x; 152 this.y = y; 153 this.width = width; 154 this.height = height; 155 156 this.status = true; 157 this.toolbar = true; 158 this.location = true; 159 this.scrollbars = true; 160 this.resizable = true; 161 this.dependent = false; 162 163 this.open = PopupWindow_open; 164} 165 166function openPage(url) { 167 var width = 500; 168 var height = 415; 169 var popup = new PopupNewPageWithNav( url, "newwindow", 100, 100, width, height); 170 popup.open(); 171} 172
173function PopupPDF(pdf) { 174 175 var pdfwidth = 450; 176 var pdfheight = 400; 177 var xpos = 160; 178 var ypos = 90; 179 NewWindow = window.open("" ,"popUp","left="+xpos+",top="+ypos+",screenX="+xpos+",screenY="+ypos+",width="+pdfwidth+",height="+pdfheight+"outerWidth="+pdfwidth+",outerHeight="+pdfheight+",toolbar=no,location=no,directories=no,status=yes,titlebar=no,menubar=no,scrollbars=yes,resizable=yes"); 180 181 182NewWindow.document.write("<html><title>Incorporator - Australian Company Incorporations</title>"); 183NewWindow.document.write("<body leftmargin='0' topmargin='0' marginwidth='0'marginheight='0'>"); 184 NewWindow.document.write("<embed src='"+ pdf +"' width='100%' height='100%' href='"+ pdf +"'>"); 185NewWindow.document.write("</embed></body></html>"); 186 187 if (!((navigator.appName == "Microsoft Internet Explorer") && (navigator.appVersion.substring(0, 3) < "3"))) 188 { 189 NewWindow.focus(); 190 } 191} 192 193function openDotComCheck() { 194 var width = 420; 195 var height = 490; 196 197 if( !( dotcomwindow == null ) && ( typeof dotcomwindow.window == "object" ) ) 198 { 199 dotcomwindow.window.close(); 200 dotcomwindow = null; 201 } 202 dotcomwindow = new PopupNewPageWithNav("/14/loading.htm", "dotcomwindow", 375, 5, width, height); 203 dotcomwindow.open(); 204} 205 206function openDotComAuCheck() { 207 var width = 420; 208 var height = 420; 209 210 if( !( dotcomauwindow == null ) && ( typeof dotcomauwindow.window == "object" ) ) 211 { 212 dotcomauwindow.window.close(); 213 dotcomauwindow = null; 214 } 215 dotcomauwindow = new PopupNewPageWithNav("/14/loading.htm", "dotcomauwindow", 375, 145, width, height); 216 dotcomauwindow.open(); 217} 218 219// JC 10/09/2004 Ref 1317 Different way of popping up to avoid random usernam/password prompts. 220// Replaces PopupRules() function. 221function PopupRulesPDF() { 222 var popup = new PopupWindow("/COMMON/pdfs/ReplaceableRules.pdf", "popWindow", 110, 100, 560, 430); 223 224 popup.toolbar = true; 225 popup.location = false; 226 popup.directories = false; 227 popup.status = true; 228 popup.titlebar = false; 229 popup.menubar = false; 230 popup.scrollbars = true; 231 popup.resizable = true; 232 popup.dependent = true; 233 popup.status = true; 234 window.guidancePopup = popup.open(); 235} 236 237function PopupRules(){ 238 var newWindow = null; 239 if (navigator.appName == "Microsoft Internet Explorer" && (navigator.appVersion > 2.0)) 240 { 241 newWindow = window.open("", "popWindow", 242 "left=110,top=100,toolbar=yes,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=560,height=300"); 243 newWindow.close(); 244 while(! newWindow.closed) ; 245 } 246 newWindow = window.open("/14/ReplaceableRules-FullVersion.pdf", "popWindow", 247 "left=110,top=100,toolbar=yes,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=560,height=300"); 248 if (navigator.appName != "Microsoft Internet Explorer") 249 { 250 251 newWindow.focus() 252 } 253} 254function PopupLinkedRules(){ 255 var newWindow2 = null; 256 if (navigator.appName == "Microsoft Internet Explorer" && (navigator.appVersion > 2.0)) 257 { 258 newWindow2 = window.open("", "popWindow2", 259 "left=200,top=200,toolbar=yes,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=560,height=300"); 260 newWindow2.close(); 261 while(! newWindow2.closed) ; 262 } 263 newWindow2 = window.open("/l3/replaceable.asp", "popWindow2", 264 "left=200,top=200,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=560,height=300"); 265 if (navigator.appName != "Microsoft Internet Explorer") 266 { 267 268 newWindow2.focus() 269 } 270} 271 272function _global_onLoad() { 273 MM_preloadImages('/common/images/start_incorporator_r.gif','#958434902255'); 274 MM_preloadImages('/common/images/faq_r.gif','#958434924136'); 275 MM_preloadImages('/common/images/resource_r.gif','#958434941151'); 276 MM_preloadImages('/common/images/view_summary_r.gif','#958434964665'); 277 MM_preloadImages('/common/images/terms_conditions_r.gif','#958449575585'); 278 MM_preloadImages('/common/images/copyright_r.gif','#958449768192'); 279 MM_preloadImages('/common/images/email_friend_r.gif','#958449797404'); 280 MM_preloadImages('/common/images/back_r.gif','#958456712527'); 281 MM_preloadImages('/common/images/guidance_boxleft.gif','#958456737233'); 282 MM_preloadImages('/common/images/guidance_boxbutton.gif','#958456737213'); 283 MM_preloadImages('/common/images/guidance_boxtitle.gif','#958456737223'); 284 MM_preloadImages('/common/images/guidance_02.gif','#958456737244'); 285 MM_preloadImages('/common/images/guidance_03.gif','#958456737245'); 286 MM_preloadImages('/common/images/guidance_04.gif','#958456737246'); 287 MM_preloadImages('/common/images/guide_bottom.gif','#958456737247'); 288 //var timeoutReference = setTimeout('setSessionTimeout()', '43200000' ); 289} 290 291function _loib_onClick(varForm, strName, strOnClick, blnTest) { 292 varForm[strName].value = '1'; 293 if (blnTest) { 294 var blnSub; 295 eval("blnSub = " + strOnClick); 296 if (blnSub) 297 varForm.submit(); 298 else 299 varForm[strName].value = ''; 300 } else if (strOnClick == 'null') { 301 varForm.submit(); 302 } else { 303 eval(strOnClick); 304 } 305} 306 307function _page_continue(form) { 308 if (typeof(formSubmitted) != "undefined") { 309 if (formSubmitted) { 310 if (typeof(formSubmittedMessage) != "undefined") { 311 alert( formSubmittedMessage ); 312 } 313 return false; 314 } 315 } 316 var successful = true; 317 var elements = form.elements; 318 for (var i = 0; successful && i < elements.length; i++) { 319 if (elements[i].validate) { 320 successful = elements[i].validate(); 321 } 322 } 323 if (successful) { 324 if (typeof(formSubmitted) != "undefined") { 325 formSubmitted = true; 326 } 327 } 328 return successful; 329} 330 331 function BookMark() { 332 if (navigator.appVersion.indexOf("Mac") != -1) 333 { 334 alert('Please press Apple Key + D to add Incorporator to your bookmarks. '); 335 } 336 else 337 { 338 if (navigator.appName =="Microsoft Internet Explorer") 339 { 340 window.external.addFavorite("http://www.incorporator.com.au",document.title ); 341 } 342 else 343 { 344 if (navigator.appName =="Netscape") 345 { 346 alert('Please press Crtl + D to add Incorporator to your bookmarks.'); 347 } 348 else 349 { 350 alert('Please press Crtl + D to add Incorporator to your bookmarks.' ); 351 } 352 } 353 } 354 }
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.