//Functions for CV Web


function HowBig()
{
   var wide = document.body.clientWidth -300;
   var hi = document.body.clientHeight -150;
   document.getElementById("content").style.width = wide+"px";
   document.getElementById("content").style.height = hi+"px";


}   //end of howbig


/*
=============================================
The certification bar
=============================================
*/

function runCert()
/* runs the timing loop for the certification area at the bottom of the page */
{
   timerID = setInterval('changeCert()', 3500);
}  //End of runCert

function changeCert()
/* Generates the certifiaction area */
{
   certs = new Array(5);   //Create a new array...

   certs[0] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/ccna.gif\"></td><td ><b>Cisco Certified Network Associate</b><br><small>CCNA 640-607 : <i>Cisco Routing & Switching</i></small><br><a href = \"http://www.cisco.com\" target = \"new\">www.cisco.com</a></td></tr></table>";
   certs[1] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-214 : <i>Implementing & Administrating Security In a Microsoft Windows 2000 Network</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[2] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-215 : <i>Installing, Configuring, & Administering Microsoft Windows 2000 Server</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[3] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-270 : <i>Installing, Configuring, & Administering Microsoft Windows XP Professional</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[4] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/SECp.jpg\"></td><td ><b>CompTIA Security+</b><br><small>Computer Technology Industry Association SY0-101</small><br><a href = \"http://www.comptia.org/\" target = \"new\">www.comptia.org</a></td></tr></table>";
   certs[5] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCSA-s.jpg\"></td><td ><b>Microsoft Certified Systems Administrator - Security (MCSA)</b><br><small>Windows 2000 Security</small><br><a href = \"http://www.microsoft.com/mcp/\" target = \"new\">http://www.microsoft.com/mcp</a></td></tr></table>";
   certs[6] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-218 : <i>Managing a Microsoft Windows 2000 Network Enviroment</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[7] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCSA.jpg\"></td><td ><b>Microsoft Certified Systems Administrator (MCSA)</b><br><small>Windows 2000</small><br><a href = \"http://www.microsoft.com/mcp/\" target = \"new\">http://www.microsoft.com/mcp</a></td></tr></table>";
   certs[8] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/wcsp_small.gif\"></td><td ><b>Watchguard Certified Systems Professional (WCSP)</b><br><small>Managing Watchguard Firewalls with Fireware software</small><br><a href = \"http://www.watchguard.com\" target = \"new\">http://www.watchguard.com</a></td></tr></table>";
   certs[9] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCSE.jpg\"></td><td ><b>Microsoft Certified Systems Engineer (MCSE)</b><br><small>Windows 2000</small><br><a href = \"http://www.microsoft.com/mcp/\" target = \"new\">http://www.microsoft.com/mcp</a></td></tr></table>";
   certs[10] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCSE-s.jpg\"></td><td ><b>Microsoft Certified Systems Engineer - Security (MCSE)</b><br><small>Windows 2000 Security</small><br><a href = \"http://www.microsoft.com/mcp/\" target = \"new\">http://www.microsoft.com/mcp</a></td></tr></table>";
   certs[11] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-216 : <i>Implementing and Administering a Microsoft Windows 2000 Network Infrastructure</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[12] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/MCP.gif\"></td><td ><b>Microsoft Certified Professional</b><br><small>MCP 70-298 : <i>Designing Security for a Microsoft Windows Server 2003 Network</i> </small><br><a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a></td></tr></table>";
   certs[13] = "<table><tr valign = \"middle\"><td width = \"100\"><img src = \"images/logos/jncia-logo.png\" height = \"50\"></td><td ><b>Juniper Networks Certified Internet Associate - Enterprise Routing</b><br><small>JNCIA-ER JN0-342</small><br><a href = \"http://www.juniper.net/training/certification/\" target = \"new\">www.juniper.net/training/certification/</a></td></tr></table>";

   index = Math.floor(Math.random() * certs.length);
   document.getElementById("certBar").innerHTML = certs[index];
//document.getElementById("certBar").innerHTML = certs[13];   //Used for testing

}  //End of changeCert

/*

/*
================================================
The Latest News element
================================================
*/

newsItem = 0;         // Tracks which news item is currently to be used.
news = new Array();  // The news array is populated in global scope

