var banner={
'#banner a' : function(el){
el.addClassName('track')
el.writeAttribute('track','/'+el.title)
},
'#promotion' : function(el){
el.onclick=function(){
$('promotion').toggle()}
},
'.promotion' : function(el){
el.onclick=function(){
($('promotion').visible())? msg.start(): msg.stop()
$('promotion').toggle()
return false}
},
'.banner.next' : function(el){
el.onclick=function(){
msg.next()
return false}
},
'.banner.previous' : function(el){
el.onclick=function(){
msg.previous()
return false}
},
'.banner.pause' : function(el){
el.onclick=function(){
msg.pause()
return false}
},
'.banner.resume' : function(el){
el.onclick=function(){
msg.resume()
return false}
},
'#contentbox' : function(el){
if(readCookie('contentlayer'))
el.style.display="none"
},
'#contentbox .contentboxheader a' : function(el){
el.onclick=function(){
$('contentbox').toggle()
createCookie('contentlayer','true','90','/')
return false}
},
'a.contentbox' : function(el){
el.onclick=function(){
$('contentbox').toggle()
return false}}}
var local={
'.presentation' : function(el){
el.onclick=function(){
window.open(el.href,'_blank','width=500, height=360')
return false}
},
'#content .issuu' : function(el){
var hrefArray=(el.href)? el.href.split("/"): 0
var id=(hrefArray.length>0)? hrefArray[hrefArray.length-1] : ''
var width=el.width
var width=640
var height=480
var movieUrl="http://static.issuu.com/webembed/viewers/style1/v1/IssuuViewer.swf"
var flashvars={
jsAPIClientDomain: "http://www.straumann.ca",
mode:"embed",
layout:"http%3A%2F%2Fskin.issuu.com%2Fv%2Flight%2Flayout.xml",
showFlipBtn:"true",
documentId:id,
docName:"agent2issue4",
username:"AGENT2",
loadingInfoText:"",
et:"1251461518896",
er:"26"}
var params={
scale: "NoBorder",
bgcolor: "",
menu: "false",
allowfullscreen: "true"}
var attributes={}
$(el).id="myMovie"
$(el).update(loadMedia(movieUrl,width,height,flashvars,params,attributes))}}
var events={
'button#advanced' : function(el){
if(readCookie("eventAdvanced")){
$("advancedfields").toggle()}
el.onclick=function(){
if($("advancedfields").visible()){
eraseCookie("eventAdvanced")}
else{
createCookie("eventAdvanced",true)}
$("advancedfields").toggle()}}
,
'.eventplace' : function(el){
el.onclick=function(){
$("eventplace").toggle()
return false}}
,
'.organizer' : function(el){
el.onclick=function(){
$("organizer").toggle()
return false}}}
var courses={
'a#busy' : function(el){
$$('tr.busy').each(function(s){s.toggle();return false;})
el.onclick=function(){
$$('tr.busy').each(function(s){s.toggle();return false;})
return false}}
,
'a.speaker' : function(el){
el.onclick=function(){
el.next().toggle()
return false}}
,
'a#courseLevel' : function(el){
el.onclick=function(){
$('legend').toggle()
return false}}
,
'a#courseregistration' : function(el){
el.onclick=function(){
$('courseRegForm').toggle()
return false}}}
Behaviour.register(banner)
Behaviour.register(local)
Behaviour.register(events)
Behaviour.register(courses)
