Changeset 4482 for extensions/Juza/js


Ignore:
Timestamp:
Dec 13, 2009, 9:29:39 PM (14 years ago)
Author:
vdigital
Message:

[Update] For Juza - Minor changes for plg

Pendings:

  • Configuration (On going, just first steps have been done)
  • Exception management
  • Menubar
File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/Juza/js/juzascript.js

    r4474 r4482  
    66    $(this).addClass('bigImg').attr('src', $(this).attr('src').replace('thumbnail/TN-', ''));
    77  });
     8        $('.thumbnailCategories li').addClass('Juza-cat');
     9        $('.description li').removeClass('Juza-cat');
     10  $nav = $('#content .navigationBar').html();
     11        if ($nav == null) $nav = '';
     12        $('#content .navigationBar').hide();
     13        $('div.titrePage h2').after('<div id="Juza-Thumbs"></div>'+$nav);
     14  $reltag = $('#menubar #mbTags').html();
     15        if ($reltag == null) $reltag = '';
     16        $reltag = '<div id="relTag">' + $reltag + '</div>';
     17        $('#copyright').before('<div id="jquery_local_img">' + $reltag + '</div>');
     18  $('span.wrap2 a img').click(function() {
     19    $scr = $(this).attr('src').replace('thumbnail/TN-', '');
     20    $href = $(this).parent('a').attr('href');
     21    $alt = $(this).attr('alt');
     22    $(this).parent('h3 a').attr('href', '#Juza-Thumbs');
     23    $temp = $href.substr($href.indexOf('/')+1);
     24    $temp = $temp.substr(0,$temp.indexOf('/'));
     25    $title = $('#ix-desc .Thumb-'+$temp).attr('title');
     26    $('#jquery_local_img').fadeOut("slow").replaceWith('<div id="jquery_local_img"><img usemap="#picturetop" title="'+$title+'" alt="'+$alt+'" src="'+$scr+'"/><map name="picturetop"><area href="#" coords="0,0,1024,300" shape="rect" title="Index"/><area href="'+$href+'" coords="0,301,1024,600" shape="rect" title="'+$title+'"/></map><br/>'+ $title +' - <a href="#Juza-Thumbs"><em>Index</em></a>' + $reltag + '</div>').fadeIn("slow");
     27          $(this).hover(function() { },function() {
     28            $(this).parent('h3 a').eq(0).attr('href', $href);
     29          });
     30});
     31
     32        if ($reltag == '') $('#jquery_local_img').hide();
    833  $('.thumbnailCategory .description h3 a').each(function() {
    934    $cat_url = $(this).attr('href');
    1035    $cat_tree = $('#menubar #mbCategories dd ul li a[href="'+$cat_url+'"]').next('.menuInfoCatByChild').next().html();
    1136    if ($cat_tree == null) $cat_tree = '';
    12     $(this).parent('h3').next('.text').after('<ul>'+$cat_tree+'</ul>');
     37    $(this).parent('h3').eq(0).next('.text').after('<ul>'+$cat_tree+'</ul>');
    1338  });
    14         $('.thumbnailCategories li').addClass('Juza-cat');
    15         $('.description li').removeClass('Juza-cat');
    16   $reltag = $('#menubar #mbTags').html();
    17         if ($reltag == null) $reltag = '';
    18         $reltag = '<div id="relTag">' + $reltag + '</div>';
    19         $('#copyright').before('<div id="jquery_local_img">' + $reltag + '</div>');
    20   $reltag = $('#content .navigationBar').html();
    21         if ($reltag == null) $reltag = '';
    22         $('#content .navigationBar').css('display','none');
    23         $('div.titrePage h2').after('<div id="Juza-Thumbs"></div>'+$reltag);
    24   $('span.wrap2 a img').click(function() {
    25     $scr = $(this).attr('src').replace('thumbnail/TN-', '');
    26     $href = $(this).parent('a').attr('href');
    27     $alt = $(this).attr('alt');
    28     $(this).parent('a').attr('href', '#Juza-Thumbs');
    29     $temp = $href.substr($href.indexOf('/')+1);
    30     $temp = $temp.substr(0,$temp.indexOf('/'));
    31     $title = $('#ix-desc .Thumb-'+$temp).attr('title');
    32     $('#jquery_local_img').fadeOut("slow").replaceWith('<div id="jquery_local_img"><img usemap="#picturetop" title="'+$title+'" alt="'+$alt+'" src="'+$scr+'"/><map name="picturetop"><area href="#" coords="0,0,1024,300" shape="rect" title="Index"/><area href="'+$href+'" coords="0,301,1024,600" shape="rect" title="'+$title+'"/></map><br/>'+ $title +' - <a href="#Juza-Thumbs"><em>Index</em></a>' + $reltag + '</div>').fadeIn("slow");
    33   });
    34   $('span.wrap2 a img').hover(function() { },function() {
    35     $(this).parent('a').attr('href', $href);
    36   });
    37         if ($reltag == '') $('#jquery_local_img').hide();
    3839});
Note: See TracChangeset for help on using the changeset viewer.