WordPress.org

Ready to get started?Download WordPress

Forums

JavaScript Ignored (8 posts)

  1. Eternal Sky Chaz
    Member
    Posted 8 years ago #

    I am trying to integrate my site for better SEO.

    The long story short id that i've found a theme where I can easily place a navbar in the header.

    So far so good ...

    But one of the buttons in my navbar has to contain a PopUp Menu and it won't render. It displays the "Up" image and OnMouseover it displays the rollover image, but it seems to ignore the JavaScript that Dreamweaver creates and places in the actual <head> section.

    Anyone got any clues as to why this happens? Does WP actually ignore JS ?

  2. pizdin_dim
    Member
    Posted 8 years ago #

    No, WP doesn't ignore JS but you have over 30 JS errors (in firefox 1.5) when your main page is rendered. I think you need to look at fixing that to begin with.

  3. Eternal Sky Chaz
    Member
    Posted 8 years ago #

    Can you send me a list? I'm not being facetious, but I just opened my page in Firefox 1.5 for Mac and got no errors at all. Everything worked perfectly.

    please send the list or screen print to:

    Chaz@eternalsky.us

    I used Dreamweaver to create the navbar, so I don't know how it could be creating errors.

    Additionally, the home page is not what gave me problems. That page is just a plain HTML page and not generated by WP. I encountered problems when attempting to add a navbar to the header of a WP theme.

    So when my blog page loads, it either loads in a new window (for my testing purposes) or would have replaced the home page in that window, thereby overwriting any previous code from the homepage.

  4. Samuel B
    moderator
    Posted 8 years ago #

  5. pizdin_dim
    Member
    Posted 8 years ago #

    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'font-weight'. Declaration dropped.http://www.eternalsk... (line 0)
    Unknown property 'fontSize'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'visibility'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)
    Error in parsing value for property 'cursor'. Declaration dropped.http://www.eternalsk... (line 0)

  6. Eternal Sky Chaz
    Member
    Posted 8 years ago #

    Thanks. I will get on this when I get home tonight.

    I do have to say, though, that it seems most of the errors reported by samboll's validator were created by someon else. for example this error:

    Error Line 58, column 20: document type does not allow element "li" here; missing one of "ul", "ol", "menu", "dir" start-tag .
    <li id="linkcat-2"><h2>Eternal Sky Links</h2>

    was not created by Dreamweaver or myself. That is created by the code:

    <?php get_links_list(); ?>

    that is the code that WP uses to generate and display the link Categories or Blogrolls. If that's in error, then WP needs to look into its own programming practises.

    One more thing ... I just loaded the homepage into Dreamweaver to see if I could quickly determine where those line 0 errors were coming from and there's no line 0, so I have no way to debug them.

  7. pizdin_dim
    Member
    Posted 8 years ago #

    "that is the code that WP uses to generate and display the link Categories or Blogrolls. If that's in error, then WP needs to look into its own programming practises"

    I don't think so. The problem is actually in your template's sidebar. You need to check with the author of the template.

    "I just loaded the homepage into Dreamweaver to see if I could quickly determine where those line 0 errors were coming from and there's no line 0, so I have no way to debug them."

    If I were you, I'd look at "mm_menu.js" for the problem, that's where the attributes mentioned in the error list are used.

    BTW: I think your javascript declaration is wrong for an XHTML document, it needs a type attribute:

    <script language="JavaScript" src="mm_menu.js"></script>

  8. RichHosek
    Member
    Posted 8 years ago #

    I recently discovered the solution to this problem. I had a script that worked great in all browsers, no errors. Then, when I was upgrading it suddenly in Firefox I was getting the "Error in parsing value for property 'xxx'. Declaration dropped.url... (line 0)"

    I compared the two side by side and discovered the <!DOCTYPE> declaration was the culprit. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    worked fine, but when I tried to upgrade to XHTML and use <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    the problem popped up.

    Like the poster, I was using very simple, standard code and the problem showed up with various types of CSS properties. In my case, is was reassigning the top and left properties for a <span> style to move a graphic around the screen with the mouse.

    ...
    .cursorstyle {
    position: absolute;
    visibility: visible;
    z-index: 2;
    left: 0px;
    top: 0px;
    }
    </head>
    <body>
    <span id="cursorDiv" class="cursorstyle">
    <img src="images/something.gif" id="cursor" class="cursorstyle" alt="">
    </span>
    <script language="JavaScript" type="text/javascript">
    spanObj = document.getElementById("cursorDiv");
    spanObj.top = 100;
    spanObj.left = 100;
    </script>
    ...

    The spanObj.top = 100; and spanObj.left = 100; lines were giving me a problem with XHTML, but not HTML. Anyone have any idea why? Seems like pretty standard stuff to me, is it somehow violating the DOM or some other aspect of CSS?

Topic Closed

This topic has been closed to new replies.

About this Topic