Hi!
I have a little problem with User Role Editor plugin: http://wordpress.org/plugins/user-role-editor/ when using this theme (and it’s framework from ait-themes): http://themeforest.net/item/solitudo-page-builder-30-customizable-elements/6187668.
Everything works as far as I can see, but when I log in with a newly created user I get this error:
Warning: array_flip(): Can only flip STRING and INTEGER values! in /home/warpson/public_html/wp-content/themes/solitudo/ait-theme/@framework/admin/admin.min.php on line 39
the code in that line in themes framework is:
enqueueAdminCssAndJs(){global$pagenow,$page_hook;$hooks=array_flip(self::$pagesSlugs);$assetsUrl=aitPaths()->url->admin.’/assets’;wp_enqueue_style(‘ait-wp-admin-style’,”{$assetsUrl}/css/wp-admin.css”,array(‘media-views’:wink:,AIT_FW_VERSION);$pages=array(‘edit.php’,’post-new.php’,’post.php’,’media-upload.php’:wink:;if(isset($hooks[$page_hook])||in_array($pagenow,$pages)){$min=((defined(‘SCRIPT_DEBUG’:wink:and
SCRIPT_DEBUG)or
AIT_DEV)?”:’.min’;wp_enqueue_style(‘ait-colorpicker’,”{$assetsUrl}/libs/colorpicker/colorpicker.css”,array(),’2.2.1′:wink:;wp_enqueue_style(‘ait-jquery-chosen’,”{$assetsUrl}/libs/chosen/chosen.css”,array(),’0.9.10′:wink:;wp_enqueue_style(‘jquery-ui’,”{$assetsUrl}/libs/jquery-ui/jquery-ui.css”,array(‘media-views’:wink:,AIT_FW_VERSION);wp_enqueue_style(‘jquery-switch’,”{$assetsUrl}/libs/jquery-switch/jquery.switch.css”,array(),’0.4.1′:wink:;wp_enqueue_style(‘ait-admin-style’,”{$assetsUrl}/css/style.css”,array(‘media-views’:wink:,AIT_FW_VERSION);wp_enqueue_style(‘ait-admin-options-controls’,”{$assetsUrl}/css/options-controls”.($pagenow==’edit.php’?”-quickedit”:””:wink:.”.css”,array(‘ait-admin-style’,’ait-jquery-chosen’:wink:,AIT_FW_VERSION);wp_enqueue_script(‘ait.admin’,”{$assetsUrl}/js/ait.admin{$min}.js”,array(‘media-editor’:wink:,AIT_FW_VERSION,TRUE);self::adminGlobalJsSettings();wp_register_script(‘ait-jquery-filedownload’,”{$assetsUrl}/libs/file-download/jquery.fileDownload{$min}.js”,array(‘jquery’,’ait.admin’:wink:,’1.3.3′,TRUE);wp_enqueue_script(‘ait-colorpicker’,”{$assetsUrl}/libs/colorpicker/colorpicker{$min}.js”,array(‘jquery’:wink:,’2.2.1′,TRUE);wp_enqueue_script(‘ait-jquery-chosen’,”{$assetsUrl}/libs/chosen/chosen.jquery{$min}.js”,array(‘jquery’:wink:,’1.0.0′,TRUE);wp_enqueue_script(‘ait-jquery-sheepit’,”{$assetsUrl}/libs/sheepit/jquery.sheepItPlugin{$min}.js”,array(‘jquery’,’ait.admin’:wink:,’1.1.1-ait-1′,TRUE);wp_enqueue_script(‘ait-jquery-deparam’,”{$assetsUrl}/libs/jquery-deparam/jquery-deparam{$min}.js”,array(‘jquery’,’ait.admin’:wink:,FALSE,TRUE);wp_enqueue_script(‘ait-jquery-rangeinput’,”{$assetsUrl}/libs/rangeinput/rangeinput.min.js”,array(‘jquery’,’ait.admin’:wink:,’1.2.7′,TRUE);wp_enqueue_script(‘ait-jquery-numberinput’,”{$assetsUrl}/libs/numberinput/numberinput{$min}.js”,array(‘jquery’,’ait.admin’:wink:,FALSE,TRUE);wp_enqueue_script(‘ait-jquery-switch’,”{$assetsUrl}/libs/jquery-switch/jquery.switch{$min}.js”,array(‘jquery’,’ait.admin’:wink:,FALSE,TRUE);wp_enqueue_script(‘ait-bootstrap-dropdowns’,”{$assetsUrl}/libs/bootstrap-dropdowns/bootstrap-dropdowns{$min}.js”,array(‘jquery’,’ait.admin’:wink:,FALSE,TRUE);wp_enqueue_media();wp_enqueue_script(‘ait.admin.Tabs’,”{$assetsUrl}/js/ait.admin.tabs.js”,array(‘ait.admin’,’jquery’:wink:,AIT_FW_VERSION,TRUE);wp_enqueue_script(‘ait.admin.options’,”{$assetsUrl}/js/ait.admin.options.js”,array(‘ait.admin’,’jquery’,’jquery-ui-tabs’,’ait-jquery-chosen’,’jquery-ui-datepicker’:wink:,AIT_FW_VERSION,TRUE);wp_enqueue_script(‘ait.admin.backup’,”{$assetsUrl}/js/ait.admin.backup.js”,array(‘ait.admin’,’jquery’,’ait-jquery-filedownload’:wink:,AIT_FW_VERSION,TRUE);wp_enqueue_script(‘ait.admin.options.elements’,”{$assetsUrl}/js/ait.admin.options.elements.js”,array(‘ait.admin’,’ait.admin.options’,’jquery-ui-draggable’,’jquery-ui-droppable’,’jquery-ui-sortable’:wink:,AIT_FW_VERSION,TRUE);}}protected
I tried a little hack by changing array_flip to array_keys and warning disappeared but the themes page builder broke. Solution is probably easy but I don’t no what to do. Can anyone help me with this?