[TH] Custom Fields [Deleted]

You have to post the actual error content in code tags. Otherwise nobody knows what the actual script called was or all the files involved.
 
yeah i thought i would ask.
Thanks again..

Server Error Log:


Error Info:
Code:
ErrorException: Array to string conversion - library\Waindigo\CustomFields\ViewPublic\Helper\Thread.php:30
Stack Trace:
Code:
#0 C:\xampp\htdocs\xenforo\library\Waindigo\CustomFields\ViewPublic\Helper\Thread.php(30): XenForo_Application::handlePhpError(8, 'Array to string...', 'C:\xampp\htdocs...', 30, Array)
#1 C:\xampp\htdocs\xenforo\library\Waindigo\CustomFields\ViewPublic\Helper\Thread.php(103): Waindigo_CustomFields_ViewPublic_Helper_Thread::getThreadFieldValueHtml(Object(WidgetFramework_XenForo_View1), Array, NULL)
#2 C:\xampp\htdocs\xenforo\library\Waindigo\CustomFields\Extend\XenForo\ViewPublic\Forum\View.php(26): Waindigo_CustomFields_ViewPublic_Helper_Thread::addThreadFieldsValueHtml(Object(WidgetFramework_XenForo_View1), Array)
#3 C:\xampp\htdocs\xenforo\library\XenForo\ViewRenderer\Abstract.php(227): Waindigo_CustomFields_Extend_XenForo_ViewPublic_Forum_View->renderHtml()
#4 C:\xampp\htdocs\xenforo\library\XenForo\ViewRenderer\HtmlPublic.php(67): XenForo_ViewRenderer_Abstract->renderViewObject('XenForo_ViewPub...', 'Html', Array, 'forum_view')
#5 C:\xampp\htdocs\xenforo\library\XenForo\FrontController.php(572): XenForo_ViewRenderer_HtmlPublic->renderView('XenForo_ViewPub...', Array, 'forum_view', NULL)
#6 C:\xampp\htdocs\xenforo\library\XenForo\FrontController.php(158): XenForo_FrontController->renderView(Object(XenForo_ControllerResponse_View), Object(XenForo_ViewRenderer_HtmlPublic), Array)
#7 C:\xampp\htdocs\xenforo\index.php(13): XenForo_FrontController->run()
#8 {main}
Request State:
Code:
array(3) {
  ["url"] => string(56) "http://localhost/xenforo/forums/test-forum.2/"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(0) {
  }
}
 
Can you give steps to replicate this error? It seems to me that this error can only be replicated by editing the database directly or something like that.
 
Can you give steps to replicate this error? It seems to me that this error can only be replicated by editing the database directly or something like that.
When I click on a link to a forum, I get an error.
Code:
An exception occurred: Array to string conversion in C:\xampp\htdocs\xenforo\library\Waindigo\CustomFields\ViewPublic\Helper\Thread.php on line 30

    XenForo_Application::handlePhpError() in Waindigo/CustomFields/ViewPublic/Helper/Thread.php at line 30
    Waindigo_CustomFields_ViewPublic_Helper_Thread::getThreadFieldValueHtml() in Waindigo/CustomFields/ViewPublic/Helper/Thread.php at line 103
    Waindigo_CustomFields_ViewPublic_Helper_Thread::addThreadFieldsValueHtml() in Waindigo/CustomFields/Extend/XenForo/ViewPublic/Forum/View.php at line 26
    Waindigo_CustomFields_Extend_XenForo_ViewPublic_Forum_View->renderHtml() in XenForo/ViewRenderer/Abstract.php at line 227
    XenForo_ViewRenderer_Abstract->renderViewObject() in XenForo/ViewRenderer/HtmlPublic.php at line 67
    XenForo_ViewRenderer_HtmlPublic->renderView() in XenForo/FrontController.php at line 572
    XenForo_FrontController->renderView() in XenForo/FrontController.php at line 158
    XenForo_FrontController->run() in C:/xampp/htdocs/xenforo/index.php at line 13
 
When I click on a link to a forum, I get an error.
Code:
An exception occurred: Array to string conversion in C:\xampp\htdocs\xenforo\library\Waindigo\CustomFields\ViewPublic\Helper\Thread.php on line 30

    XenForo_Application::handlePhpError() in Waindigo/CustomFields/ViewPublic/Helper/Thread.php at line 30
    Waindigo_CustomFields_ViewPublic_Helper_Thread::getThreadFieldValueHtml() in Waindigo/CustomFields/ViewPublic/Helper/Thread.php at line 103
    Waindigo_CustomFields_ViewPublic_Helper_Thread::addThreadFieldsValueHtml() in Waindigo/CustomFields/Extend/XenForo/ViewPublic/Forum/View.php at line 26
    Waindigo_CustomFields_Extend_XenForo_ViewPublic_Forum_View->renderHtml() in XenForo/ViewRenderer/Abstract.php at line 227
    XenForo_ViewRenderer_Abstract->renderViewObject() in XenForo/ViewRenderer/HtmlPublic.php at line 67
    XenForo_ViewRenderer_HtmlPublic->renderView() in XenForo/FrontController.php at line 572
    XenForo_FrontController->renderView() in XenForo/FrontController.php at line 158
    XenForo_FrontController->run() in C:/xampp/htdocs/xenforo/index.php at line 13
Has it always been like that or did you have to set up some custom fields first?
 
Hello,

Not sure if this has been reported yet or not, I did a brief search and didn't see anything.

