$(document).ready(function(){
   $("#small_gallery_wrapper").addClass('script');
   $("#small_gallery").addClass('script');
   $("a.img").addClass('script');
   $(".author_date .desc").text(" • ");
   $(".tags .sep").text(" • ");
   $('input').textPlaceholder();
   Hyphenator.run();


   /* Galeria */
   $("#small_gallery div").each(
      function(index){
         $(this).css('left',(index*700).toString()+'px');
      }
   );
   $('.small_gallery_backward').hide();
   /*$('.small_gallery_backward').hover(function() {
      $(this).css('background','url("img/backward.png")';
   });*/
   $('.small_gallery_forward').click(function() {
      $('.small_gallery_backward').show();
      if($("#small_gallery div").last().css('left') == '700px') {
         $('.small_gallery_forward').hide();
      }
      $("#small_gallery div").animate({'left':'-=700px'});
   });
   $('.small_gallery_backward').click(function() {
      $('.small_gallery_forward').show();
      if($("#small_gallery div").first().css('left') == '-700px') {
         $('.small_gallery_backward').hide();
      }
      $("#small_gallery div").animate({'left':'+=700px'});
   });
$('.fancybox').fancybox({
   'transitionIn' : 'elastic',
   'speedIn'      :  400, 
});

   $('textarea.resizable:not(.processed)').TextAreaResizer();
});

// For discussion and comments, see: http://remysharp.com/2009/01/07/html5-enabling-script/
(function(){if(!/*@cc_on!@*/0)return;var e = "fb,abbr,article,aside,audio,bb,canvas,datagrid,datalist,details,dialog,eventsource,figure,footer,header,hgroup,mark,menu,meter,nav,output,progress,section,time,video".split(',');for(var i=0;i<e.length;i++){document.createElement(e[i])}})()

