Results 1 to 3 of 3

Thread: curious behaviour (issues with non-IE browsers) [site link and partial code included]

  1. #1
    Join Date
    Sep 2008
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question curious behaviour (issues with non-IE browsers) [site link and partial code included]

    Greetings folks, I'm working on a site redesign for an Online Radio Station, and have run into a bug i cannot explain nor find a fix for (as of yet). been searching for the last 3 days.

    If you visit the above link, and click 'library' you will see a list of artists in a box on the left, a box to the right of that where it will display that bands albums, and a spot below where it will display songs / request information.

    The Problem:
    Works fine in IE, All other tested browsers require multiple clicks(2) to navigate the artist, album and song listings.

    the page uses a mix of php, javascript, ajax, and the jQuery library to make things work.

    The library page gets loaded when you hit the library key (as intended, first click). The artist box is auto-populated via mysql database.
    each item is part of a <ul><li onclick="jquery code here"></li><ul>

    ------
    Live Site
    (removed)
    ------

    the onclick code, using the artist list to album list
    Code:
    <li artistid="<?php echo urlencode($artist);?>" onClick="javascript:$(this).click(function() {
    var artistid = $(this).attr('artistid');
    artistclick(fixedUrl);
    });">(artist name goes here)</li>
    the artistclick function (this is in the main index.php, as is almost all the javascript code)
    Code:
    function artistclick(artistid) {
    	var buster = new Date();
        var b2 = buster.getTime();
    	var fixedUrl = "albumlist.php?artistid=" + artistid + "&buster=" + b2;
    //	fetch(fixedUrl, "albums"); <-- old code, errors in all browsers except IE
    	$("#albums").load(fixedUrl); <-- new code, works in all browsers. jQuery
      }
    now mind you, even though $("#albums").load(fixedUrl); works, you have to click an artist name TWICE to have it actually load the album list to the next window. It works flawless in IE.. However the two-clicks-required bug has shown itself in FF (old and new versions) and Chrome (havn't tested other browsers yet, but i'm waiting from feedback from my testers who use different browsers)

    if you need more code to look into, i'll be happy to post some, however i'd like to keep posted code to a minimum as this site is not yet open for public use.

    at this point, i'm at a loss, i've checked over the code thoroughly, i've also tried swapping the list tag for <a> tags, <p> tags, and even different <h> tags.

    Firefox's Error Console reports no errors, and i see no problems in the code while looking over it with FireBug plugin..

    any idea's would be most appreciated.

    Thanks in Advance,

    Oser~
    ---------------------------

    after 4 days of banging my head, a solution finally came to me. this thread is no longer valid.. (turns out IE was the one that was bugged and wasn't handling the triggers properly, where the rest were performing normal behaviour given the code being used.
    Last edited by Oseriduun; 09-05-2008 at 11:48 AM. Reason: solved

  2. #2
    Join Date
    Jun 2008
    Posts
    589
    Thanks
    13
    Thanked 54 Times in 54 Posts
    Blog Entries
    1

    Default

    Well, there is one little hint that I have for you:

    JUST TO MAKE THINGS REALLY EASY, SIMPLY TELL YOUR SITE USERS TO CLICK ON WHAT YOU WANT THEM TO TWICE, OR ONCE.

    -magicyte

  3. #3
    Join Date
    Feb 2008
    Location
    Cebu City Philippines
    Posts
    1,160
    Thanks
    17
    Thanked 277 Times in 275 Posts

    Default

    magicyte, you should have observed the edition reason of the OP (Resolved).

    It was marked as resolved as he said, unluckily we were not lucky enough to be able to know the information.
    Learn how to code at 02geek

    The more you learn, the more you'll realize there's much more to learn
    Ray.ph!

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •