Opened 10 years ago
Closed 10 years ago
#29879 closed defect (bug) (duplicate)
theme_mod option length
Reported by: | aubreypwd | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 4.0 |
Component: | Themes | Keywords: | |
Focuses: | Cc: |
Description
Today I uploaded a theme that had a rather long name: andrew-vista-surgicalcloud-scheduleperfect-hybrid-wordpress-theme-3b5734edbcc7.zip
It was downloaded from a BitBucket Repository and automatically included this long name with SHA's, etc, so the folder in the .zip was named andrew-vista-surgicalcloud-scheduleperfect-hybrid-wordpress-theme-3b5734edbcc7
, thus the uploaded theme folder created on the server was named andrew-vista-surgicalcloud-scheduleperfect-hybrid-wordpress-theme-3b5734edbcc7
.
All was fine until I ran into a problem. Anything saved via 'type' => 'theme_mod'
, including menus, was not saving. I did a look in my DB and found that the key for the option was shorter than the folder name, see http://prntscr.com/4tyxio
Not sure what the fix is, but this at least happened on two WordPress installs.
I assume that this is hitting the limit of 64 characters for the
option_name
column in the options table. I would imagine this scenario happening with other premium themes too.