[TH] Credits: Shop [Deleted]

Nobody can register either:

Code:
Zend_Db_Statement_Mysqli_Exception: Mysqli statement execute error : Field 'adcredit_shop_postbit_icons' doesn't have a default value - library/Zend/Db/Statement/Mysqli.php:214
Generated By: Unknown Account, 2 minutes ago

Code:
#0 /var/www/vhosts/wweforums.net/httpdocs/library/Zend/Db/Statement.php(297): Zend_Db_Statement_Mysqli->_execute(Array)
#1 /var/www/vhosts/wweforums.net/httpdocs/library/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#2 /var/www/vhosts/wweforums.net/httpdocs/library/Zend/Db/Adapter/Abstract.php(574): Zend_Db_Adapter_Abstract->query('INSERT INTO `xf...', Array)
#3 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/DataWriter.php(1624): Zend_Db_Adapter_Abstract->insert('xf_user', Array)
#4 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/DataWriter.php(1613): XenForo_DataWriter->_insert()
#5 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/DataWriter.php(1405): XenForo_DataWriter->_save()
#6 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/ControllerPublic/Register.php(416): XenForo_DataWriter->save()
#7 /var/www/vhosts/wweforums.net/httpdocs/library/UserEss/ControllerPublic/Register.php(68): XenForo_ControllerPublic_Register->actionRegister()
#8 /var/www/vhosts/wweforums.net/httpdocs/library/Andy/NewUserConversation/ControllerPublic/Register.php(16): UserEss_ControllerPublic_Register->actionRegister()
#9 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/FrontController.php(347): Andy_NewUserConversation_ControllerPublic_Register->actionRegister()
#10 /var/www/vhosts/wweforums.net/httpdocs/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#11 /var/www/vhosts/wweforums.net/httpdocs/index.php(13): XenForo_FrontController->run()
#12 {main}

Check out patch 2 that I mailed out the other day
 
Check out patch 2 that I mailed out the other day

Code:
Mysqli statement execute error : Duplicate column name 'display_on_profile_inventory'

Zend_Db_Statement_Mysqli->_execute() in Zend/Db/Statement.php at line 297
Zend_Db_Statement->execute() in Zend/Db/Adapter/Abstract.php at line 479
Zend_Db_Adapter_Abstract->query() in Audentio/Credit/Shop/Listener/Install/1000472.php at line 14
Audentio_Credit_Shop_Listener_Install_1000472::run() in Audentio/Credit/Shop/Listener/Install.php at line 29
Audentio_Credit_Shop_Listener_Install::run()
call_user_func() in XenForo/Model/AddOn.php at line 215
XenForo_Model_AddOn->installAddOnXml() in ConvEss/Model/AddOn.php at line 24
ConvEss_Model_AddOn->installAddOnXml() in XenForo/Model/AddOn.php at line 169
XenForo_Model_AddOn->installAddOnXmlFromFile() in XenForo/ControllerAdmin/AddOn.php at line 236
XenForo_ControllerAdmin_AddOn->actionUpgrade() in XenForo/FrontController.php at line 347
XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 134
XenForo_FrontController->run() in /var/www/vhosts/wweforums.net/httpdocs/admin.php at line 13
 
Im scared to buy this product, lol. Have these been fixed?

Not yet, members have been unable to register for 24+ hours now. However, this issue may be exclusive to my site only and the plugins I run in addition to this one. This is most likely the case because my server errors mention other plugins.
 
I have fixed broken registration by setting default values of rows adcredit_shop_postbit_icons and adcredit_shop_profile_icons to NULL. The plugin must remain disabled though, or you get errors when viewing any thread.
 
An exception occurred: array_key_exists() expects parameter 2 to be array, boolean given in /var/www/CENSORED/library/Audentio/Credit/Shop/ViewPublic/Thread/View.php on line 16

  1. XenForo_Application::handlePhpError()
  2. array_key_exists() in Audentio/Credit/Shop/ViewPublic/Thread/View.php at line 16
  3. Audentio_Credit_Shop_ViewPublic_Thread_View->renderHtml() in Waindigo/CustomFields/Extend/XenForo/ViewPublic/Thread/View.php at line 16
  4. Waindigo_CustomFields_Extend_XenForo_ViewPublic_Thread_View->renderHtml() in Audentio/Credit/Core/ViewPublic/Thread/View.php at line 6
  5. Audentio_Credit_Core_ViewPublic_Thread_View->renderHtml() in XenForo/ViewRenderer/Abstract.php at line 227
  6. XenForo_ViewRenderer_Abstract->renderViewObject() in XenForo/ViewRenderer/HtmlPublic.php at line 71
  7. XenForo_ViewRenderer_HtmlPublic->renderView() in XenForo/FrontController.php at line 586
  8. XenForo_FrontController->renderView() in XenForo/FrontController.php at line 158
  9. XenForo_FrontController->run() in /var/www/kinmunity.com/index.php at line 13
Upon viewing thread. Please fix this.
 
My errors are after patch2 as well

I have fixed broken registration by setting default values of rows adcredit_shop_postbit_icons and adcredit_shop_profile_icons to NULL. The plugin must remain disabled though, or you get errors when viewing any thread.

