
/* Merged Plone Javascript file
 * This file is dynamically assembled from separate parts.
 * Some of these parts have 3rd party licenses or copyright information attached
 * Such information is valid for that section,
 * not for the entire composite file
 * originating files are separated by - filename.js -
 */

/* - reloadImage.js - */
// http://commstudies.ucla.edu/portal_javascripts/reloadImage.js?original=1
function reloadImage(){if(document.images.randimg){var now=new Date();document.images.randimg.src="/random_images/randimg?time="+now.getTime();setTimeout("reloadImage()",3000)}}
setTimeout("reloadImage()",3000);

/* - reloadAlumni.js - */
// http://commstudies.ucla.edu/portal_javascripts/reloadAlumni.js?original=1
function reloadAlumni(loader){if(loader)
loader.onload="";if(!this.vsrc||!this.hsrc||!this.dest){this.vsrc=document.getElementById("thumb_vsrc");this.hsrc=document.getElementById("thumb_hsrc");this.dest=document.getElementById("thumb_dest");if(!this.vsrc||!this.hsrc||!this.dest)
return;pos=Math.floor(Math.random() * this.vsrc.childNodes.length);this.dest.appendChild(this.vsrc.childNodes[pos]);pos=Math.floor(Math.random() * this.vsrc.childNodes.length);this.dest.appendChild(this.vsrc.childNodes[pos]);pos=Math.floor(Math.random() * this.hsrc.childNodes.length);this.dest.appendChild(this.hsrc.childNodes[pos]);pos=Math.floor(Math.random() * this.vsrc.childNodes.length);this.dest.appendChild(this.vsrc.childNodes[pos]);pos=Math.floor(Math.random() * this.vsrc.childNodes.length);this.dest.appendChild(this.vsrc.childNodes[pos]);this.rotate=0}
oldimg=this.dest.childNodes[rotate];if(this.rotate==2){pos=Math.floor(Math.random() * this.hsrc.childNodes.length);newimg=this.hsrc.childNodes[pos];this.hsrc.appendChild(this.dest.replaceChild(newimg,oldimg))}
else{pos=Math.floor(Math.random() * this.vsrc.childNodes.length);newimg=this.vsrc.childNodes[pos];this.vsrc.appendChild(this.dest.replaceChild(newimg,oldimg))}
this.rotate++;if(this.rotate==5)
this.rotate=0;setTimeout("reloadAlumni(null)",3000)}

/* - popup.js - */
// http://commstudies.ucla.edu/portal_javascripts/popup.js?original=1
function popup(){window.open(this.href,'description','width = 500, height = 175, location = no, menubar = no, resizable = yes, scrollbars = yes, status = no, toolbar = no');return false}
function course_links(){var coursenum;for(var i=0;i<document.links.length;i++){if(document.links[i].href.search("courses#")!=-1){coursenum=document.links[i].hash.substring(1);document.links[i].href="/showcourse?course="+coursenum;document.links[i].onclick=popup}}}
