Solved

PHPBB forum gives 01-01-1970 as startdate, and certain values are counted from that date too

Posted on 2004-09-15
17
3,282 Views
Last Modified: 2013-12-12
Hi all

As the question indicates i have troubles with the startdate, i have already gone to the mysql database and pasted in the unix code for 3 september 2004, but it still wont display it, and the values of posts per day are for instance now 0,001 while i have 1867 posts in 12 days already, anyone know a workaround? I have been to the phpbb forum, that is where i got the solution to paste in the unix formatter code but that did also not help. This is my last resort, if no one can help me out here i will have to get used to that, my registration date is also unchangeable and displays 01-01-1970 too :(

Fdehell
0
Comment
Question by:fdehell
  • 6
  • 6
  • 5
17 Comments
 
LVL 9

Accepted Solution

by:
_GeG_ earned 250 total points
ID: 12067684
I don't know phpbb, but 01-01-70 is the beginning of timestamp. So your startdate is probably of type timestamp and is set to 0. Try to set it to 20040903 in the mysql database.
0
 
LVL 9

Expert Comment

by:AlanJDM
ID: 12067929
Is any data at all showing? It sounds like all of the php vars aren't recieving any values from the database.


Alan
0
 
LVL 1

Author Comment

by:fdehell
ID: 12068623
Yes like i said i have tried to set it and change it but it does not matter, and yes valiues are shown but derived from that date as well

Fdehell
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
LVL 9

Expert Comment

by:_GeG_
ID: 12069075
how did you try to change it?
0
 
LVL 9

Assisted Solution

by:AlanJDM
AlanJDM earned 250 total points
ID: 12069124
If you are sure that the database connection is bing made, then I would reinstall PHPBB. Definitely sounds like something got corrupt. 01-01-1970 is exactly what any PHP date/time function would return if it was passed a NULL or "blank" parameter, which is why I questioned weather or not you where seeing any data at all being returned.

I use PHPBB on several of our sites and I have never seen nor heard of anything like this so I think You should do a fresh install to be sure none of the files are corrupt.


Alan
0
 
LVL 1

Author Comment

by:fdehell
ID: 12069342
Geg, i went to the database with phpmyadmin and pasted the code in which was the date formatted in unix style, should i have done that different or?


Fdehell
0
 
LVL 9

Expert Comment

by:_GeG_
ID: 12069433
phpmyadmin is good ;)

if you know in which field you want to enter the data, just edit the row, and paste 20040903 in it. Probably phpmyadmin gives you a choice on the left side, something like now. Don't choose that. Now just press go. When you browse the table, the value should have changed.

If it doesn't work, tell me exactely what you pasted where.
0
 
LVL 1

Author Comment

by:fdehell
ID: 12076706
Hi geg thx for still hanging on!

Isnt it strange that the config value which is record_online_date is a varchar, shouldnt that be something like the function unix_timestamp or from_unixtime, do you know this?

config_name varchar(255)     record_online_date      
config_value varchar(255)       1094677432 ---> this alue was pasted in by me it is the date of 3 september converted to unix style

This are the current values, and i thought maybe the config_value should be a function ?

Fdehell
0
 
LVL 9

Expert Comment

by:_GeG_
ID: 12077145
shouldn't you change the date in the Admin section? What happens if you set it there?
0
 
LVL 1

Author Comment

by:fdehell
ID: 12077188
It does not give me the option to do so in the admin section, though after executing the previously described, the board starts date changed into 20 august this year, then it jumped back to the 01 01 1970 again. Maybe i should give it up no?

Fdehell
0
 
LVL 9

Expert Comment

by:_GeG_
ID: 12077299
:( this seems to be a phpbb specific problem, so better post at their support forum.
Sorry that I couldn't help, maabe it just something simple, like that you have a switch to "go live" and the board counts from that moment, or whatever....
0
 
LVL 9

Expert Comment

by:AlanJDM
ID: 12077345
I have seen people save dates as strings like that before. If you know that the format of the displayed date will always be stored the same way it is going to be used upon querying it later, then it is more efficient to not have to do the timestamp converting later on. I personally don't agree with the practice, but I have seen it done.

I am going to say again, you need to reinstall PHPBB. Even if you are able to make whatever changes you need to make to get it working, there is obviously something else wrong. PHPBB is a very stable, widely used product. There certainly should be no need to edit any code and/or database structures to get it to work.


Alan
0
 
LVL 1

Author Comment

by:fdehell
ID: 12077455
Ok well thank you both for your help, efforts will be rewarded regardless of the fact that i didnt get the date set the right way, i will divide the points , i have been at the phpbb forum by the way but they could not help me either so this was my last resort nevertheless a big thx for trying Geg and  Alan, you surely belong to the die hards which i think is great and which i have deepest respect for!

Cheers to the both of you

Fdehell
0
 
LVL 1

Author Comment

by:fdehell
ID: 12077477
I have given the excellent value, because i find it excellent that you two did not give up where a whole forum had already given up [phpBB]

Fdehell
0
 
LVL 9

Expert Comment

by:AlanJDM
ID: 12077542
Sorry we couldn't have come to a proper resolution for you. I do hope you will have a go at re-installing PHPBB as I do think it will help. Anyway, let us know if you come across any new info that could help resolve this.


Alan
0
 
LVL 9

Expert Comment

by:_GeG_
ID: 12077671
[quote]a big thx for trying Geg and  Alan, you surely belong to the die hards which i think is great and which i have deepest respect for![/quote]
English is not my native language, so I cannot formulate a fitting answer to this, but let's try:
You must be one of the last persons on earth who thanks people for not solving a problem. Thank you to fdehell for keeping up old values ;)
0
 
LVL 9

Expert Comment

by:AlanJDM
ID: 12077864
"Thank you to fdehell for keeping up old values"

Yes, I second that! People like fdehell are who I come to these forums and hope to help in some way. We could use a few more like him around here.



Alan
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will explain how to display the first page of your Microsoft Word documents (e.g. .doc, .docx, etc...) as images in a web page programatically. I have scoured the web on a way to do this unsuccessfully. The goal is to produce something …
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question