source: extensions/Juza/js/juzascript.js @ 4659

Last change on this file since 4659 was 4659, checked in by vdigital, 14 years ago

[Update] For Juza - Juza Theme is full working (On Standard Piwigo Gallery).

Recommended organization: Don't mixed Pictures and subcategories in a category.
Next step - Response time checking.
To see I will raise a locked gallery.

  • Property svn:eol-style set to LF
  • Property svn:keywords set to Author Date Id Revision
File size: 3.0 KB
Line 
1$().ready(function() {
2  $('div.illustration').each(function() {
3    $(this).addClass('maxIllustration');
4  });
5  $('div.illustration a img').each(function() {
6    $src = $(this).addClass('bigImg').attr('src');
7                $medium = $('#ix-cat .Cat[src="'+$src+'"]').eq(0).attr('title');
8                $title = $('#ix-cat .Cat[src="'+$src+'"]').eq(0).attr('alt');
9                $(this).attr('src', $medium).attr('title', $title);
10  });
11        $('.thumbnailCategories li').addClass('Juza-cat');
12        $('.description li').removeClass('Juza-cat');
13        $('.thumbnailCategory div.description').addClass('Juza-desc');
14        $('td.JS_active').show();
15  $nav = $('#content .navigationBar').html();
16        if ($nav == null) $nav = '';
17        $('#content .navigationBar').hide(); 
18        $('div.titrePage h2').after('<div id="Juza-Thumbs"></div>'+$nav); 
19  $reltag = $('#menubar #mbTags').html();
20        if ($reltag == null) $reltag = '';
21        $reltag = '<div id="relTag">' + $reltag + '</div>';
22        $('#copyright').before('<div id="jquery_local_img">' + $reltag + '</div>');
23  $('span.wrap2 a img').click(function() {
24    $href = $(this).parent('a').attr('href');
25    $alt = $(this).attr('alt');
26    $(this).parent('h3 a').attr('href', '#Juza-Thumbs');
27    $temp = $href.substr($href.indexOf('/')+1);
28    $temp = $temp.substr(0,$temp.indexOf('/'));
29    $title = $('#ix-desc .Thumb-'+$temp).attr('title');
30    $src = $('#ix-desc .Medium-'+$temp).attr('title');
31    $('#jquery_local_img').fadeOut("slow").replaceWith('<div id="jquery_local_img"><img usemap="#picturetop" title="'+$title+'" alt="'+$alt+'" src="'+$src+'"/><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");
32          $(this).hover(function() { },function() {
33            $(this).parent('h3 a').eq(0).attr('href', $href);
34          });
35});
36
37        if ($reltag == '') $('#jquery_local_img').hide();
38  $('.thumbnailCategory .description h3 a').each(function() {
39    $cat_url = $(this).attr('href');
40    $cat_tree = $('#menu-cat ul li a[href="'+$cat_url+'"]').next('.menuInfoCatByChild').next().html();
41    if ($cat_tree == null) $cat_tree = '';
42    $(this).parent('h3').eq(0).next('.text').after('<ul>'+$cat_tree+'</ul>');
43  }); 
44        $('a.Juza_menu').click(function() {
45          $('#menubar').toggleClass('displayed');
46        });
47
48  var $c = $('#Juza_call').html();
49  $('#menubar a[href*="admin.php"]').parent('li').eq(0).after('<li>'+$c+'</li>');
50  $('#menubar form#Juza_action input.Juza_conf').hide();
51  $('#menubar form#Juza_action').hide();
52  $('#menubar a.Juza_conf').show();
53
54  $('a.Juza_conf').click(function(){
55                $('#menubar').toggleClass('displayed');
56                $('#JuzaBox').fadeIn('fast'); 
57                if($('body').height() > $('body').offset().height){
58                                var sH = $('body').height();
59                        }else{
60                                var sH = $('body').offset().height;
61                } 
62                $('#JuzaShade').css( {height:sH+'px'}).css('z-index',9998).fadeIn('fast');
63
64                $('#JuzaCloseBox').click(function(){
65                        $('#JuzaBox').fadeOut('fast');
66                        $('#JuzaShade').fadeOut('fast').css('z-index',-9998);
67                });
68        });
69});
Note: See TracBrowser for help on using the repository browser.