get_results("SELECT group_id, group_name, group_desc, group_longdesc FROM $tableoptiongroups ORDER BY group_id");
@@ -65,31 +65,45 @@ if ($user_level <= 3) {
Writing Options
-
\ No newline at end of file
+
diff --git a/wp-admin/post.php b/wp-admin/post.php
index 917ca05487..5b835e4882 100644
--- a/wp-admin/post.php
+++ b/wp-admin/post.php
@@ -693,7 +693,12 @@ switch($action) {
$ping_status = get_settings('default_ping_status');
$post_pingback = get_settings('default_pingback_flag');
$default_post_cat = get_settings('default_post_category');
- include('edit-form.php');
+
+ if (get_settings('advanced_edit')) {
+ include('edit-form-advanced.php');
+ } else {
+ include('edit-form.php');
+ }
}
?>
diff --git a/wp-admin/upgrade-functions.php b/wp-admin/upgrade-functions.php
index 0b96f8bb10..855df4a205 100644
--- a/wp-admin/upgrade-functions.php
+++ b/wp-admin/upgrade-functions.php
@@ -651,7 +651,7 @@ function upgrade_100() {
function upgrade_101() {
global $wpdb, $tableoptionvalues, $tablelinkcategories, $tableposts, $tablecategories, $tablecomments, $tablelinks;
- // Fix possible duplicate problem from CVS
+ // Fix possible duplicate problem from CVS, we can REMOVE this later
$option59 = $wpdb->get_results("SELECT * FROM $tableoptionvalues WHERE option_id = '59'");
if (1 < count($option59)) {
$wpdb->query("DELETE FROM $tableoptionvalues WHERE option_id = '59' AND optionvalue LIKE('%FROM order%')");
@@ -672,6 +672,7 @@ function upgrade_101() {
add_clean_index($tablelinks , 'link_visible');
}
+
function upgrade_110() {
global $wpdb, $tableusers, $tablecomments, $tableposts, $tableoptiongroups, $tableoptiongroup_options, $tableoptions, $tablepostmeta;
@@ -708,8 +709,8 @@ function upgrade_110() {
$wpdb->query("DELETE FROM $tableoptiongroups WHERE group_id = 6");
// Add blog_charset option
- if(!$wpdb->get_var("SELECT * FROM $tableoptions WHERE option_id = '93'")) {
- $wpdb->query("INSERT INTO $tableoptions (option_id, option_name, option_type, option_value, option_description, option_admin_level) VALUES (93, 'blog_charset', 3, 'utf-8', 'Your blog’s charset (here’s a list of possible charsets)', 8)");
+ if(!$wpdb->get_var("SELECT option_id FROM $tableoptions WHERE option_name = 'blog_charset'")) {
+ $wpdb->query("INSERT INTO $tableoptions (option_name, option_type, option_value, option_admin_level) VALUES ('blog_charset', 3, 'utf-8', 8)");
}
// Convert all datetime fields' values to GMT, add a gmt_offset option
@@ -767,6 +768,18 @@ function upgrade_110() {
)
");
+ // First we need to enlarge option_value so it can hold larger values:
+ $wpdb->query("ALTER TABLE `$tableoptions` CHANGE `option_value` `option_value` TEXT NOT NULL");
+
+ // Now an option for blog pinging
+ if(!$wpdb->get_var("SELECT option_id FROM $tableoptions WHERE option_name = 'ping_sites'")) {
+ $wpdb->query("INSERT INTO $tableoptions (option_name, option_type, option_value, option_admin_level) VALUES ('ping_sites', 3, '', 8)");
+ }
+
+ // Option for using the advanced edit screen by default
+ if(!$wpdb->get_var("SELECT option_id FROM $tableoptions WHERE option_name = 'advanced_edit'")) {
+ $wpdb->query("INSERT INTO $tableoptions (option_name, option_type, option_value, option_admin_level) VALUES ('advanced_edit', 3, '0', 8)");
+ }
}
?>
\ No newline at end of file