/************************************************************************************* * This script provides the profile pictures' effect. * * It consists of both PHP and JavaScript code for practical and protective reasons. * * No PHP or JavaScript libraries were used. * * * * Author: Viktor Varadi * * * * All rights reserved! * * * *************************************************************************************/ //------------ PHP generated variables START ------------ var l = new Array(184,192,197,201,203,203,201,197,192,184,175,164,153,140,126,112,98,84,70,57,45,34,24,15,9,4,1,0); height = 175; var uname = new Array('micheal55','Annietha','faithhill1st','janejackson','mynewstatus36','Countrydiva','morningdew51','vivian143','lexkygal3','m4love1984','archingheart114','Soulmelody7','adventurous231','Honestman','karrianne','kelajoe','mrolling101','fresher123','butterflycup703','applebabyabc','richie1','moondance','robertaney','elmagnifico','Don11q','marcindreams','bentley2010','jasonsearch','nickwilliamsa','hoenykevin','affectionateman50','terrycolem8182'); var occ = new Array('Pilot','Nurse','Investment Professional','Self-employed Person','Civil Engineer','Advertising Visualiser','Accountant','Student','Professor','Beautician','Civil Engineer','Creative Person','Consultant','Government Employee','Teacher','Self-employed Person','Self-employed Person','Company Secretary','Doctor','Accountant','Contractor','Psychologist','Contractor','Marketing Professional','Accountant','Self-employed Person','Nurse','Civil Engineer','Sales Professional','Accountant','Accountant','Engineer'); var city = new Array('Portland','Westmont','Baldwin City','Highland Park','Highland Park','Yorba Linda','Lewiston','New york','Lexington','seattle','Princeton','Olympia','Chase city','Addison','Atlanta','Sugar land','Westwood','Beverly hills','Savannah','New york','Alan','Aurora','JACKSONVILLE','Arvada','Allen Park','Kinderhook','Benson','Old Chelsea','Columbus','Chi town','Smithfield','Maple Glen'); var photo = new Array('../media/photographs/thumbnails/0878a3f15e9c990620f9807885431cce90f55a70.jpg','../media/photographs/thumbnails/f38d2eb6dcf5fa31fe8c11dba9309f8de99ed059.jpg','../media/photographs/thumbnails/76ba2bc8e8a693abe5d7517dd0ecf290b91a2f32.jpg','../media/photographs/thumbnails/74adcb9ef1c5e3c95411bcd56b42fd809f5874fd.jpg','../media/photographs/thumbnails/0f6d920944849da5d6f0fa5286b6de36af662c0a.jpg','../media/photographs/thumbnails/3f30deae39cb34eb87cc25ab4e38b8e6236c3a8d.jpg','../media/photographs/thumbnails/aaa25a7e8239c37882caba59b250854960a4a8a5.jpg','../media/photographs/thumbnails/abed2f0059de83e5b2c94579c587688c514a7f5f.jpg','../media/photographs/thumbnails/8c721df729b8e8b1f60cc24151c49516f5ace271.jpg','../media/photographs/thumbnails/da87802a305dc75a38c6875eb228c212be4d79d0.jpg','../media/photographs/thumbnails/9c53960655db537c16574fbc5bd05de61beb0e05.jpg','../media/photographs/thumbnails/feca080a1de105ef770214f48e72b1e81ec3363a.jpg','../media/photographs/thumbnails/49a217645aaab69e8c968d30416e6980a07f5819.jpg','../media/photographs/thumbnails/eee3bb5179070bf2b396ad5d855e4c8787ba546c.jpg','../media/photographs/thumbnails/6645205d7fa2f330c22592bfa4c0cbb6831e0462.jpg','../media/photographs/thumbnails/08c967e850890b413e1df5521e903c316b44bc6d.jpg','../media/photographs/thumbnails/f54b059eb9b9863fd1aea386569db1698176e3d5.jpg','../media/photographs/thumbnails/661c874f68222fc75cfd156e7b682dccdb96dcd5.jpg','../media/photographs/thumbnails/3139a818d3ce4707e2aebd2c3db5807701361036.jpg','../media/photographs/thumbnails/823a79698aeaa94d17546dc63cdc153d25af3499.jpg','../media/photographs/thumbnails/436f64b6a18c2705b25903dbf4687c2e398e3565.jpg','../media/photographs/thumbnails/8fb755243d6ecebfaef09b9943cff494e72ce9c8.jpg','../media/photographs/thumbnails/91c9b3bca02df29eb3efba669655b7d35c41e6c5.jpg','../media/photographs/thumbnails/0b48bce4e429fc9ba74d38cc777a1ddf35a93d7b.jpg','../media/photographs/thumbnails/9aeda701e29ac019989ea8ad83e07a2c3108d705.jpg','../media/photographs/thumbnails/6862e248df5b8eaed94d233a428cb6a868e349a8.jpg','../media/photographs/thumbnails/f1f3ab258ebd2270e7ce7f2b47d187eff6788b07.jpg','../media/photographs/thumbnails/f82b2eaf62692b5ecc047ba17c144b2e03e86de6.jpg','../media/photographs/thumbnails/92a4e0622ed19433f4a88fdd649998b1512c1a4d.jpg','../media/photographs/thumbnails/7c049bd586f999e3bfb0125f79558fde1e8ad7f6.jpg','../media/photographs/thumbnails/9e4b208e29a894144ae315eb7ee5103ac6e38c43.jpg','../media/photographs/thumbnails/57c6783592f85985c8e455bf8bb5a67a6c8fe8db.jpg'); var num_of_places = 8; var num_of_sets = 4; var pause = 3000; var delta = 100; var first_line = Array(0,0,0,0,0,0,0,0,0); var second_line = Array(1,1,1,1,1,1,1,1,1); var step = new Array(0,0,0,0,0,0,0,0,0); last_prof = 0; //------------ PHP generated variables END ------------ function Scroll(col) { //alert(col+" + "+num_of_places+" * "+first_line[col]+" = "+(col+num_of_places*first_line[col])); document.getElementById("prof"+(col+num_of_places*first_line[col])).style['top'] = l[step[col]] - height + "px"; document.getElementById("prof"+(col+num_of_places*second_line[col])).style['top'] = l[step[col]] + "px"; step[col]++; if (step[col] < l.length) setTimeout(function(){Scroll(col)}, 30); else { step[col] = 0; first_line[col] = 1 - first_line[col]; second_line[col] = 1 - first_line[col]; document.getElementById("prof"+(col+num_of_places*second_line[col])).style['top'] = height + "px"; if (col == num_of_places) { Refresh(second_line[col]); setTimeout("Animator()", pause); } } } function Refresh(line) { for (var col=1; col < num_of_places+1; col++) { curr_place = col+num_of_places*line; curr_prof = (last_prof+col)%(num_of_places*num_of_sets); document.getElementById("prof"+curr_place+"_pic").innerHTML = ''; document.getElementById("prof"+curr_place+"_occ").innerHTML = occ[curr_prof]; //document.getElementById("prof"+curr_place+"_age").innerHTML = age[curr_prof]; document.getElementById("prof"+curr_place+"_city").innerHTML = city[curr_prof]; document.getElementById("prof"+curr_place+"_lnk").href = "/dating/view-profile-" + uname[curr_prof] + ".html"; } last_prof = (last_prof+num_of_places)%(num_of_places*num_of_sets); } function Animator() //PHP generated { setTimeout("Scroll(1)", pause+(1-1)*delta); setTimeout("Scroll(2)", pause+(2-1)*delta); setTimeout("Scroll(3)", pause+(3-1)*delta); setTimeout("Scroll(4)", pause+(4-1)*delta); setTimeout("Scroll(5)", pause+(5-1)*delta); setTimeout("Scroll(6)", pause+(6-1)*delta); setTimeout("Scroll(7)", pause+(7-1)*delta); setTimeout("Scroll(8)", pause+(8-1)*delta); } function InitScroller() { Refresh(first_line[1]); Refresh(second_line[1]); setTimeout("Animator()", pause); }