I'm trying to import the XML for Core Dark as a child of Core Parent.

When I click "Import", I get the below:

XF\Db\Exception: MySQL query error [1364]: Field 'th_iau_profile_id' doesn't have a default value in src/XF/Db/AbstractStatement.php at line 228
XF\Db\AbstractStatement->getException() in src/XF/Db/Mysqli/Statement.php at line 196
XF\Db\Mysqli\Statement->getException() in src/XF/Db/Mysqli/Statement.php at line 77
XF\Db\Mysqli\Statement->execute() in src/XF/Db/AbstractAdapter.php at line 94
XF\Db\AbstractAdapter->query() in src/XF/Db/AbstractAdapter.php at line 221
XF\Db\AbstractAdapter->insert() in src/XF/Mvc/Entity/Entity.php at line 1452
XF\Mvc\Entity\Entity->_saveToSource() in src/XF/Mvc/Entity/Entity.php at line 1184
XF\Mvc\Entity\Entity->save() in src/XF/Service/Style/Import.php at line 366
XF\Service\Style\Import->getTargetStyle() in src/XF/Service/Style/Import.php at line 117
XF\Service\Style\Import->importFromXml() in src/XF/Admin/Controller/Style.php at line 398
XF\Admin\Controller\Style->actionImport() in src/XF/Mvc/Dispatcher.php at line 350
XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 261
XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 113
XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 55
XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2184
XF\App->run() in src/XF.php at line 391
XF::runApp() in admin.php at line 13


Pixel Exit Staff
Do you have the add-on install from ThemeHouse? It appears to be a conflict there... the style will definitely import on a normal installation. Can you try disabling that add-on if you do have it?


Do you have the add-on install from ThemeHouse? It appears to be a conflict there... the style will definitely import on a normal installation. Can you try disabling that add-on if you do have it?
Yes, and I actually did disable it and still got the error.

I'm going to try just uninstalling it entirely. I haven't even used it... Was just curious to try it out.


A bit confused on the appropriate way to have a dark + lite.

Should it be

Core (Parent) > Core > Core Dark (Parent) > Core Dark (Parent) > Core Dark

or just

Core (Parent) > Core > Core Dark (Parent) > Core Dark

I'm sure I'm making it harder than it needs to be :)


Pixel Exit Staff
If you're wanting to run just the dark style:

import: style-Core-Dark-(Parent-DO-NOT-EDIT).xml from the /xml/ folder and create a child, you're done.

If you want to run both light and dark style:

Import: style-Core-(Parent-DO-NOT-EDIT).xml from the /xml/ folder and create a child style call it "My site light" (or whatever you want). Then import "style-Core-Dark.xml" from the /customchilds/ as a child of your "My site light" and you can edit that directly (no need for a child of this). When you upgrade this version you'll only import and overwrite the main Core style, not the core dark you imported.


Awesome. I want both, so I think I did it correct.
This look good?



Pixel Exit Staff
Looks perfect, You can edit the "Core" and "Core Dark" to your own titles (descriptions as well).

With this setup just be careful... ideally your changes should go inside "Core". When making these changes be cautious, if you're setting a font color don't just hard code it to like #000 to make the text black because the dark style will inherit this. Instead, utilize the color palette so use: @xf-textColor which will look nice on both styles.

I hope that makes sense... let me know if you have any questions! You can configure the light bulb for quick switching the styles here: https://pixelexit.com/documentation/light-switch/


Just an FYI, realized I never confirmed. I did have to uninstall ThemeHouse Install & Upgrade.

Simply disabling it did not resolve the error in the OP.

Had no problems after uninstalling.

Pre-Sale Questions

If you have any questions or concerns you want to ask before you make a purchase don't hesitate to use one of our multiple support channels for your convenience.