I'm trying to install a new theme for a wordpress site and when I want to activate a plugin I get this error. Can you help me understand how to solve this error?
function thegem_cf_shortcode_settings()
{
return array(
'name' => __('Custom Fields', 'thegem'),
'base' => 'gem_custom_fields',
'icon' => 'thegem-icon-wpb-ui-custom-fields',
'category' => __('TheGem', 'thegem'),
'description' => __('Custom Fields', 'thegem'),
'params' => array_merge(
/* General - Layout */
thegem_cf_set_layout_params(),
/* General - Styles */
thegem_cf_set_style_params(),
/* Extra Options */
thegem_set_elements_extra_options(),
// Design Options
thegem_cf_set_design_options_params(),
/* Responsive Options */
thegem_set_elements_responsive_options(),
thegem_cf_extends_responsive_options_params(),
)
}
function thegem_cf_shortcode($atts, $content)
{
I'm trying to install a new theme for a wordpress site and when I want to activate a plugin I get this error. Can you help me understand how to solve this error?
function thegem_cf_shortcode_settings()
{
return array(
'name' => __('Custom Fields', 'thegem'),
'base' => 'gem_custom_fields',
'icon' => 'thegem-icon-wpb-ui-custom-fields',
'category' => __('TheGem', 'thegem'),
'description' => __('Custom Fields', 'thegem'),
'params' => array_merge(
/* General - Layout */
thegem_cf_set_layout_params(),
/* General - Styles */
thegem_cf_set_style_params(),
/* Extra Options */
thegem_set_elements_extra_options(),
// Design Options
thegem_cf_set_design_options_params(),
/* Responsive Options */
thegem_set_elements_responsive_options(),
thegem_cf_extends_responsive_options_params(),
)
}
function thegem_cf_shortcode($atts, $content)
{
Share
Improve this question
edited Jul 31, 2023 at 17:03
YourManDan
4342 silver badges12 bronze badges
asked Jul 30, 2023 at 21:51
Izabela Cecilia MilaIzabela Cecilia Mila
1
1
- 2 Check the error log, the stack trace should tell you exactly which lines of which PHP file the error is. – ray-happyforms Commented Jul 31, 2023 at 6:26
1 Answer
Reset to default 4You have a missing closing bracket on your params
parameter on the array_merge()
. It should look like this:
return array(
'name' => __('Custom Fields', 'thegem'),
'base' => 'gem_custom_fields',
'icon' => 'thegem-icon-wpb-ui-custom-fields',
'category' => __('TheGem', 'thegem'),
'description' => __('Custom Fields', 'thegem'),
'params' => array_merge(
/* General - Layout */
thegem_cf_set_layout_params(),
/* General - Styles */
thegem_cf_set_style_params(),
/* Extra Options */
thegem_set_elements_extra_options(),
// Design Options
thegem_cf_set_design_options_params(),
/* Responsive Options */
thegem_set_elements_responsive_options(),
thegem_cf_extends_responsive_options_params(),
) // <-- missing this bracket
); // <-- missing semicolon