1. Milton Keynes, UK
    Joined
    28 Jul '04
    Moves
    80200
    08 Jun '11 11:06
    Originally posted by yashin
    [b]
    lausey was correct I think

    I found this in the code:

    document.write('<a class="loggedInInfo" href="/core/gameserve.php">' + nGamesWaiting + ' game' + (nGamesWaiting>1?'s':''😉 + ' waiting</a><a href="#" onclick="XPopGamesUrgent( event );return false;">

    I bet it used to be:

    document.write('<a class="loggedInInfo" href="/core/gameser ...[text shortened]... interested in these bug-hunting thingies.[/b][/b]
    For a non-programmer, it is very well deduced. You also noticed that it was done in the Javascript rather than the PHP (the PHP code will not be visible to the end user). I think your solution will work. Although this will be more efficient:

    document.write('<a class="loggedInInfo" href="/core/gameserve.php">' + nGamesWaiting + ' game' + (nGamesWaiting<>1?'s':''😉 + ' waiting</a><a href="#" onclick="XPopGamesUrgent( event );return false;">

    Although my Javascript is a little rusty. I am not sure if "not equals" is <> or !=.
  2. SubscriberRuss
    RHP Code Monkey
    RHP HQ
    Joined
    21 Feb '01
    Moves
    2417
    10 Jun '11 09:08
    What has amused me about this mistake is that someone sent feedback saying "are you EVER going to fix the 1 games waiting" error.

    So, I replied saying that after nearly a decade, I probably should, and it was a low risk modification that could be hot fixed, so approx. 3 minutes later the solution was live - but as you discovered, broken in another (and really stupid) way.

    If you hit ctrl+refresh in your browser to reload the javascript you will find the problem is fixed. (Or is it...? 😉 )
  3. Joined
    08 Apr '09
    Moves
    19512
    10 Jun '11 09:49
    Originally posted by Russ
    What has amused me about this mistake is that someone sent feedback saying "are you EVER going to fix the 1 games waiting" error.

    So, I replied saying that after nearly a decade, I probably should, and it was a low risk modification that could be hot fixed, so approx. 3 minutes later the solution was live - but as you discovered, broken in another (and real ...[text shortened]... your browser to reload the javascript you will find the problem is fixed. (Or is it...? 😉 )
    How much did it cost to buy the 's' back? ;-)
Back to Top

Cookies help us deliver our Services. By using our Services or clicking I agree, you agree to our use of cookies. Learn More.I Agree