news[0] = "<table><td width = \"75\"><img src = \"images/logos/jncia-logo.png\"><td><td width = \"500\" height = \"150\"><b>30/01/09</b> - I earned Juniper Networks Certified Internet Associate - Enterprise Routing (JNCIA-ER) certification.<li style = \"font-size:10pt;\">JNCIA-ER certification recognizes the skills and experiance required to deploy and manage Juniper JUNOS routers in an Enterprise enviroment.<li style = \"font-size:10pt;\">For further informaion on JNCIA-ER certiciation click <a href = \"jncia-er.htm\" target = \"new\">HERE</a> or visit <a href = \"http://www.juniper.net/training/certification/\">www.juniper.net/training/certification/</a></td></table>";
news[1] = "<table><td width = \"75\"><img src = \"images/logos/cisecurity.gif\"><td><td width = \"500\" height = \"150\"><b>15/11/08</b> - Following on from the previous development work I have done for CIS, I have been working towards a new Security Benchmark for Juniper Networks routers running JUNOS.<li style = \"font-size:10pt;\"><b>The Center for Internet Security (CIS)</b> is a non-profit enterprise whose mission is to help organizations reduce the risk of business and e-commerce disruptions resulting from inadequate technical security controls.<li style = \"font-size:10pt;\">For further informaion on CIS please visit <a href = \"http://www.cisecurity.org\" target = \"new\">www.cisecurity.org</a> or click <a href = \"cis.htm\">HERE</a></td></table>";
news[2] = "<table><td width = \"75\"><img src = \"images/logos/linkedin.gif\"><td><td width = \"500\" height = \"150\"><b>01/11/08</b> - You can now find my on LinkedIn, the professional social networking site.  Come visit my profile, contact me or add me to your LinkedIn network.<br><a href = \"http://www.linkedin.com/in/routerguy\" target = \"new\">www.linkedin.com/in/routerguy/</a></td></table>";
news[3] = "<table><td width = \"75\"><img src = \"images/logos/future.gif\"><td><td width = \"500\" height = \"150\"><b>01/10/07</b> - I have recently started work with Future Publishing based in Bath as a Senior Network Engineer / Architect.<li style = \"font-size:10pt;\">Future Publishing is one of the UK's largest Magazine publishing organizations with over 100 titles and 60 popular websites.<li style = \"font-size:10pt;\">I have been working with Future to provide a major network refresh and ensure reliable, secure networking and web hosting services.<li style = \"font-size:10pt;\">For further informaion on Future Publishing, please visit <a href = \"http://www.futurenet.co.uk\" target = \"new\">www.futurenet.co.uk</a> or click <a href = \"future.htm\">HERE</a> for more details of this role.</td></table>";
news[4] = "<table><td width = \"75\"><img src = \"images/logos/bbclogo.jpg\"><td><td width = \"500\" height = \"150\"><b>19/05/07</b> - Providing Network Infrastructure consultancy services to BBC Wales from Broadcasting House in Cardiff.<li style = \"font-size:10pt;\">BBC Wales produces and broadcasts TV and Radio in English and Welsh language formats as well as providing Welsh News, education information, community action and many other services throughout Wales.<li style = \"font-size:10pt;\">Some of the BBC's most popular programmes including Dr Who and Torchwood are produced by BBC Wales.<li style = \"font-size:10pt;\">For further informaion on BBC Wales, please visit <a href = \"http://www.bbc.co.uk/wales\" target = \"new\">www.bbc.co.uk/wales</a> or click <a href = \"bbc.htm\">HERE</a> for more details of this role.</td></table>";
news[5] = "<table><td width = \"75\"><img src = \"images/logos/cisecurity.gif\"><td><td width = \"500\" height = \"150\"><b>04/04/07</b> - Following on from volunteer work I have performed as an active member, I have been asked to undertake consultancy work with the Center for Internet Security.<li style = \"font-size:10pt;\"><b>The Center for Internet Security (CIS)</b> is a non-profit enterprise whose mission is to help organizations reduce the risk of business and e-commerce disruptions resulting from inadequate technical security controls.<li style = \"font-size:10pt;\">For further informaion on CIS please visit <a href = \"http://www.cisecurity.org\" target = \"new\">www.cisecurity.org</a> or click <a href = \"cis.htm\">HERE</a> for more information on the work I will be doing.</td></table>";
news[6] = "<table><td width = \"75\"><img src = \"images/logos/MCSE-s.jpg\"><td><td width = \"500\" height = \"150\"><b>23/02/07</b> - I have now completed all 7 exams to earn Microsoft Certified Systems Engineer certification.<li style = \"font-size:10pt;\">This is Microsofts highest techinical certification and I have achieved MCSE status in the <I>Windows 2000</I> and <I>Security</I> specialist tracks.<li style = \"font-size:10pt;\">For further informaion on this program and exams, please visit <a href = \"http://www.microsoft.com/mcp\" target = \"new\">www.microsoft.com/mcp</a>.</td></table>";
news[7] = "<table><td width = \"75\"><img src = \"images/logos/logicacmg.gif\"><td><td width = \"500\" height = \"150\"><b>19/12/06</b> - Consulting with LogicaCMG as a <I>Senior Network Security Analyst</I>.<li style = \"font-size:10pt;\">LogicaCMG are one of the worlds largest IT and Business Services providers with pre-tax profits of over 129.4 Million last year and a presence in over 40 countries.<li style = \"font-size:10pt;\">LogicaCMG provide a wide range of services from their worldwide datacentres to small and large enterprises as well as Government and Defence organisations.<li style = \"font-size:10pt;\">Click <a href = \"logica.htm\">HERE</a> for more details of the company and this position.</td></table>";
news[8] = "<table><td width = \"75\"><img src = \"images/logos/wcsp_sm.gif\"><td><td width = \"500\" height = \"150\"><b>16/08/06</b> - I recently completed the Watchguard Certified Systems Profesional certification program.<li style = \"font-size:10pt;\">The certification recognizes the skills required to manage Watchguard firewall and security products using Fireware software.<li style = \"font-size:10pt;\">For further informaion on this program and Watchguard products, please visit <a href = \"http://www.watchguard.com\" target = \"new\">www.watchguard.com</a>.</td></table>";


