Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

date() error

  • 25-09-2001 7:39pm
    #1
    Closed Accounts Posts: 15


    May want to look into this...getting this error at the top of every showthread page.
    Warning: unexpected error in date() in ./admin/functions.php on line 1486
    Post edited by Shield on


Comments

  • Registered Users, Registered Users 2 Posts: 5,049 ✭✭✭Cloud


    Any idea what it is?

    The line is:
    return date($format,$timestamp+($bbuserinfo-$timeoffset)*3600);

    in the vbdate function. Unchanged AFAIK.

    Thanks,

    John.
    --


  • Registered Users, Registered Users 2 Posts: 1,684 ✭✭✭Kraken


    Not sure, But maybe the date on your machine is wrong and wont except the date given off boards.ie
    Or it could be that i am just guessing??? No your going to have a few errors till they get their haed around vb but when they do you wont see to much of this id say.

    Cloud did you count down 1486 lines to find that????


  • Registered Users, Registered Users 2 Posts: 1,842 ✭✭✭phaxx


    Oh yes I'm sure he did, it's the way any half-decent geek does it. Using the "go to" function in practically every text editor is the sissy way of doing it.


  • Registered Users, Registered Users 2 Posts: 5,049 ✭✭✭Cloud


    I hate to dissappoint you weirdos but you're both wrong, my editor has line numbers in it :-)


  • Registered Users, Registered Users 2 Posts: 1,684 ✭✭✭Kraken


    Who you calling a weirdo?
    The cheek of ya..... :p


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 5,049 ✭✭✭Cloud


    Perhaps I should have said No Life wannabe!

    :D

    John.
    --
    /me points at Presto's post count


  • Closed Accounts Posts: 15 tubedogg


    I think I have determined the problem. For some reason unknown to me, certain individuals do not have a registration date. This is causing errors.

    Fix: Update the registration date for those who do not have one.
    UPDATE user SET joindate='788936401' WHERE (joindate='' OR joindate='0' OR joindate<0);

    Not sure if they don't have reg dates, or just have screwed up dates, but that should fix it. Probably. :D


  • Registered Users, Registered Users 2 Posts: 5,049 ✭✭✭Cloud


    The problem here tubedogg is that we had an original UBB which didn't have a registration date field - before the newer versions. So those who registered way back before UBB had a registration date field have that blank entry.

    Thanks for the tip.

    All the best,

    John.
    --


  • Registered Users, Registered Users 2 Posts: 7,626 ✭✭✭smoke.me.a.kipper


    Originally posted by Cloud
    Perhaps I should have said No Life wannabe!

    :D

    John.
    --
    /me points at Presto's post count

    you call that a 'post count'?? :rolleyes: :p.


    [ontopic]
    so where did all this 1970 business come from??


  • Closed Accounts Posts: 15 tubedogg


    January 1970 is the Unix Epoch. A Unix Timestamp (which is the time format vBulletin uses) of the Epoch is 0. Encountering a blank field, I assume it reverted to 0, hence January 1970.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,684 ✭✭✭Kraken


    Originally posted by Cloud
    Perhaps I should have said No Life wannabe!

    :D

    John.
    --
    /me points at Presto's post count

    Whats that supposed to mean? I dont spam if thats what you mean.The Cheek...........


  • Registered Users, Registered Users 2 Posts: 7,626 ✭✭✭smoke.me.a.kipper


    Originally posted by Presto
    I dont spam

    ha :D lol!

    why must you turn this into a board of LIES??


  • Registered Users, Registered Users 2 Posts: 1,684 ✭✭✭Kraken


    Na i dont spam really.


  • Registered Users, Registered Users 2 Posts: 21,264 ✭✭✭✭Hobbes


    Only happens if you pick a different timezone. I changed mine back to CST (Cloud Standard Time) and it works fine.


  • Registered Users, Registered Users 2 Posts: 654 ✭✭✭DS


    Ah sure me and the old "unexpected error in date()" are the best of friends. Invariably, it's happened to me when a minus value (or some other undisplayable timestamp) manages to sneak in as the second parameter. In this case it's very obviously a problem with the time offset in the user's profile, which is somehow screwing up the timestamp.


Advertisement