Member
Member
vincent3569   2010-09-28, 22:26
#1

hello

in the printNewsPageListWithNav function, the current item is not easily identifiable for the css

so, after each installation of a new version of zenphot, I do a hack in zenpage-template-functions.php to add a on the current item

so could you implemente this feature in a next realase ?

line 1507-1508 of zenpage-template-functions.php
replace
`if($i == $current) {

echo "".$i."\n";

`

with
`if($i == $current) {

echo "".$i."\n";

`

Member
Member
sbillard   2010-09-29, 01:03
#2

Why would you add a ... around the element? The

[*]...
provides exactly the same wrapping and applies the class to the whole element.

Member
Member
vincent3569   2010-10-14, 22:50
#3

Hello

in fact, I tried to have the same CSS rules between printPageListWithNav() and printNewsPageListWithNav().
but these two functions behave differently on the current element.

with printPageListWithNav(), the current element is a navigable link, wheras with printNewsPageListWithNav(), the current element is not.

after spending several hours to solve this CSS problem, add the span tag is the only way I found.

if you have another solution, I know it well ;-)

Otherwise, if you can change the core, it would be nice because it keeps me from making a hack with each new version, especially since I want to publish my theme.

Administrator
Administrator
acrylian   2010-10-15, 08:22
#4

You probably should improve your CSS knowledge...

You can address the current element of the Zenpage pagelist with .class-of-your-page list li.current { }. Really not that hard and not that much extra. Of course if you have some global setting for uls you might have to add an !important to the call.

Generally it does not make sense to link to the page itself you are currently on.

Member
Member
vincent3569   2010-10-15, 13:10
#5

Quote:You probably should improve your CSS knowledge...
You're absolutely right, I'm not expert in php and css and it's always very complicated to understand and modify the code php and css and I lose a lot of time on it

Quote:Generally it does not make sense to link to the page itself you are currently on.
you're right, but if you have a look, printPageListWithNav() generates the following html code for the current element:
1

Finally, it should perhaps not modify printNewsPageListWithNav() but you need to simplify printPageListWithNav()

what do you think about ?

Administrator
Administrator
acrylian   2010-10-15, 13:44
#6

Well, yes, the Zenphoto pagelist function is quite a little older than the Zenpage equivalent. We will think about that. Anyway, it should be easily solved now you know hte css...;-)

Btw, regarding the "loosing time" on these stuff. That is normal and does not dissapear even when you know what you are doing. Especially the different browser behaviour fun...

Member
Member
vincent3569   2010-10-19, 21:27
#7

after looking at the CSS rules to write, after asking for help on forums specializing in css, I gave up: I created two specific rules for two different pagination.

but be sure that the simple addition of the tag on the current element of printNewsPageListWithNav() would provide a more compact code css with one rule for both pagination.

Administrator
Administrator
acrylian   2010-10-20, 08:50
#8

You do know tht you can declare css class option for more than one at the time by doing something like .class1, .class2 { ... }?

As said we will think about that but currently have a few more important things to do.

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.