#2629 XHTML - family_fav.php

closed-fixed
Brian Holland
None
5
2009-10-19
2009-07-03
KosherJava
No

On the individual page for some themes, the family_fav.php overrides the CSS for some themes. This produces invalid CSS. I would recommend that different css classes be used instead. The code is:

<?php if ($theme_name=="Xenea" || $theme_name=="Standard" || $theme_name=="Wood" || $theme_name=="Ocean") { ?>
<style type="text/css" rel="stylesheet">
a:hover .name2 { color: #222222; }
</style>
<?php } ?>

Discussion

1 2 > >> (Page 1 of 2)
  • Greg Roach
    Greg Roach
    2009-07-05

    Having style-specific logic in the main code is horrid.

     
  • Gerry Kroll
    Gerry Kroll
    2009-07-06

    I've assigned this to windmillway. "family_nav.php" is his code.

     
  • Gerry Kroll
    Gerry Kroll
    2009-07-06

    • assigned_to: nobody --> windmillway
     
  • Brian Holland
    Brian Holland
    2009-07-06

    Then I had better fix it

     
  • kiwi_pgv
    kiwi_pgv
    2009-07-06

    Interesting. I totally agree with Greg, but an almost identical issue was raised in the Help forum (or was it Open Discussion?) about the 'name2' class. General consensus there seemed to be that 'we' don't want to add a whole load of extra classes to an already bloated style sheet!

     
  • Brian Holland
    Brian Holland
    2009-07-07

    Fixed in svn 5851

     
  • Brian Holland
    Brian Holland
    2009-07-07

    • status: open --> pending-fixed
     
  • KosherJava
    KosherJava
    2009-07-07

    Brian,
    Thanks for the fix. I checked in a minor fix to add a missing </td>. As happens many times fixing one issue exposes others. The page still has errors. I believe that the cause is the </div> in lines 517, 519 etc that are closed before the table that is closed much farther down on the page. Is this something that you can look into?
    Thanks

     
  • KosherJava
    KosherJava
    2009-07-07

    • status: pending-fixed --> open-fixed
     
  • Brian Holland
    Brian Holland
    2009-07-07

    Kosher,
    No problem, I will get back to you
    Brian

     
  • Brian Holland
    Brian Holland
    2009-07-07

    Kosher,
    Thanks for picking up the missing </td> and the end of line spaces.
    OK, the </div>s are moved/changed in svn 5856.
    Could you check and verify the validation again please.
    Brian

     
  • KosherJava
    KosherJava
    2009-07-07

    Looks MUCH better. It is still complaining as below. and that matches up to what I see in teh generated html. An <a> can't contain a block level element such as a table or div. The generated code is roughly in the format of:

    <div id="menu822049622844" class="">
    <a href="javascript:;" onmouseover="..." onmouseout="...">
    <div class="flyout">
    <table class="person_box flyout" >
    <tr>
    <td class="nowrap ltr" >
    <b>Parents</b>
    <br />
    <a href="individual.php...">...</a>
    <br /><a href="individual.php?...>...</a>
    <br />
    </td>
    </tr>
    </table>

    You can test your changes by simply running a publicly accessible URL through http://validator.w3.org/ . There is also a good Firefox plugin for this
    ----------------------From the Validator --------------------------

    Line 890, Column 257: document type does not allow element "div" here; missing one of "object", "applet", "map", "iframe", "button", "ins", "del" start-tag

    …5787699', ''); "><div class="flyout"><table class="person_box flyout" ><tr><t

    The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element.

    One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").

     
  • Brian Holland
    Brian Holland
    2009-07-07

    Kosher,
    This looks as if it will be more difficult to find, as the first
    <a href="javascript:;" onmouseover="..." onmouseout="...">
    I think, is not in the family_nav.php page.
    Can you tell me EXACTLY where you are (URL PAGE) when running this validation please.
    Brian

     
  • Brian Holland
    Brian Holland
    2009-07-07

    Kosher,
    Using FF 3.0.11 I have used the tools to validate my HTML.
    This was the result:

    Congratulations
    The document located at <http://www.windmillway.f2s.com/genealogy_4.1/individual.php?pid=I7&ged=hollands.ged> was successfully checked as XHTML 1.0 Transitional. This means that the resource in question identified itself as "XHTML 1.0 Transitional" and that we successfully performed a formal validation using an SGML, HTML5 and/or XML Parser(s) (depending on the markup language used).

    So now I am a bit confused

    Brian

     
  • KosherJava
    KosherJava
    2009-07-07

    I just emailed you a URL via sourceforge.

     
  • Brian Holland
    Brian Holland
    2009-07-08

    Kosher,
    I have tried to be a bit creative and have managed to remove all <div> and <table> block level elements within the submenu anchor.
    It's meant a few css changes, as well as to family_nav.php, but that's fine.
    Let me know if it improves things for your validation.
    svn 5870
    (Still wondering why my site passed and yours did not .. anyway, no matter)
    Brian

     
  • KosherJava
    KosherJava
    2009-07-09

    Brian,
    No joy. The issue seems to be teh nested <a><a> tags. Can teh outer one be a div instead of an <a>? . I get the validation errors on your page from the local validator but not the w3 one. If you validate you page on the w3 validator, and select the option to show the source, you will see that it is not correctly seeing all the source. do a search for Parents (a word in the family nav) and you will see that it is not present in the source.

     
  • Brian Holland
    Brian Holland
    2009-07-09

    Kosher,
    Thanks for the feedback.
    I am out this morning, but will try later on this afternoon to see what I can do.
    Brian

     
  • Brian Holland
    Brian Holland
    2009-07-10

    Kosher,

    I understand what you are saying about nested <a> tags.
    My problem is that the outer <a> I think is part of the "Menu" process calling the submenu.
    In the submenu I have defined <a> links.
    I need help with this as I do not want to really start changing the Menu structure.
    Maybe there is a better way of changing my nested <a> links into something else that will react like a hotspot.
    Has anyone else any ideas please?
    Veit perhaps, as I know he has done work in the menu area with the PGV_MENUS_AS_LISTS on family_nav.php.

    Sorry but I really need help here.
    I'll send Veit an offline note if he misses this.

    I will post some improvements anyway which change & into &amp; that I spotted in family_nav.php

    Brian

     
  • Veit
    Veit
    2009-07-10

    Checked the problem and found that it is nothing special for lists navigation. it is resulting from an improper use of the navigation class. I have done a hack with svn 5882 that allows successful validation. Also the headlines of the flyouts are no longer links. But they had only a functionless javascript link in the past, so this should be no problem. I have done no cross browser test, so give me feedback if there is something that do not work anymore.

     
  • KosherJava
    KosherJava
    2009-07-10

    This looks good now. I will continue testing with other browsers.
    Thanks

     
  • KosherJava
    KosherJava
    2009-07-10

    • status: open-fixed --> pending-fixed
     
  • Brian Holland
    Brian Holland
    2009-07-10

    Veit,

    That was rather a neat change you did. Many thanks.
    Perhaps you can explain one day (when youare not going on vacation etc) what you meant by << it is resulting from an improper use of the navigation class >>

    Brian

     
  • This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 100 days (the time period specified by
    the administrator of this Tracker).

     
1 2 > >> (Page 1 of 2)