var valueProfileCompanyFocus;
function checkTel(elem)
{
//alert(event.keyCode);
/*
if(elem.name == "tel_prefix" && elem.value.length == 4 && event.keyCode != 46 && event.keyCode != 16 && event.keyCode != 9)
{
document.getElementById('tel_zone').focus();
}
*/
if(isNaN(elem.value))
{
elem.value = elem.value.substr(0,elem.value.length-1);
return;
}
}
function get_wnd(path)
{
window.open(path,'','width=700,height=600,scrollbars=yes,resizable=yes,status=yes');
}
function get_wnd1(path)
{
//path = "window.html?win="+path;
path = "index.html?win="+path;
window.open(path,'','width=700,height=600,scrollbars=yes,resizable=yes');
}
function pop_print(pg,lg,doc) {
tmp="print.html?page="+pg+"&lang="+lg+"&doc="+doc;
window.open(tmp,'','resizable=1,toolbar=no,status=no,scrollbars=yes,location=no,menubar=no,width=750,height=650');
}
function launch_printer(path,hidden)
{
var top = 0;
var left = 0;
var width = 750;
var height = 550
if(hidden)
{
left = "10000";
}
window.open(path,'','resizable=1,toolbar=no,status=no,scrollbars=yes,location=no,menubar=yes,width='+width+',height='+height+',top='+top+',left='+left);
}
NS4 = (document.layers) ;
IE4 = (document.all) ;
mac=((IE4)&&(navigator.appVersion.indexOf ("Mac")!=-1));
DOM=document.documentElement&&!NS4&&!IE4;
mswnd=(navigator.appVersion.indexOf("Windows")!=-1||navigator.appVersion.indexOf("WinNT")!=-1);
if(IE4)
{
av=navigator.appVersion;
avi=av.indexOf("MSIE");
if (avi==-1)
version = parseInt (av) ;
else
version = parseInt(av.substr(avi+4)) ;
}
if (NS4 || IE4 || DOM)
{
maxlev = 3;
popupWidth = 200; // longueur de la cellule
levelOffset = 0; // positionnement horizontal du second niveau
bord = 1; // epaisseur du bord de tous le tableau
vertSpace = 1; // hauteur de la cellule
sep = 1; // epaisseur de la ligne séparatrice des cellules
sepFrame = false;
openSameFrame = false;
cntFrame = "content";
contentFrame = "content";
mout = true;
iconSize = 8; // taille de l'icon qui avertit si un sous-niveau existe, afichage à droite du menu
imgFolder = "pics"; // folder pour l'icon
closeDelay = 750; // délais de fermeture du menu en miliseconde
tlmOrigBg = ""; // nav_back_color
tlmOrigCol = ""; // nav_color
bBitmapScheme = false;
bBitmapPopups = false;
popupOpenHeight = 0; // hauteur de l'espace du menu
popupLeftPad = 0; // espace à gauche entre le bord de la cellule et le contenu text
popupRightPad = 0; // espace à droite entre le bord de la cellule et le contenu text
tlmHlBg = "#FFFFFF"; // subnav_back_color
tlmHlCol = ""; // subnav_color
borderCol = "#000000";
menuHorizontal = true; // menu horizontal->true, menu vertical->false
scrollHeight=0;
popupOffset = 7; // positionnement horizontal du premier niveau
popupWidth_vert = 200; // longueur de la cellule
levelOffset_vert = 0; // positionnement horizontal du second niveau
tlmOrigBg_vert = "#616465"; // nav_back_color
tlmOrigCol_vert = "#FFFFFF"; // nav_color
tlmHlBg_vert = "#ADA2A3"; // subnav_back_color
tlmHlCol_vert = "#FFFFFF"; // subnav_color
borderCol_vert = "#C6C7C8";
menuHorizontal_vert = false; // menu horizontal->true, menu vertical->false
popupOffset_vert = 0; // positionnement horizontal du premier niveau
}
// Navigation script
//lev0 = new Array ("subnav size","1",false,false,"subnav color","subnav backcolor","nav color","font family","nav backcolor") ;
lev0 = new Array ("11.2","1",false,false,"#FFFFFF","#006EA9","#FFFFFF","Arial","#006EA9") ;
lev1 = new Array ("11.2","1",false,false,"#FFFFFF","#006EA9","#FFFFFF","Arial","#006EA9") ;
lev2 = new Array ("11.2","1",false,false,"#FFFFFF","#006EA9","#FFFFFF","Arial","#006EA9") ;
lev3 = new Array ("11.2","1",false,false,"#FFFFFF","#006EA9","#FFFFFF","Arial","#006EA9") ;
lev0_vert = new Array ("11.2","1",false,false,"#FFFFFF","#ADA2A3","#FFFFFF","Arial Black","#616465") ;
lev1_vert = new Array ("11.2","1",false,false,"#FFFFFF","#ADA2A3","#FFFFFF","Arial Black","#616465") ;
lev2_vert = new Array ("11.2","1",false,false,"#FFFFFF","#ADA2A3","#FFFFFF","Arial Black","#616465") ;
lev3_vert = new Array ("11.2","1",false,false,"#FFFFFF","#ADA2A3","#FFFFFF","Arial Black","#616465") ;
absPath="";
if (sepFrame && !openSameFrame)
{
if (document.URL.lastIndexOf("\\")>document.URL.lastIndexOf("/")) {sepCh = "\\" ;} else {sepCh = "/" ;}
absPath = document.URL.substring(0,document.URL.lastIndexOf(sepCh)+1);
}
if (NS4)
{
document.write("<"+"SCRIPT LANGUAGE='JavaScript1.2' SRC='scripts/ns4.js'><"+"/"+"SCRIPT>");
document.write("<"+"SCRIPT LANGUAGE='JavaScript1.2' SRC='scripts/ns4_vert.js'><"+"/"+"SCRIPT>");
}
else
{
document.write("<"+"SCRIPT LANGUAGE='JavaScript1.2' SRC='scripts/dom.js'><"+"/"+"SCRIPT>");
document.write("<"+"SCRIPT LANGUAGE='JavaScript1.2' SRC='scripts/dom_vert.js'><"+"/"+"SCRIPT>");
}
//document.write("");
// news ticker function
var newslist=new Array();
var cnt=0; // current news item
var curr = "";
var i=-1; // current letter being typed
//mxt.innerHTML = "
";
//newslist[0]=new Array("International Women's Day >>more...","news.html?wnd=119");
function newsticker()
{
// next character of current item
if (i < newslist[cnt][0].length - 1)
{
i++;
temp1 = newslist[cnt][0];
temp1 = temp1.split('');
curr = curr+temp1[i];
temp2 = newslist[cnt][1];
mtxt.innerHTML = ""+curr+"_";
setTimeout('newsticker()',10)
return;
}
// new item
i = -1; curr = "";
if (cnt @ , ; : \ " . [ ] */
var specialChars="\\(\\)<>@,;:\\\\\\\"\\.\\[\\]"
/* The following string represents the range of characters allowed in a
username or domainname. It really states which chars aren't allowed. */
var validChars="\[^\\s" + specialChars + "\]"
/* The following pattern applies if the "user" is a quoted string (in
which case, there are no rules about which characters are allowed
and which aren't; anything goes). E.g. "jiminy cricket"@disney.com
is a legal e-mail address. */
var quotedUser="(\"[^\"]*\")"
/* The following pattern applies for domains that are IP addresses,
rather than symbolic names. E.g. joe@[123.124.233.4] is a legal
e-mail address. NOTE: The square brackets are required. */
var ipDomainPat=/^\[(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\]$/
/* The following string represents an atom (basically a series of
non-special characters.) */
var atom=validChars + '+'
/* The following string represents one word in the typical username.
For example, in john.doe@somewhere.com, john and doe are words.
Basically, a word is either an atom or quoted string. */
var word="(" + atom + "|" + quotedUser + ")"
// The following pattern describes the structure of the user
var userPat=new RegExp("^" + word + "(\\." + word + ")*$")
/* The following pattern describes the structure of a normal symbolic
domain, as opposed to ipDomainPat, shown above. */
var domainPat=new RegExp("^" + atom + "(\\." + atom +")*$")
/* Finally, let's start trying to figure out if the supplied address is
valid. */
/* Begin with the coarse pattern to simply break up user@domain into
different pieces that are easy to analyze. */
var matchArray=emailStr.match(emailPat)
if (matchArray==null) {
/* Too many/few @'s or something; basically, this address doesn't
even fit the general mould of a valid e-mail address. */
alert("Wrong e-mail format (check @ and .'s)")
return false
}
var user=matchArray[1]
var domain=matchArray[2]
// See if "user" is valid
if (user.match(userPat)==null) {
// user is not valid
alert("The username doesn't seems to be valid.")
return false
}
/* if the e-mail address is at an IP address (as opposed to a symbolic
host name) make sure the IP address is valid. */
var IPArray=domain.match(ipDomainPat)
if (IPArray!=null) {
// this is an IP address
for (var i=1;i<=4;i++) {
if (IPArray[i]>255) {
alert("Invalid destination IP address!")
return false
}
}
return true
}
// Domain is symbolic name
var domainArray=domain.match(domainPat)
if (domainArray==null) {
alert("Invalid domain name")
return false
}
/* domain name seems valid, but now make sure that it ends in a
three-letter word (like com, edu, gov) or a two-letter word,
representing country (uk, nl), and that there's a hostname preceding
the domain or country. */
/* Now we need to break up the domain to get a count of how many atoms
it consists of. */
var atomPat=new RegExp(atom,"g")
var domArr=domain.match(atomPat)
var len=domArr.length
if (domArr[domArr.length-1].length<2 ||
domArr[domArr.length-1].length>3) {
// the address must end in a two letter or three letter word.
alert("The e-mail address has an invalid domain extension.")
return false
}
// Make sure there's a host name preceding the domain.
if (len<2) {
var errStr="Wrong domain name."
alert(errStr)
return false
}
// If we've gotten this far, everything's valid!
return true;
}
/*************************************************************************
This code is from Dynamic Web Coding at http://www.dyn-web.com/
See Terms of Use at http://www.dyn-web.com/bus/terms.html
Permission granted to use this code
as long as this entire notice is included.
*************************************************************************/
function getDocHeight(doc) {
var docHt = 0, sh, oh;
if (doc.height) docHt = doc.height;
else if (doc.body) {
if (doc.body.scrollHeight) docHt = sh = doc.body.scrollHeight;
if (doc.body.offsetHeight) docHt = oh = doc.body.offsetHeight;
if (sh && oh) docHt = Math.max(sh, oh);
}
return docHt;
}
function setIframeHeight(iframeName) {
var iframeWin = window.frames[iframeName];
var iframeEl = document.getElementById? document.getElementById(iframeName): document.all? document.all[iframeName]: null;
if ( iframeEl && iframeWin ) {
iframeEl.style.height = "auto"; // helps resize (for some) if new doc shorter than previous
var docHt = getDocHeight(iframeWin.document);
// need to add to height to be sure it will all show
if (docHt) iframeEl.style.height = docHt + 30 + "px";
}
}
function loadIframe(iframeName, url) {
if ( window.frames[iframeName] ) {
window.frames[iframeName].location = url;
return false;
}
else return true;
}