function oldNews(way)
/* moves the news backwards or forwards trough the array */
{

   newsItem = newsItem + way;

   if(newsItem == 0)
   {
      document.getElementById("newsFlash").innerHTML = news[newsItem]+"<br><a href = \"javascript:oldNews(1)\">Next Item</a>";
   }
   else if (newsItem < news.length - 1)
   {
         document.getElementById("newsFlash").innerHTML = news[newsItem]+"<br><a href = \"javascript:oldNews(-1)\">Previous Item</a>||<a href = \"javascript:oldNews(1)\">Next Item</a>";
   }
   else
   {
      document.getElementById("newsFlash").innerHTML = news[newsItem]+"<br><a href = \"javascript:oldNews(-1)\">Previous Item</a>";
   };

} //End of oldNews

/*
------------------------------------------------
Menus
------------------------------------------------
*/

function OVRmenu(id, menu)
{
   document.getElementById(id).style.backgroundColor = "#774433";  //Change the link color

      SCRUBmenu(menu);  //Clear down exising menus

   if(menu != "nomenu") {

      document.getElementById(menu).style.top = "15px";  //Sets the current menu down.

      }//End if
};

function SCRUBmenu(menu)
//Collapse all menus
{

   //Set all menus to be off the top of the screen

        menuz = new Array(4); //Create a new array to hold the menu names (as they appear in ID)

        menuz[0] = "MENexp";
        menuz[1] = "MENedu";
//        menuz[2] = "MENskil";
//        menuz[3] = "MENint";
//        menuz[4] = "MENexam";

   for(var menuzI = 0; menuzI < 2; menuzI ++) {    //Initiallise a loop over the array.
      if(menuz[menuzI] != menu) {   //If this is not the current menu
         document.getElementById(menuz[menuzI]).style.top = "-500px";   //Set this menu off the top of the screen
      } //End if
   } //End of Loop (this uses the array to set all of the inactive menus off the screen.

};

function OUTmenu(id)
// Resets the menu items background
{
   document.getElementById(id).style.backgroundColor = "#666666";
};

/*
=============================================
The recommendations counter
=============================================
*/

function runReco()
/* runs the timing loop for the recommendations */
{
    setInterval('changeReco()', 10500);
};  //End of runReco

function changeReco()
/* Generates the certifiaction area */
{
   reco = new Array(3);   //Create a new array...

   reco[0] = "<i font-color = \"#666666\">\"I worked with Martin on a very complex infrastructure project for Future Publishing that Martin. As the technical design architect and project manager, Martin's understanding of Future Publishing's business requirements was key.<br>He fully engaged with both Cisco directly and a number of key partners to ensure that he delivered a solution that not only fulfilled the current business requirement but would also enable Future Publishing to drive operational gains in the future both from a productivity stand point and also an ability to seamlessly add additional applications as needed.<br>Martin\'s planning, briefings, attention to detail and interpersonal skills are exceptional.<br>I have no hesitation in reccomending Martin to any suitable organisation.\"</i><br><br><b>Martyn Jones, Account Manager, Cisco Systems</b>";
   reco[1] = "<i font-color = \"#666666\">\"Very knowledgeable and extremely helpful. Solved a variety of complex technical problems for us.<br>Top Qualities: Great Results, Expert, High Integrity\"</i><br><br><b>Roger Crothers, IT Manager, BBC Wales</b>";
   reco[2] = "<i font-color = \"#666666\">\"Working with Martin has proved to be a consistently rewarding experience for the Network, and entire operations, teams throughout his time with us.<br>His breadth of knowledge and experience, combined with dedication and commitment, have made him able to fill gaps in knowledge and resource, both inside and outside of our team, on a regular basis. Items I would consider key amongst his assets are his flexibility and ability to project his ideas and opinions in a direct and concise manner.<br>Cross platform experience, covering Cisco, Juniper, Foundry and others, with a dynamic workplace attitude should make Martin a useful and easy to integrate addition to any networking team.\"</i><br><br><b>Maria Blackmore, Senior Network Administrator, Future Publishing</b>";

   index = Math.floor(Math.random() * reco.length);
   document.getElementById("recom").innerHTML = reco[index];
};  //End of changeCert
