Treehouse: Grow your CSS skills. Land your dream job.

Strange error within all versions of IE

  • # January 14, 2010 at 4:42 pm

    Hello, I’m running into an interesting issue and of course it only seems to be evident in all versions of IE. I can’t determine if it’s a PHP issue or JS, so I figured I would start here. Forgive me in advance if this is posted in the wrong forum.
    If you look at the following two pages within IE, you will notice that link #1, has an image with a description that appears in the lower left when you mouse over it. That one works just fine in IE. Link #2, as you will see does not have a description tied to it, and as a result, IE is throwing the following error. ‘this[…].style’ is null or not an object. I can’t figure out what is causing this.
    #1 … php?id=216
    #2 … php?id=446

    Here is the code block that displays the description in the lower left of the picture. Pretty straight forward, I have a column in my table called description and if it’s not null, then I display the description block and if it is null, I simply want to display nothing, i.e. a paragraph with a space in it.

    < ? if ($row_Recordset1['description'] !=null) { echo "
    Show description
    echo $row_Recordset1[‘description’];
    echo “

    } else if ($row_Recordset1[‘description’] == null) {
    echo “



    Additional Information
    You will notice that I am using the jQuery accordion function, so I think it should be pretty cut and dry, but obviously, I’ve done something wrong.

    Thanks for your time and I hope someone can help me out.

    Take care!

    # January 15, 2010 at 4:50 am

    hm could be:

    echo “$row_Recordset1[‘description’]”;

    you don’t have quotations on that line, either that it is a problem with the accordion definition list, i’m guessign you are using a javascript library such as jQuery ?
    Have you tested your plain html without php ?

    Start there and validate it to eliminate any markup errors

    # January 15, 2010 at 9:36 am

    Hi Mat, thanks for the suggestion, when I add quotes to that block of code

    echo “$row_Recordset1[‘description’]”;

    , the page no longer works, … php?id=446. So I don’t think that particular line needs quotes.

    Also, I have tested with only using HTML and I get the same results, … php?id=446.



    Lastly, yes I am using jQuery and it’s accordion function.

    Thanks again.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.