Resource icon

Setting up a Trash Forum

Vincent

Well-known member
VincentU submitted a new resource:

Setting up a Trash Forum (version 1.0) - Set up a Trash Forum

I like to have a trash forum at my site so here's how to do it:

1. Set up a Trash Forum, don't forget to untick "Allow new messages to be posted in this forum".

2. In library\XenForo\Model\Thread.php and In library\XenForo\Model\InlineMod\Thread.php change:
Code:
$dw->set('discussion_state', 'deleted');

to

Code:
$dw->set('node_id', 'xxx');

3. Change xxx with the ID of your trash forum.

Now, every time you soft-delete a thread it will appear as a...

Read more about this resource...
 
Getting an error:

#0 /www/library/XenForo/Model/Thread.php(1941): XenForo_Application::handlePhpError(4096, 'Object of class...', '/www/...', 1941, Array)
#1 /www/library/XenForo/ControllerPublic/Thread.php(1261): XenForo_Model_Thread->deleteThread(3, 'soft', Array)
#2 /www/library/XenForo/FrontController.php(347): XenForo_ControllerPublic_Thread->actionDelete()
#3 /www/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#4 /www/index.php(13): XenForo_FrontController->run()

ErrorException: Object of class EWRporta_DataWriter_Discussion_Thread could not be converted to string - library/XenForo/Model/Thread.php:1941

I'm think that that line is the dw->set('diss...

Anyone know how to fix
 
Getting an error:

#0 /www/library/XenForo/Model/Thread.php(1941): XenForo_Application::handlePhpError(4096, 'Object of class...', '/www/...', 1941, Array)
#1 /www/library/XenForo/ControllerPublic/Thread.php(1261): XenForo_Model_Thread->deleteThread(3, 'soft', Array)
#2 /www/library/XenForo/FrontController.php(347): XenForo_ControllerPublic_Thread->actionDelete()
#3 /www/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#4 /www/index.php(13): XenForo_FrontController->run()

ErrorException: Object of class EWRporta_DataWriter_Discussion_Thread could not be converted to string - library/XenForo/Model/Thread.php:1941

I'm think that that line is the dw->set('diss...

Anyone know how to fix
Seems like a clash with XenPorta.
 
Back
Top Bottom