1function preloadImage(url) 2{ 3 var img=new Image(); 4 img.src=url; 5} 6 7function Interval(fn, time) { 8 var timer = false; 9 this.start = function () { 10 if (!this.isRunning()) 11 timer = setInterval(fn, time); 12 }; 13 this.stop = function () { 14 clearInterval(timer); 15 timer = false; 16 }; 17 this.isRunning = function () { 18 return timer !== false; 19 }; 20} 21 22var amyBlogJson = ''; 23 24 25jQuery( document ).ready(function($){ 26 var address = 'a'+'m'+'y'+'@'+'amy'+'kohn'+'.'+'c'+'o'+'m'; 27 $(".antiemail").html('<a href="mailto:'+address+'">'+address+'</a>'); 28 $(".social-icons a.email").attr("href","mailto:"+address); 29 30 //fix for smartphones 31 var is_mobile = false; 32 is_mobile = ($('#smartphones').css('display')=='none'); 33 34 if (is_mobile) { 35 $("#main-slider .w-slide").eq(0).css('background-image','url(images/homeslide00_50percent.jpg)'); 36 } 37 38 39 $("#mc-embedded-subscribe-form").submit(function(e){ 40 e.preventDefault(); 41 $("#mc_embed_signup .bg-danger").hide(); 42 $.post("mailchimp.php",$(this).serialize(),function(data){ 43 if (data.error) { 44 $("#mc_embed_signup .bg-danger").html(data.error); 45 $("#mc_embed_signup .bg-danger").show(); 46 } else { 47 $("#mc_embed_signup").html(data.message); 48 } 49 }); 50 $('html,body').animate({scrollTop: $("#join").offset().top}); 51 }); 52 53 54 55 56 $("#bottom-space").css("height",$( window ).height()/2) 57 58 $(".pre-order-plexilusso-from-snippet").click(function(){ 59 $("#row-album-plexilusso .ecommerce-intro").slideUp(); 60 $("#row-album-plexilusso .ecommerce-options").slideDown(); 61 }); 62 63 64 function getAmyBlogJson() { 65 $.get("getamyblog.php", function(data){ 66 amyBlogJson = data; 67 }); 68 } 69 70 function AmyBlogLoadPost(index) { 71 $.get("getamyblog.php?index="+index, function(data){ 72 var blogItem = data; 73 var blogItemHtml = ''; 74 if (blogItem.item) { 75 var d = new Date(blogItem.item.ts_published*1000); 76 77 blogItemHtml += '<div class="blog-entry-date">'+d.toDateString()+'</div>'; 78 blogItemHtml += '<div class="blog-entry-title">'+blogItem.item.title+'</div>'; 79 blogItemHtml += '<div class="blog-entry-content">'+blogItem.item.content+'</div>'; 80 $('#blog .w-container').append('<div class="w-row row-blog-item" blog-row-item="'+index+'"><div class="w-col w-col-6">'+ blogItemHtml +'</div></div>'); 81 if (blogItem.next && blogItem.next>0) { 82 $('#blog .w-container').append('<button type="button" class="load-next-post btn btn-primary" next-post-index="'+blogItem.next+'">Load next Blog post</button>'); 83 } 84 85 } 86 }); 87 } 88 89 //load first blog post 90 AmyBlogLoadPost(0); 91 92 93 $(document).on("click",".load-next-post",function(){ 94 var next = $(this).attr("next-post-index"); 95 $(this).remove(); 96 AmyBlogLoadPost(next); 97 }); 98 99 100 101 102 $(".ecommerce-intro button").click(function(){ 103 $(this).closest(".ecommerce-intro").slideUp(); 104 $(this).closest(".ecommerce").find(".ecommerce-options").slideDown(); 105 }); 106 107 108 //toggle top menu bar for mobile devices 109 $(".row-nav-bar .nav-button").click(function(){ 110 $(".row-nav-bar .nav-bar").addClass("toggled"); 111 $(".row-nav-bar .nav-bar").slideToggle(); 112 }); 113 //fix if .nav-bar closed with toggle button and window resize 114 $( window ).resize(function() { 115 if ($(".row-nav-bar .nav-button").is(":hidden")) { 116 if ($(".row-nav-bar .nav-bar").hasClass("toggled")) { 117 $(".row-nav-bar .nav-bar").removeClass("toggled").addClass("forced").show(); 118 } 119 } else { 120 if ($(".row-nav-bar .nav-bar").hasClass("forced")) { 121 $(".row-nav-bar .nav-bar").removeClass("forced").addClass("toggled").hide(); 122 } 123 } 124 });
125 126 $(document).on("click",".row-nav-bar .nav-bar .nav-link",function(){ 127 if ($(".row-nav-bar .nav-button").is(":visible")) { 128 $(".row-nav-bar .nav-bar").slideToggle(); 129 } 130 }); 131 132 //toggle fixed menu bar for mobile devices 133 $(document).on("click",".section-fixed-menu .img .nav-button",function(){ 134 $(".section-fixed-menu .menu").addClass("toggled"); 135 $(".section-fixed-menu .menu").slideToggle(); 136 }); 137 //fix if .nav-bar closed with toggle button and window resize 138 $( window ).resize(function() { 139 if ($(".section-fixed-menu .img .nav-button").is(":hidden")) { 140 if ($(".section-fixed-menu .menu").hasClass("toggled")) { 141 $(".section-fixed-menu .menu").removeClass("toggled").addClass("forced").show(); 142 } 143 } else { 144 if ($(".section-fixed-menu .menu").hasClass("forced")) { 145 $(".section-fixed-menu .menu").removeClass("forced").addClass("toggled").hide(); 146 } 147 } 148 }); 149 150 $(document).on("click",".section-fixed-menu .menu .nav-link",function(){ 151 if ($(".section-fixed-menu .img .nav-button").is(":visible")) { 152 $(".section-fixed-menu .menu").slideToggle(); 153 } 154 }); 155 156 157 158 159 //players 160 $("div.player button").each(function(){ 161 $(this).parent().attr("track",$(this).attr("track")); 162 }); 163 164 $(document).on("click", "div.player button", function(){ 165 var track = $(this).attr("track"); 166 $("div.player").each(function(){ 167 var track = $(this).attr('track'); 168 $(this).html(str_players[track]); 169 }); 170 $("div.player."+track).html(players[track]); 171 172 }); 173 174 //preload some images 175 $("div.preloader").append('<img src="/images/AmyKohnPlexiFont-120px.png">'); 176 177 $(document).on("click","a.back-to-top",function(e){ 178 e.preventDefault(); 179 $(this).blur(); 180 $('html,body').animate({scrollTop:0},600); 181 182 }); 183 //load only if we are in the right page 184 //if (!$("body.page-home").length) return true; 185 186 // join mailing list 187 $("a.nav-link.page-join").click(function(e){ 188 e.preventDefault(); 189 190 var $menudiv = $(this).closest("div.w-row"); 191 if ($("#div_ghost_join").length) { 192 $("#div_ghost_join").remove(); 193 } else { 194 $menudiv.after('<div id="div_ghost_join" style="">ciao</div>'); 195 //$menudiv. 196 } 197 }); 198 199 200}); 201 202jQuery( document ).ready(function($){ 203 //sticky top menu 204 $('.row-nav-bar').waypoint(function(direction) { 205 if (direction=='down') { 206 $(this).css('visibility','hidden'); 207 208 $("body").append('<div class="section section-fixed-menu">' + 209 '<div class="img">' + 210 '<a href="/" class="back-to-top"><img src="/images/AmyKohnPlexiFont-120px.png" alt="Amy Kohn - Home Page"></a>' + 211 '<button class="nav-button" type="button">' + 212 '<span class="sr-only">Toggle navigation</span>' + 213 '<span class="icon-bar"></span>' + 214 '<span class="icon-bar"></span>' + 215 '<span class="icon-bar"></span>' + 216 '</button>' + 217 '</div>' + 218 '<div class="menu">' + $(".nav-bar").html() + '</div>' + 219 '</div>' 220 ); 221 $(".section-fixed-menu").fadeIn(); 222 223 224 225 //$('.back-to-top').animate({'opacity':'1'},500); 226 } else { 227 $(".section-fixed-menu").remove(); 228 $(this).css('visibility','visible'); 229 //$('.back-to-top').hide(); 230 } 231 }, 232 { 233 offset: function() { 234 return -$(this).height(); 235 } 236 }); 237 238 //affix 239 $(".section.anchor").waypoint(function(direction) { 240 if (direction=='down') { 241 //alert(direction + $(this).attr("id"));
242 $(".section-fixed-menu a.nav-link."+$(this).attr("id")).addClass("active"); 243 } else { 244 $(".section-fixed-menu a.nav-link."+$(this).attr("id")).removeClass("active"); 245 } 246 }, 247 { 248 //offset: '100%' 249 //offset: function() {return -$(this).height();} 250 }); 251 252 253 254 //load only if we are in the right page 255 if (!$("body.page-albums").length) return true; 256 257 // switch album description 258 $("a.snippet").click(function(e){ 259 $(this).blur(); 260 e.preventDefault(); 261 if (!$(this).hasClass("active")) { 262 $("a.snippet.active").removeClass('active'); 263 $(this).addClass('active'); 264 var i = $("a.snippet").index(this); 265 $(".section.album-description").hide(); 266 $(".section.album-description").eq(i).fadeIn('slow'); 267 } 268 }); 269}); 270 271jQuery( document ).ready(function($){ 272 //blinking function 273 var blink = new Interval(function() { 274 $(".jp_container a.track.active span.glyphicon").toggleClass("glyphicon-volume-down glyphicon-volume-up"); 275 }, 276 500 //ms 277 ); 278 var my_jPlayer = $("#jquery_jplayer"); 279 my_jPlayer.jPlayer({ 280 swfPath: "/js", 281 cssSelectorAncestor: ".jp_container", 282 supplied: "mp3", 283 wmode: "window" 284 }); 285 $(".jp_container .track").click(function(e) { 286 e.preventDefault(); 287 $(this).blur(); 288 blink.stop(); 289 $(".jp_container .track.active span.glyphicon-volume-up").removeClass("glyphicon-volume-up").addClass("glyphicon-volume-down"); 290 my_jPlayer.jPlayer("stop"); 291 var onlystop = $(this).hasClass("active"); 292 $(".jp_container .track.active").removeClass("active"); 293 if (!onlystop) { 294 my_jPlayer.jPlayer("setMedia", { 295 mp3: $(this).attr("href") 296 }); 297 my_jPlayer.jPlayer("play"); 298 $(this).addClass("active"); 299 blink.start(); 300 } 301 302 }); 303}); 304 305jQuery( document ).ready(function($){ 306 //load only if we are in the right page 307 //if (!$("body.page-photos").length) return true; 308 309 // 310 window.slide_icons = function(slide_index) { 311 //alert(slide_index); 312 var howmany = 6; 313 var start = 0; 314 315 //$("img.gallery.icon").removeClass("active"); 316 var active = $("img.gallery.icon").eq(slide_index).addClass("active"); 317 $("img.gallery.icon").not(active).removeClass('active'); 318 319 if ($("div.icon").eq(slide_index).is(':hidden')) { 320 if ($("div.icon").eq(slide_index).next().length && $("div.icon").eq(slide_index).next().is(':visible') ) { 321 start = slide_index; 322 } else { 323 start = Math.max(slide_index - howmany + 1 , 0); 324 } 325 $("div.icon").hide(); 326 $("div.icon").slice( start, start + howmany ).show(); 327 } 328 } 329 330 /* 331 $('.slicks').slick({ 332 fade: true, 333 onAfterChange: function(slider,index){ 334 slide_icons(index); 335 } 336 }); 337 */ 338 $("#photos a.icon").on("click",function(e){ 339 e.preventDefault(); 340 var slide_index = $(this).attr("photonumber"); 341 $(".w-slider-nav .w-slider-dot").eq(slide_index).click(); 342 //slide_icons(slide_index); 343 344 345 /* 346 var Webflow = Webflow || []; 347 Webflow.push(function () { 348 Webflow.require('slider').redraw(); 349 }); 350 */ 351 352 //$('.slicks').slickGoTo(parseInt(slide_index)); 353 }); 354});
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.