PageSourceSearch

https://ibsindia.org/IBSAF/common/js/pausescroller.js

js ibsindia.org collected 2026-09-24 19:41:07 UTC 6,435 bytes, 91 lines download raw bytes

1var pausecontent=new Array()
2pausecontent[0]='<p>New Delhi, Gurgaon, Meerut<br> Agra, Rohini, Chandigarh<br> Ludhiana<br><br /><strong>Contact</strong>: Prof. Prapti Paul<br /><strong>Campus</strong>: IBS Gurgaon<br /> <strong>Phone</strong>: +91 9891768799 <br /><strong>email</strong>: [email protected]</p>'
3pausecontent[1]='<p>Lucknow, Kanpur, Mandi<br> Allahabad, Bareilly, Shimla<br> Dehradun, Karnal<br><br /><strong>Contact</strong>: Mr. Sanjeev Malya<br /><strong>Campus</strong>: IBS Dehradun<br /> <strong>Phone</strong>: +91-135-3003081<br /><strong>email</strong>: [email protected] </p>'
4pausecontent[2]='<p>Hyderabad,Vijayawada<br>Vishakapatnam<br><br /><strong>Contact</strong>: Mr. Srinivas C <br /><strong>Campus</strong>: IBS Hyderabad<br /> <strong>Phone</strong>: +91 9848411643<br /><strong>email</strong>: [email protected]  </p>'
5pausecontent[3]='<p>Bangalore, Chennai<br> Coimbatore, Kochi<br><br /><strong>Contact</strong>: Prof. J Venkataraman  <br /><strong>Campus</strong>: IBS Bangalore <br /> <strong>Phone</strong>: +91 9845761498<br />[email protected]  </p>'
6pausecontent[4]='<p>Ahmedabad , Baroda, Indore<br> Bhopal, Gwalior<br><br /><strong>Contact</strong>: Prof. Vivek Ranga   <br /><strong>Campus</strong>: IBS Ahmedabad <br /> <strong>Phone</strong>: +91 9825945510<br /><strong>email</strong>: [email protected]   </p>'
7pausecontent[5]='<p>Jaipur, Alwar, Udaipur<br> Jodhpur<br><br /><strong>Contact</strong>:Mr. Naresh Kumar<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sharma<br /><strong>Campus</strong>: IBS Jaipur  <br /> <strong>Phone</strong>: +91-79-65430148<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 65430149 <br /><strong>email</strong>: [email protected]    </p>'
8pausecontent[6]='<p>Kolkata, Bhubaneshwar<br> Guwahati, Ranchi<br> Jamshedpur, Dhanbad, Patna<br><br /><strong>Contact</strong>: Prof. Sumita <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Mukherjee<br /><strong>Campus</strong>: IBS Kolkata   <br /> <strong>Phone</strong>: +91 9831217446 <br /><strong>email</strong>: [email protected]</p>'
9pausecontent[7]='<p>Mumbai, Nasik, Nagpur<br><br /><strong>Contact</strong>: Ms. Hema Sisodia  <br /><strong>Campus</strong>: IBS Mumbai<br /> <strong>Phone</strong>: +91 9820027928 <br /><strong>email</strong>: [email protected]   </p>'
10pausecontent[8]='<p>Pune, Aurangabad<br> Kolhapur<br><br /><strong>Contact</strong>: Dr. Ashwini Sovani   <br /><strong>Campus</strong>: IBS Pune<br /> <strong>Phone</strong>: +91 9822912145 <br />[email protected]    </p>'
11
12function pausescroller(content, divId, divClass, delay){
13this.content=content //message array content
14this.tickerid=divId //ID of ticker div to display information
15this.delay=delay //Delay between msg change, in miliseconds.
16this.mouseoverBol=0 //Boolean to indicate whether mouse is currently over scroller (and pause it if it is)
17this.hiddendivpointer=1 //index of message array for hidden div
18
19document.write('<div id="'+divId+'" class="'+divClass+'" style="position: relative; overflow: hidden"><div class="innerDiv" style="position: absolute; width: 100%" id="'+divId+'1">'+content[0]+'</div><div class="innerDiv" style="position: absolute; width: 100%; visibility: hidden" id="'+divId+'2">'+content[1]+'</div></div>')
20var scrollerinstance=this
21if (window.addEventListener) //run onload in DOM2 browsers
22window.addEventListener("load", function(){scrollerinstance.initialize()}, false)
23else if (window.attachEvent) //run onload in IE5.5+
24window.attachEvent("onload", function(){scrollerinstance.initialize()})
25else if (document.getElementById) //if legacy DOM browsers, just start scroller after 0.5 sec
26setTimeout(function(){scrollerinstance.initialize()}, 500)
27}
28
29pausescroller.prototype.initialize=function(){
30this.tickerdiv=document.getElementById(this.tickerid)
31this.visiblediv=document.getElementById(this.tickerid+"1")
32this.hiddendiv=document.getElementById(this.tickerid+"2")
33this.visibledivtop=parseInt(pausescroller.getCSSpadding(this.tickerdiv))
34//set width of inner DIVs to outer DIV's width minus padding (padding assumed to be top padding x 2)
35this.visiblediv.style.width=this.hiddendiv.style.width=this.tickerdiv.offsetWidth-(this.visibledivtop*2)+"px"
36this.getinline(this.visiblediv, this.hiddendiv)
37this.hiddendiv.style.visibility="visible"
38var scrollerinstance=this
39document.getElementById(this.tickerid).onmouseover=function(){scrollerinstance.mouseoverBol=1}
40document.getElementById(this.tickerid).onmouseout=function(){scrollerinstance.mouseoverBol=0}
41if (window.attachEvent) //Clean up loose references in IE
42window.attachEvent("onunload", function(){scrollerinstance.tickerdiv.onmouseover=scrollerinstance.tickerdiv.onmouseout=null})
43setTimeout(function(){scrollerinstance.animateup()}, this.delay)
44}
45
46pausescroller.prototype.animateup=function(){
47var scrollerinstance=this
48if (parseInt(this.hiddendiv.style.top)>(this.visibledivtop+5)){
49this.visiblediv.style.top=parseInt(this.visiblediv.style.top)-5+"px"
50this.hiddendiv.style.top=parseInt(this.hiddendiv.style.top)-5+"px"
51setTimeout(function(){scrollerinstance.animateup()}, 50)
52}
53else{
54this.getinline(this.hiddendiv, this.visiblediv)
55this.swapdivs()
56setTimeout(function(){scrollerinstance.setmessage()}, this.delay)
57}
58}
59
60pausescroller.prototype.swapdivs=function(){
61var tempcontainer=this.visiblediv
62this.visiblediv=this.hiddendiv
63this.hiddendiv=tempcontainer
64}
65
66pausescroller.prototype.getinline=function(div1, div2){
67div1.style.top=this.visibledivtop+"px"
68div2.style.top=Math.max(div1.parentNode.offsetHeight, div1.offsetHeight)+"px"
69}
70
71pausescroller.prototype.setmessage=function(){
72var scrollerinstance=this
73if (this.mouseoverBol==1) //if mouse is currently over scoller, do nothing (pause it)
74setTimeout(function(){scrollerinstance.setmessage()}, 100)
75else{
76var i=this.hiddendivpointer
77var ceiling=this.content.length
78this.hiddendivpointer=(i+1>ceiling-1)? 0 : i+1
79this.hiddendiv.innerHTML=this.content[this.hiddendivpointer]
80this.animateup()
81}
82}
83
84pausescroller.getCSSpadding=function(tickerobj){ //get CSS padding value, if any
85if (tickerobj.currentStyle)
86return tickerobj.currentStyle["paddingTop"]
87else if (window.getComputedStyle) //if DOM2
88return window.getComputedStyle(tickerobj, "").getPropertyValue("padding-top")
89else
90return 0
91}

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.