When I have the option to 'Automatically Create Thread in Forum' selected in the Resource Categories configuration in XF admin panel - I get the following server errors (below). I usually have this set so whenever a new article/resource is submitted through the RM a new thread is automatically created in the forums.


Code:
Server Error Log
Error Info
ErrorException: Fatal Error: Call to undefined method Waindigo_CustomFields_Extend_XenResource_DataWriter_Category::_getFieldModel() - library/Waindigo/CustomFields/Extend/XenResource/DataWriter/Category.php:128

Stack Trace
#0 [internal function]: XenForo_Application::handleFatalError()
#1 {main}
Request State
array(3) {
  ["url"] => string(66) "http://ffxivaddicts.com/admin.php?resource-categories/fates.7/save"
  ["_GET"] => array(1) {
    ["resource-categories/fates_7/save"] => string(0) ""
  }
  ["_POST"] => array(18) {
    ["category_title"] => string(5) "FATES"
    ["category_description"] => string(49) "List of FATES and best areas to quickly level up!"
    ["parent_category_id"] => string(1) "0"
    ["display_order"] => string(1) "6"
    ["allow_local"] => string(1) "1"
    ["allow_external"] => string(1) "1"
    ["allow_commercial_external"] => string(1) "1"
    ["allow_fileless"] => string(1) "1"
    ["usable_user_group_type"] => string(3) "sel"
    ["user_group_ids"] => array(3) {
      [0] => string(1) "3"
      [1] => string(1) "4"
      [2] => string(1) "2"
    }
    ["thread_node_id"] => string(2) "70"
    ["thread_prefix_id"] => string(1) "0"
    ["header"] => string(0) ""
    ["footer"] => string(0) ""
    ["_xfToken"] => string(8) "********"
    ["_xfRequestUri"] => string(43) "/admin.php?resource-categories/fates.7/edit"
    ["_xfNoRedirect"] => string(1) "1"
    ["_xfResponseType"] => string(4) "json"
  }
}



Hope this helps.
Thanks.
 
XF 1.2.2
XFRM 1.0.2
Custom Fields by Waindigo 1.3.0a

/admin.php?resource-categories/

When I'm trying to set "Automatically Create Thread in Forum" for resource category I get this:
Code:
Fatal Error: Call to undefined method Waindigo_CustomFields_Extend_XenResource_DataWriter_Category::_getFieldModel()
  library/Waindigo/CustomFields/Extend/XenResource/DataWriter/Category.php:128
 
I set up some custom field and creat thread normal, but when I enable Debug Options and see the erro
What custom field is it that is causing the error? What are the settings for it? Did you give it a value when you created the thread?
 
What custom field is it that is causing the error? What are the settings for it? Did you give it a value when you created the thread?
i have created 10 Custom Thread Fields:
Single-line text box
Multi-line text box
Drop down selection
Radio Buttons
Check Boxes
Multiple-choice drop down selection
PHP Callback:
When i creat thread if i leave it blank for some field, I'll get erro
if not leave it blank, no erro
Thanks.
 
Now i try leave it blank for 1 field, 2field, 3field but not get an erro again,
I dont understand that what hapened, so i think that's good.
Ah! I want some custom field is requre
Can you add this option to addon?
Like this:


Capture.webp

Thank you very much!
 
Now i try leave it blank for 1 field, 2field, 3field but not get an erro again,
I dont understand that what hapened, so i think that's good.
Ah! I want some custom field is requre
Can you add this option to addon?
Like this:


View attachment 59897

Thank you very much!
You can set thread fields as required on a per-node basis. Just edit the node and the option is there.
 
@Waindigo sorry if I've missed this, but has this been updated where if you have a dropdown field I can display it without using xen:if statements? If so how? {$customFields.FIELD_ID} seems to be showing just the value not the text
 
XF 1.2.2
XFRM 1.0.2
Custom Fields by Waindigo 1.3.0a

/admin.php?resource-categories/

When I'm trying to set "Automatically Create Thread in Forum" for resource category I get this:
Code:
Fatal Error: Call to undefined method Waindigo_CustomFields_Extend_XenResource_DataWriter_Category::_getFieldModel()
  library/Waindigo/CustomFields/Extend/XenResource/DataWriter/Category.php:128
Just info. With the 1.2.2a version my problem is gone.

==============================
Update.
:oops: Oh sorry. Now I reread the version update info attentively.
 
Last edited:
The Default Value of resource custom field for category don't work, isn't it? It isn't displayed when creating a resource. Or it's only for me.
 
Hi @Waindigo,

There are some issues with the "Article discussion link" custom field used with the Library add-on.

First, each time I edit an article with an existing link, the combo boxes come up empty (ie the existing content is not set, but nodes and threads are present and selectable). When clicking on the Save button, the link is lost.
WL1.webpWL2.webp
Also, when browsing the threads list, the threads are ordered by thread_id although it used to be ordered by title (if I remember correctly). This makes the above bug even more painful when you have to look for the thread name each time you edit the article.

Secondly, on a clean install, trying to create an article configure the field, I get this error :
WL0.webp
I actually do not have this error on my live site, this is FYI.

Hoping you'll be able to figure these out. Let me know if you need more information.
 
Last edited:
This is a bug with PHP 5.3+. I thought it was something that was fixed in XenForo core. Are you running the latest version of XenForo?
Oh, the debug mode bug? OK. I'm with 1.2.1 on this install, not yet upgraded to 1.2.2. The other error has been noticed while running on XF1.2.2.

EDIT : OK, I confirm the template error isn't displayed when debug mode is disabled.
 
Top Bottom