Thesis theme and Wordpress 2.8

by Carlos Dagorret on June 11, 2009

The Thesis theme does not work well with Wordpress 2.8.

One effect is that it does not work the buttons to upload images and videos in the edition of a post.

The ultimate solution is to update the theme to version 1.5.1. This version supports the new features of Wordpress 2.8. See more at: http://diythemes.com/thesis/version-151-release/

Another solution to touch the code of Thesis 1.5.

You have to find the file admin.php in the directory /lib/admin under the theme.

Here:

1) Search thesis_options_js function () and replace this code

$date_modified_js = filemtime(THESIS_SCRIPTS . '/thesis.js');
$date_modified_ui = filemtime(THESIS_SCRIPTS . '/jquery-ui.js');
echo '<script type="text/javascript" src="' . THESIS_SCRIPTS_FOLDER . '/thesis.js?d=' . date('mdy-Gms', $date_modified_js) . '" /></script>' . "\n";
echo '<script type="text/javascript" src="' . THESIS_SCRIPTS_FOLDER . '/jquery-ui.js?d=' . date('mdy-Gms', $date_modified_ui) . '" /></script>' . "\n";

For this other code:


if (!is_admin()) { return; }
$date_modified_js = filemtime(THESIS_SCRIPTS . '/thesis.js');
$date_modified_ui = filemtime(THESIS_SCRIPTS . '/jquery-ui.js');
wp_enqueue_script('jquery-ui-core');
wp_enqueue_script('jquery-ui-sortable');
wp_enqueue_script('jquery-ui-tabs');
wp_enqueue_script('thesis-admin-js', THESIS_SCRIPTS_FOLDER.'/thesis.js');

2) In the same file search function thesis_admin_styles_and_scripts (). And replace only this code

add_action('admin_head', 'thesis_options_stylesheet');
add_action('admin_head', 'thesis_options_js');

for this:

add_action('admin_head', 'thesis_options_stylesheet');
add_action('admin_head', 'thesis_options_js');
add_action('init', 'thesis_options_js');

Save and enjoy.

Please backup the file : /lib/admin/admin.php.

If you enjoyed this post, please consider leaving a comment or subscribing to the RSS feed to have future articles delivered to your feed reader.
blog comments powered by Disqus

Previous post:

Next post: