ID); // Check if the data is serialized if (is_ms_serialized($decodedData)) { // The data is serialized, so unserialize it $slider_settings = unserialize($decodedData); // Optionally, convert the unserialized data to JSON and save it back in base64 encoding for future access // This step is optional but recommended to transition your data format $jsonEncodedData = json_encode($slider_settings); update_post_meta($post_id, 'awl_ms_settings_' . $post_id, $jsonEncodedData); // Now, to use the newly saved format, fetch and decode again $encodedData = get_post_meta($post_id, 'awl_ms_settings_' . $post_id, true); $slider_settings = json_decode(($encodedData), true); } else { // Assume the data is in JSON format $jsonData = get_post_meta($post_id, 'awl_ms_settings_' . $post_id, true); // Decode the JSON string into an associative array $slider_settings = json_decode($jsonData, true); // Ensure true is passed to get an associative array } // css wp_enqueue_style('ms-bootstrap-css', MS_PLUGIN_URL . 'css/ms-bootstrap.css'); wp_enqueue_style('ms-font-awesome-min-css', MS_PLUGIN_URL . 'css/font-awesome.min.css'); wp_enqueue_style('ms-styles-css', MS_PLUGIN_URL . 'css/styles.css'); wp_enqueue_style('ms-go-to-top-css', MS_PLUGIN_URL . 'css/go-to-top.css'); wp_enqueue_style('ms-toogle-button-css', MS_PLUGIN_URL . 'css/toogle-button.css'); wp_enqueue_style('awl-em-pe-icon-7-stroke-css', MS_PLUGIN_URL . 'css/pe-icon-7-stroke.css'); // js wp_enqueue_script('jquery'); wp_enqueue_script('ms-bootstrap-js', MS_PLUGIN_URL . 'js/bootstrap.js', array('jquery'), '', true); wp_enqueue_script('ms-go-to-top-js', MS_PLUGIN_URL . 'js/go-to-top.js', array('jquery'), '', true); ?>