An exception occurred: array_key_exists() expects parameter 2 to be array, boolean given in /var/www/CENSORED/library/Audentio/Credit/Shop/ViewPublic/Thread/View.php on line 16

  1. XenForo_Application::handlePhpError()
  2. array_key_exists() in Audentio/Credit/Shop/ViewPublic/Thread/View.php at line 16
  3. Audentio_Credit_Shop_ViewPublic_Thread_View->renderHtml() in Waindigo/CustomFields/Extend/XenForo/ViewPublic/Thread/View.php at line 16
  4. Waindigo_CustomFields_Extend_XenForo_ViewPublic_Thread_View->renderHtml() in Audentio/Credit/Core/ViewPublic/Thread/View.php at line 6
  5. Audentio_Credit_Core_ViewPublic_Thread_View->renderHtml() in XenForo/ViewRenderer/Abstract.php at line 227
  6. XenForo_ViewRenderer_Abstract->renderViewObject() in XenForo/ViewRenderer/HtmlPublic.php at line 71
  7. XenForo_ViewRenderer_HtmlPublic->renderView() in XenForo/FrontController.php at line 586
  8. XenForo_FrontController->renderView() in XenForo/FrontController.php at line 158
  9. XenForo_FrontController->run() in /var/www/kinmunity.com/index.php at line 13
Upon viewing thread. Please fix this.

I don't have access to the mailing list right now as I'm at home and we don't have internet at our new office yet. But a quick fix for this error is the following:

In library/Audentio/Credit/Shop/ViewPublic/Thread/View.php replace:
Code:
if (array_key_exists('icons', $postbitIcons))

With:
Code:
if (is_array($postbitIcons) && array_key_exists('icons', $postbitIcons))

and you won't get that error anymore.

Regards,

Jake
 
Any intention to make this product be able to sell "Actual" Items. The lack of a shop for xF for selling "Non-digital", even with its maturity now is massively surprising. I don't want to have to use IPB, but I may have to. Here's top hoping you guys add such support.
 
I don't have access to the mailing list right now as I'm at home and we don't have internet at our new office yet. But a quick fix for this error is the following:

In library/Audentio/Credit/Shop/ViewPublic/Thread/View.php replace:
Code:
if (array_key_exists('icons', $postbitIcons))

With:
Code:
if (is_array($postbitIcons) && array_key_exists('icons', $postbitIcons))

and you won't get that error anymore.

Regards,

Jake

Does that fix the mysql error that indicates a default value isn't set for
adcredit_shop_postbit_icons?
 
Well, I made that change, but I still get the error.

Mysqli statement execute error : Field 'adcredit_shop_postbit_icons' doesn't have a default value

  1. Zend_Db_Statement_Mysqli->_execute() in Zend/Db/Statement.php at line 317
  2. Zend_Db_Statement->execute() in Zend/Db/Adapter/Abstract.php at line 479
  3. Zend_Db_Adapter_Abstract->query() in Zend/Db/Adapter/Abstract.php at line 574
  4. Zend_Db_Adapter_Abstract->insert() in XenForo/DataWriter.php at line 1624
  5. XenForo_DataWriter->_insert() in XenForo/DataWriter.php at line 1613
  6. XenForo_DataWriter->_save() in XenForo/DataWriter.php at line 1405
  7. XenForo_DataWriter->save() in XenForo/ControllerPublic/Register.php at line 416
  8. XenForo_ControllerPublic_Register->actionRegister() in XenForo/FrontController.php at line 347
  9. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 134
  10. XenForo_FrontController->run() in /xxxx/index.php at line 13
I'll have to uninstall the addon because even disabling it won't remove the error.

Well, wait a second, I probably updated the wrong piece of code.
 
Well, I give up, my version of 1.0.4 AD Credits Shop file:
library/Audentio/Credit/Shop/ViewPublic/Thread/View.php

Doesn't have any reference to
if (array_key_exists('icons', $postbitIcons))

So I'm gonna have to start over, or stick with Credits.

Why is this code being executed even if the addon is disabled?
 
Well, I give up, my version of 1.0.4 AD Credits Shop file:
library/Audentio/Credit/Shop/ViewPublic/Thread/View.php

Doesn't have any reference to
if (array_key_exists('icons', $postbitIcons))

So I'm gonna have to start over, or stick with Credits.

Why is this code being executed even if the addon is disabled?

It isn't being executed, if you disable the add-on there is no default value for that field (as it is set by the DataWriter). I had issues with having MySQL set a default value for blob fields on older versions of MySQL so I left it to be handled by the DataWriter. I will email you a full package with the fixed code for the shop though, just to be sure.

- Jake
 
Now, aftering making sure I'm using "Patch 2" of 1.0.4, I get the same error:

Field 'adcredit_shop_postbit_icons' doesn't have a default value

I don't see how changing the View.php file is going to affect an error in the registration process, but it still happens for me. I'll have to uninstall it because nobody can register.
 
I have fixed broken registration by setting default values of rows adcredit_shop_postbit_icons and adcredit_shop_profile_icons to NULL. The plugin must remain disabled though, or you get errors when viewing any thread.

Now, aftering making sure I'm using "Patch 2" of 1.0.4, I get the same error:

Field 'adcredit_shop_postbit_icons' doesn't have a default value

I don't see how changing the View.php file is going to affect an error in the registration process, but it still happens for me. I'll have to uninstall it because nobody can register.

@SneakyDave I did this before the official fix was issued. They are in xf_user. Both fixes combined work fine.
 
Top Bottom