Plugin Directory

Changeset 1327269


Ignore:
Timestamp:
01/13/2016 08:15:02 AM (10 years ago)
Author:
michouse
Message:

Update wp-extend-toolbar.js

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wp-extend-toolbar/trunk/js/wp-extend-toolbar.js

    r1196979 r1327269  
    11jQuery(document).ready(function(jQuery){
     2   
    23    var title = jQuery("title").text();
    34    var description = jQuery("meta[name=description]").attr("content");
    45   
    5     console.log('Description : ' + description );
    6    
    76    jQuery("#wp-admin-bar-extend-toolbar-title .ab-item").text("PAGE TITLE:" + title);
    87    jQuery("#wp-admin-bar-extend-toolbar-description .ab-item").text("DESCRIPTION:" + description);
     8   
     9    var total_height = 32;
     10    total_height += jQuery('#wp-admin-bar-extend-toolbar-title').height();
     11    total_height += jQuery('#wp-admin-bar-extend-toolbar-description').height();
     12   
     13    jQuery('html').css({
     14        'margin-top': total_height + 'px'
     15    });
     16    jQuery('* html body').css({
     17        'margin-top': total_height + 'px'
     18    });
     19    jQuery('#wpadminbar').css({
     20        'height': total_height + 'px'
     21    });
     22    jQuery('body.admin-bar .navbar-fixed-top').css({
     23        'cssText': 'top:' + total_height + 'px !important'
     24    });
    925});
Note: See TracChangeset for help on using the changeset viewer.