Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » New Versions, & Updating » Old Version fixes and change logs »

BUGFIX 361-04: Allow Custom Menu widget links to use same styling as Pages widget.


  #1  
Old Jan 22, 2011, 05:49 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
While not actually a BUG, I've created a bugfix for this enhancement to allow it to be tracked.

Wordpress version 3 introduced a new widget, the 'Custom Menu' widget. This widget used different classes than the 'Pages' widget, which can be styled in the Atahualpa options. The attached css.php has the new classes added to the styling so both will be styled the same.

Edit css.php and change the following lines from
HTML Code:
/* First, remove the left border and padding from the <LI>. The margin stays on the <LI>'s 
because if the <A>'s of the cateories widget were set to display:inline (default setting) 
then margin would work there */
div.widget_pages ul li, 
div.widget_categories ul li {
	border-left: 0 !important;
	padding: 0 !important;
}

/* Then, add left border and padding to the <A> */
div.widget_pages ul li a:link, 
div.widget_pages ul li a:visited, 
div.widget_pages ul li a:active,
div.widget_categories ul li a:link,
div.widget_categories ul li a:visited, 
div.widget_categories ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists']['link-border-left-color']; ?>;
	}

div.widget_pages ul li a:hover,
div.widget_categories ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists']['link-border-left-hover-color']; ?>; 
}

div.widget_pages ul li ul li a:link, 
div.widget_pages ul li ul li a:visited, 
div.widget_pages ul li ul li a:active,
div.widget_categories ul li ul li a:link,
div.widget_categories ul li ul li a:visited, 
div.widget_categories ul li ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists2']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists2']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists2']['link-border-left-color']; ?>;
	}

div.widget_pages ul li ul li a:hover,
div.widget_categories ul li ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists2']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists2']['link-border-left-hover-color']; ?>; 
}

div.widget_pages ul li ul li ul li a:link, 
div.widget_pages ul li ul li ul li a:visited, 
div.widget_pages ul li ul li ul li a:active,
div.widget_categories ul li ul li ul li a:link,
div.widget_categories ul li ul li ul li a:visited, 
div.widget_categories ul li ul li ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists3']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists3']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists3']['link-border-left-color']; ?>;
	}

div.widget_pages ul li ul li ul li a:hover,
div.widget_categories ul li ul li ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists3']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists3']['link-border-left-hover-color']; ?>; 
}

/* The pages widget gets "block" because it usually has only 
one link per <LI> and no text */
div.widget_pages ul li a:link,
div.widget_pages ul li a:active,
div.widget_pages ul li a:visited,
div.widget_pages ul li a:hover {
	display: block !important;
}
to
HTML Code:
/* First, remove the left border and padding from the <LI>. The margin stays on the <LI>'s 
because if the <A>'s of the cateories widget were set to display:inline (default setting) 
then margin would work there */
div.widget_pages ul li, 
div.widget_nav_menu ul li, 
div.widget_categories ul li {
	border-left: 0 !important;
	padding: 0 !important;
}

/* Then, add left border and padding to the <A> */
div.widget_nav_menu ul li a:link, 
div.widget_nav_menu ul li a:visited, 
div.widget_nav_menu ul li a:active,
div.widget_pages ul li a:link, 
div.widget_pages ul li a:visited, 
div.widget_pages ul li a:active,
div.widget_categories ul li a:link,
div.widget_categories ul li a:visited, 
div.widget_categories ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists']['link-border-left-color']; ?>;
	}

div.widget_nav_menu ul li a:hover,
div.widget_pages ul li a:hover,
div.widget_categories ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists']['link-border-left-hover-color']; ?>; 
}

div.widget_nav_menu ul li ul li a:link, 
div.widget_nav_menu ul li ul li a:visited, 
div.widget_nav_menu ul li ul li a:active,
div.widget_pages ul li ul li a:link, 
div.widget_pages ul li ul li a:visited, 
div.widget_pages ul li ul li a:active,
div.widget_categories ul li ul li a:link,
div.widget_categories ul li ul li a:visited, 
div.widget_categories ul li ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists2']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists2']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists2']['link-border-left-color']; ?>;
	}

div.widget_nav_menu ul li ul li a:hover,
div.widget_pages ul li ul li a:hover,
div.widget_categories ul li ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists2']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists2']['link-border-left-hover-color']; ?>; 
}

div.widget_nav_menu ul li ul li ul li a:link, 
div.widget_nav_menu ul li ul li ul li a:visited, 
div.widget_nav_menu ul li ul li ul li a:active,
div.widget_pages ul li ul li ul li a:link, 
div.widget_pages ul li ul li ul li a:visited, 
div.widget_pages ul li ul li ul li a:active,
div.widget_categories ul li ul li ul li a:link,
div.widget_categories ul li ul li ul li a:visited, 
div.widget_categories ul li ul li ul li a:active {
	padding: 0 0 0 <?php echo $bfa_ata['widget_lists3']['link-padding-left']; ?>px; 
	border-left: solid <?php echo $bfa_ata['widget_lists3']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists3']['link-border-left-color']; ?>;
	}

div.widget_nav_menu ul li ul li ul li a:hover,
div.widget_pages ul li ul li ul li a:hover,
div.widget_categories ul li ul li ul li a:hover {
	border-left: solid <?php echo $bfa_ata['widget_lists3']['link-border-left-width']; ?>px #<?php echo $bfa_ata['widget_lists3']['link-border-left-hover-color']; ?>; 
}

/* The pages widget gets "block" because it usually has only 
one link per <LI> and no text */
div.widget_nav_menu ul li a:link,
div.widget_nav_menu ul li a:active,
div.widget_nav_menu ul li a:visited,
div.widget_nav_menu ul li a:hover,
div.widget_pages ul li a:link,
div.widget_pages ul li a:active,
div.widget_pages ul li a:visited,
div.widget_pages ul li a:hover {
	display: block !important;
}
or you can use the attached file which has the changes already applied. Download the file, unzip it and upload it to your Atahualpa 3.6.1 theme folder.

NOTE: this css.php contains the changes in: BUGFIX 361-03: Allow Tag widget links to use Atahualpa widget link styling.

css.zip
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support

Last edited by juggledad; Jan 22, 2011 at 05:58 AM.
  #2  
Old Jan 22, 2011, 09:40 AM
damian
 
22 posts · Feb 2010
Wow. It worked. Nice job. Thanks!

Bookmarks



Similar Threads
Thread Thread Starter Forum Replies Last Post
BUGFIX 361-03: Allow Tag widget links to use Atahualpa widget link styling. juggledad Old Version fixes and change logs 3 Jan 14, 2011 04:56 PM
BUGFIX 361-01: meta tags not appearing in generated source juggledad Old Version fixes and change logs 5 Jan 13, 2011 04:57 AM
Styling Custom Widget Area bigwavedesign Sidebars & Widgets 5 Nov 12, 2010 04:47 PM
BUGFIX 351/352-06: BFA Subscribe widget does use link colors in widget options juggledad Old Version fixes and change logs 0 Jul 12, 2010 09:21 AM


All times are GMT -6. The time now is 12:40 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.