Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

update forum latest thread post

Asked Modified Viewed 1,479 times
T
TauTau
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions
asked
Junior Member

Hi,

I managed to get our forums from SMF to phpfusion, but I can't update the field for last post in the forum threads, so these date all to 1970. Problem with this is that sorting isn't correct obviously.
Is there some way, to update that value in the database? The dates of the postings themselves are there and correct, and I need those to be taken to the thread list...
0 replies

7 posts

T
TauTau
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions
answered
Junior Member

hm... there's obviously things that cure themselves... or something scheduled has been run, but the error is gone now (without changing anything in viewforum.php)
0 replies
P
PHPar
P
PHPar 10
  • Member, joined since
  • Contributed 118 posts on the community forums.
  • Started 7 threads in the forums
answered
Member

open viewforum.php

try to change $data to $tdata in line 176
0 replies
T
TauTau
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions
answered
Junior Member

didn't help... I also tried to reply to the threads to see if the errors reduce...
0 replies
P
PHPar
P
PHPar 10
  • Member, joined since
  • Contributed 118 posts on the community forums.
  • Started 7 threads in the forums
answered
Member

try to add another thread
0 replies
T
TauTau
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions
answered
Junior Member

so, when trying the move-over on my online server, everything went smooth so far, but I got an error message when viewing a forum:


Notice: Undefined index: thread_lastuser in /var/www/web4/web/phpfusion/forum/viewforum.php on line 176


where could that error come from? From what I can see, there is no index on thread_lastuser?
0 replies
T
TauTau
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions
answered
Junior Member

cool... I already took thread_lastpostid over, so it was quite easy...

UPDATE phpfusion.fusion0a47d_threads threads
INNER JOIN phpfusion.fusion047d_posts posts
ON posts.post_id=threads.thread_lastpostid
SET threads.thread_lastpost = posts.post_datestamp


I will anyway post the efforts of all this here, since there is no converter from SMF to phpfusion, so maybe all those SQL snippets are useful for someone ;)
0 replies
H
HobbyMan
H
Just some Guy
  • Veteran Member, joined since
  • Contributed 1,486 posts on the community forums.
  • Started 91 threads in the forums
answered
Veteran Member

If a time code is incorrectly formatted or missing, it'll default back to January 1, 1970

You'll need to write a script to harvest post_datestamp from DB_POSTS and input it into thread_lastpost in DB_THREADS using the highest post_id and thread_id
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 7 posts
  • Votes 0 votes
  • Topic users 3 members

3 participants

H
H
Just some Guy
  • Veteran Member, joined since
  • Contributed 1,486 posts on the community forums.
  • Started 91 threads in the forums
P
P
PHPar 10
  • Member, joined since
  • Contributed 118 posts on the community forums.
  • Started 7 threads in the forums
T
T
TauTau 10
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 11 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet