diff options
author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-11-14 09:11:25 +0000 |
---|---|---|
committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-11-14 09:11:25 +0000 |
commit | 84ced2073e6ad54fba9ac9fef66f2618f16201f5 (patch) | |
tree | 43a401eccf36d1ac727be481d75b33d182370d17 | |
parent | aa812f5b630554bd154d2c125c5e15ee6bd549bc (diff) | |
download | wordpress-mu-84ced2073e6ad54fba9ac9fef66f2618f16201f5.tar.gz wordpress-mu-84ced2073e6ad54fba9ac9fef66f2618f16201f5.tar.xz wordpress-mu-84ced2073e6ad54fba9ac9fef66f2618f16201f5.zip |
WP Merge
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@432 7be80a69-a1ef-0310-a953-fb0f7c49ff36
31 files changed, 1036 insertions, 997 deletions
diff --git a/wp-inst/wp-admin/admin-db.php b/wp-inst/wp-admin/admin-db.php index 0c5d47b..4912876 100644 --- a/wp-inst/wp-admin/admin-db.php +++ b/wp-inst/wp-admin/admin-db.php @@ -46,7 +46,6 @@ function get_editable_user_ids( $user_id, $exclude_zeros = true ) { $user = new WP_User( $user_id ); if ( ! $user->has_cap('edit_others_posts') ) { - echo "no cap<br/>"; if ( $user->has_cap('edit_posts') || $exclude_zeros == false ) return array($user->id); else diff --git a/wp-inst/wp-admin/admin-functions.php b/wp-inst/wp-admin/admin-functions.php index e26c47f..7235f2a 100644 --- a/wp-inst/wp-admin/admin-functions.php +++ b/wp-inst/wp-admin/admin-functions.php @@ -282,9 +282,6 @@ function edit_user($user_id = 0) { $user->role = $_POST['role']; } - if (isset ($_POST['role'])) { - $user->role = $_POST['role']; - } if (isset ($_POST['email'])) $user->user_email = wp_specialchars(trim($_POST['email'])); if (isset ($_POST['url'])) { diff --git a/wp-inst/wp-admin/categories.php b/wp-inst/wp-admin/categories.php index da015cc..8e8f024 100644 --- a/wp-inst/wp-admin/categories.php +++ b/wp-inst/wp-admin/categories.php @@ -150,9 +150,7 @@ cat_rows(); <?php if ( current_user_can('manage_categories') ) : ?> <div class="wrap"> - <p><?php printf(__('<strong>Note:</strong><br />Deleting a category does not delete posts from that category, it will just set them back to the default category <strong>%s</strong>.'), get_catname( get_option( 'default_category' ) )) ?> - <br /><?php printf(__('You cannot delete the default category, <strong>%s</strong>, as a result. You must set another category as the default one by visiting the <a href="options-writing.php">Writing Options</a> page and changing it there.'), get_catname( get_option( 'default_category' ) )) ?> - </p> +<p><?php printf(__('<strong>Note:</strong><br />Deleting a category does not delete posts from that category, it will just set them back to the default category <strong>%s</strong>.'), get_catname(get_option('default_category'))) ?></p> </div> <div class="wrap"> diff --git a/wp-inst/wp-admin/install.php b/wp-inst/wp-admin/install.php index 510b8aa..453944d 100644 --- a/wp-inst/wp-admin/install.php +++ b/wp-inst/wp-admin/install.php @@ -141,8 +141,8 @@ make_db_current_silent(); populate_options(); populate_roles(); -$wpdb->query("UPDATE $wpdb->options SET option_value = '$weblog_title' WHERE option_name = 'blogname'"); -$wpdb->query("UPDATE $wpdb->options SET option_value = '$admin_email' WHERE option_name = 'admin_email'"); +update_option('blogname', $weblog_title); +update_option('admin_email', $admin_email); // Now drop in some default links $wpdb->query("INSERT INTO $wpdb->linkcategories (cat_id, cat_name) VALUES (1, '".$wpdb->escape(__('Blogroll'))."')"); diff --git a/wp-inst/wp-admin/moderation.php b/wp-inst/wp-admin/moderation.php index 656378e..2d443ad 100644 --- a/wp-inst/wp-admin/moderation.php +++ b/wp-inst/wp-admin/moderation.php @@ -141,7 +141,7 @@ $i = 0; else $class = ''; echo "\n\t<li id='comment-$comment->comment_ID' $class>"; ?> - <p><strong><?php _e('Name:') ?></strong> <?php comment_author_link() ?> <?php if ($comment->comment_author_email) { ?>| <strong><?php _e('E-mail:') ?></strong> <?php comment_author_email_link() ?> <?php } if ($comment->comment_author_email) { ?> | <strong><?php _e('URI:') ?></strong> <?php comment_author_url_link() ?> <?php } ?>| <strong><?php _e('IP:') ?></strong> <a href="http://ws.arin.net/cgi-bin/whois.pl?queryinput=<?php comment_author_IP() ?>"><?php comment_author_IP() ?></a></p> + <p><strong><?php _e('Name:') ?></strong> <?php comment_author_link() ?> <?php if ($comment->comment_author_email) { ?>| <strong><?php _e('E-mail:') ?></strong> <?php comment_author_email_link() ?> <?php } if ($comment->comment_author_url && 'http://' != $comment->comment_author_url) { ?> | <strong><?php _e('URI:') ?></strong> <?php comment_author_url_link() ?> <?php } ?>| <strong><?php _e('IP:') ?></strong> <a href="http://ws.arin.net/cgi-bin/whois.pl?queryinput=<?php comment_author_IP() ?>"><?php comment_author_IP() ?></a> | <strong><?php _e('Date:') ?></strong> <?php comment_date(); ?></p> <?php comment_text() ?> <p><?php echo '<a href="post.php?action=editcomment&comment='.$comment->comment_ID.'">' . __('Edit') . '</a> | ';?> diff --git a/wp-inst/wp-admin/options-discussion.php b/wp-inst/wp-admin/options-discussion.php index 585edcf..7abf4ad 100644 --- a/wp-inst/wp-admin/options-discussion.php +++ b/wp-inst/wp-admin/options-discussion.php @@ -92,7 +92,7 @@ if ($action == 'retrospam') { </fieldset> <p class="submit"> <input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'default_pingback_flag','default_ping_status','default_comment_status','comments_notify','moderation_notify','comment_moderation','require_name_email','comment_whitelist','comment_max_links','moderation_keys','blacklist_keys','open_proxy_check'" /> +<input type="hidden" name="page_options" value="default_pingback_flag,default_ping_status,default_comment_status,comments_notify,moderation_notify,comment_moderation,require_name_email,comment_whitelist,comment_max_links,moderation_keys,blacklist_keys,open_proxy_check" /> <input type="submit" name="Submit" value="<?php _e('Update Options') ?>" /> </p> </form> diff --git a/wp-inst/wp-admin/options-general.php b/wp-inst/wp-admin/options-general.php index b6e8c93..8e4f7ee 100644 --- a/wp-inst/wp-admin/options-general.php +++ b/wp-inst/wp-admin/options-general.php @@ -11,7 +11,7 @@ include('admin-header.php'); <h2><?php _e('General Options') ?></h2> <form name="form1" method="post" action="options.php"> <input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'blogname','blogdescription','users_can_register','gmt_offset','date_format','time_format','start_of_week','comment_registration', 'WPLANG'" /> +<input type="hidden" name="page_options" value="blogname,blogdescription,users_can_register,gmt_offset,date_format,time_format,start_of_week,comment_registration, WPLANG" /> <table width="100%" cellspacing="2" cellpadding="5" class="editform"> <tr valign="top"> <th width="33%" scope="row"><?php _e('Weblog title:') ?></th> diff --git a/wp-inst/wp-admin/options-misc.php b/wp-inst/wp-admin/options-misc.php index 96851e1..b2380a1 100644 --- a/wp-inst/wp-admin/options-misc.php +++ b/wp-inst/wp-admin/options-misc.php @@ -64,7 +64,7 @@ echo "\n\t<option value='$i' $selected>$i</option>"; </p> <p class="submit"> <input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'hack_file','use_fileupload','fileupload_realpath','fileupload_url','fileupload_allowedtypes','fileupload_maxk','fileupload_maxk','fileupload_minlevel','use_geo_positions','use_linksupdate'" /> +<input type="hidden" name="page_options" value="hack_file,use_fileupload,fileupload_realpath,fileupload_url,fileupload_allowedtypes,fileupload_maxk,fileupload_maxk,fileupload_minlevel,use_geo_positions,use_linksupdate" /> <input type="submit" name="Submit" value="<?php _e('Update Options') ?> »" /> </p> </form> diff --git a/wp-inst/wp-admin/options-personal.php b/wp-inst/wp-admin/options-personal.php index 66e0f7f..2ab6a04 100644 --- a/wp-inst/wp-admin/options-personal.php +++ b/wp-inst/wp-admin/options-personal.php @@ -12,7 +12,7 @@ include('admin-header.php'); <form id="personal-options" method="post" action="options-personal-update.php"> <fieldset> <p><?php _e('Personal options are just for you, they don’t affect other users on blog.'); ?><input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'rich_editing'<?php do_action('personal_option_list'); ?>" /></p> +<input type="hidden" name="page_options" value="rich_editing<?php do_action('personal_option_list'); ?>" /></p> <table width="100%" cellspacing="2" cellpadding="5" class="editform"> <tr valign="top"> <th width="33%" scope="row"><?php _e('Editing:') ?></th> diff --git a/wp-inst/wp-admin/options-reading.php b/wp-inst/wp-admin/options-reading.php index 515d480..898e24d 100644 --- a/wp-inst/wp-admin/options-reading.php +++ b/wp-inst/wp-admin/options-reading.php @@ -51,7 +51,7 @@ include('admin-header.php'); </table> <p class="submit"> <input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'posts_per_page','what_to_show','posts_per_rss','rss_use_excerpt','blog_charset','gzipcompression' " /> +<input type="hidden" name="page_options" value="posts_per_page,what_to_show,posts_per_rss,rss_use_excerpt,blog_charset,gzipcompression " /> <input type="submit" name="Submit" value="<?php _e('Update Options') ?> »" /> </p> </form> diff --git a/wp-inst/wp-admin/options-writing.php b/wp-inst/wp-admin/options-writing.php index 8b2b165..0855aa3 100644 --- a/wp-inst/wp-admin/options-writing.php +++ b/wp-inst/wp-admin/options-writing.php @@ -19,6 +19,9 @@ include('admin-header.php'); <tr valign="top"> <th scope="row"><?php _e('Formatting:') ?></th> <td> +<label for="rich_editing"> +<input name="rich_editing" type="checkbox" id="rich_editing" value="true" <?php checked('true', get_settings('rich_editing')); ?> /> +<?php _e('Use the visual rich editor when writing') ?></label><br /> <label for="use_smilies"> <input name="use_smilies" type="checkbox" id="use_smilies" value="1" <?php checked('1', get_settings('use_smilies')); ?> /> <?php _e('Convert emoticons like <code>:-)</code> and <code>:-P</code> to graphics on display') ?></label> @@ -85,7 +88,7 @@ endforeach; <p class="submit"> <input type="hidden" name="action" value="update" /> -<input type="hidden" name="page_options" value="'default_post_edit_rows','use_smilies','ping_sites','mailserver_url', 'mailserver_port','mailserver_login','mailserver_pass','default_category','default_email_category'" /> +<input type="hidden" name="page_options" value="default_post_edit_rows,use_smilies,ping_sites,mailserver_url, mailserver_port,mailserver_login,mailserver_pass,default_category,default_email_category" /> <input type="submit" name="Submit" value="<?php _e('Update Options') ?> »" /> </p> </form> diff --git a/wp-inst/wp-admin/options.php b/wp-inst/wp-admin/options.php index f7ea0fd..cb0018e 100644 --- a/wp-inst/wp-admin/options.php +++ b/wp-inst/wp-admin/options.php @@ -33,40 +33,32 @@ case 'update': if (!$_POST['page_options']) { foreach ($_POST as $key => $value) { - $option_names[] = "'$key'"; + $options[] = "'$key'"; } - $option_names = implode(',', $option_names); } else { - $option_names = stripslashes($_POST['page_options']); + $options = explode(',', stripslashes($_POST['page_options'])); } - $options = $wpdb->get_results("SELECT $wpdb->options.option_id, option_name, option_type, option_value, option_admin_level FROM $wpdb->options WHERE option_name IN ($option_names)"); - // Save for later. $old_siteurl = get_settings('siteurl'); $old_home = get_settings('home'); -// HACK -// Options that if not there have 0 value but need to be something like "closed" - $nonbools = array('default_ping_status', 'default_comment_status'); - if ($options) { - $options = apply_filters( 'options_to_update' , $options ); - foreach ($options as $option) { - $old_val = $option->option_value; - $new_val = trim($_POST[$option->option_name]); - if( in_array($option->option_name, $nonbools) && ( $new_val == '0' || $new_val == '') ) - $new_val = 'closed'; - if ($new_val !== $old_val) { - $result = $wpdb->query("UPDATE $wpdb->options SET option_value = '$new_val' WHERE option_name = '$option->option_name'"); - wp_cache_set($option->option_name, $new_val, 'options'); - $any_changed++; - } + // HACK + // Options that if not there have 0 value but need to be something like "closed" + $nonbools = array('default_ping_status', 'default_comment_status'); + if ($options) { + foreach ($options as $option) { + $option = trim($option); + $value = trim(stripslashes($_POST[$option])); + if( in_array($option, $nonbools) && ( $value == '0' || $value == '') ) + $value = 'closed'; + + if ( update_option($option, $value) ) + $any_changed++; + } } - unset($cache_settings); // so they will be re-read - get_settings('siteurl'); // make it happen now - } // end if options - if ($any_changed) { + if ($any_changed) { // If siteurl or home changed, reset cookies. if ( get_settings('siteurl') != $old_siteurl || get_settings('home') != $old_home ) { // If home changed, write rewrite rules to new location. diff --git a/wp-inst/wp-admin/profile.php b/wp-inst/wp-admin/profile.php index 2250a24..5c43ab5 100644 --- a/wp-inst/wp-admin/profile.php +++ b/wp-inst/wp-admin/profile.php @@ -31,9 +31,6 @@ $bookmarklet_height= 440; <input type="text" name="user_login" value="<?php echo $profiledata->user_login; ?>" disabled="disabled" /> </label></p> -<p><label><?php _e('Role: (no editing)') ?><br /> -<input type="text" name="role" value="<?php echo $wp_roles->role_names[$profileuser->roles[0]] ?>" disabled="disabled" /></label></p> - <p><label><?php _e('First name:') ?><br /> <input type="text" name="first_name" value="<?php echo $profiledata->first_name ?>" /></label></p> diff --git a/wp-inst/wp-admin/users.php b/wp-inst/wp-admin/users.php index 4f6f22b..ae87269 100644 --- a/wp-inst/wp-admin/users.php +++ b/wp-inst/wp-admin/users.php @@ -6,6 +6,7 @@ $title = __('Users'); $parent_file = 'profile.php'; $action = $_REQUEST['action']; +$update = ''; switch ($action) { @@ -19,13 +20,20 @@ case 'promote': if ( !current_user_can('edit_users') ) die(__('You can’t edit users.')); - $userids = $_POST['users']; - foreach($userids as $id) { - $user = new WP_User($id); - $user->set_role($_POST['new_role']); - } + $userids = $_POST['users']; + $update = 'promote'; + foreach($userids as $id) { + // The new role of the current user must also have edit_users caps + if($id == $current_user->id && !$wp_roles->role_objects[$_POST['new_role']]->has_cap('edit_users')) { + $update = 'err_admin_role'; + continue; + } + + $user = new WP_User($id); + $user->set_role($_POST['new_role']); + } - header('Location: users.php?update=promote'); + header('Location: users.php?update=' . $update); break; @@ -46,8 +54,13 @@ case 'dodelete': $userids = $_POST['users']; - foreach($userids as $id) { - switch($_POST['delete_option']) { + $update = 'del'; + foreach ($userids as $id) { + if($id == $current_user->id) { + $update = 'err_admin_del'; + continue; + } + switch($_POST['delete_option']) { case 'delete': wp_delete_user($id); break; @@ -57,7 +70,7 @@ case 'dodelete': } } - header('Location: users.php?update=del'); + header('Location: users.php?update=' . $update); break; @@ -83,26 +96,32 @@ case 'delete': ?> <form action="" method="post" name="updateusers" id="updateusers"> <div class="wrap"> - <h2><?php _e('Delete Users'); ?></h2> - <p><?php _e('You have specified these users for deletion:'); ?></p> - <ul> - <?php - foreach($userids as $id) { - $user = new WP_User($id); - echo "<li><input type=\"hidden\" name=\"users[]\" value=\"{$id}\" />"; - echo "{$id}: {$user->data->user_login}</li>\n"; - } - $all_logins = $wpdb->get_results("SELECT ID, user_login FROM $wpdb->users ORDER BY user_login"); - $user_dropdown = '<select name="reassign_user">'; - foreach($all_logins as $login) { - if(!in_array($login->ID, $userids)) { - $user_dropdown .= "<option value=\"{$login->ID}\">{$login->user_login}</option>"; +<h2><?php _e('Delete Users'); ?></h2> +<p><?php _e('You have specified these users for deletion:'); ?></p> +<ul> +<?php + $go_delete = false; + foreach ($userids as $id) { + $user = new WP_User($id); + if ($id == $current_user->id) { + echo "<li>" . sprintf('ID #%1s: %2s <strong>The current user will not be deleted.</strong>', $id, $user->data->user_login) . "</li>\n"; + } else { + echo "<li><input type=\"hidden\" name=\"users[]\" value=\"{$id}\" />" . sprintf('ID #%1s: %2s', $id, $user->data->user_login) . "</li>\n"; + $go_delete = true; } - } - $user_dropdown .= '</select>'; - ?> - </ul> - <p><?php _e('What should be done with posts and links owned by this user?'); ?></p> + } + $all_logins = $wpdb->get_results("SELECT ID, user_login FROM $wpdb->users ORDER BY user_login"); + $user_dropdown = '<select name="reassign_user">'; + foreach ($all_logins as $login) { + if ( $login->ID == $current_user->id || !in_array($login->ID, $userids) ) { + $user_dropdown .= "<option value=\"{$login->ID}\">{$login->user_login}</option>"; + } + } + $user_dropdown .= '</select>'; + ?> + </ul> +<?php if($go_delete) : ?> + <p><?php _e('What should be done with posts and links owned by this user?'); ?></p> <ul style="list-style:none;"> <li><label><input type="radio" id="delete_option0" name="delete_option" value="delete" checked="checked" /> <?php _e('Delete all posts and links.'); ?></label></li> @@ -111,6 +130,9 @@ case 'delete': </ul> <input type="hidden" name="action" value="dodelete" /> <p class="submit"><input type="submit" name="submit" value="<?php _e('Confirm Deletion'); ?>" /></p> +<?php else : ?> + <p><?php _e('There are no valid users selected for deletion.'); ?></p> +<?php endif; ?> </div> </form> <?php @@ -213,6 +235,18 @@ default: <div id="message" class="updated fade"><p><?php _e('Changed roles.'); ?></p></div> <?php break; + case 'err_admin_role': + ?> + <div id="message" class="error"><p><?php _e("The current user's role must have user editing capabilities."); ?></p></div> + <div id="message" class="updated fade"><p><?php _e('Other user roles have been changed.'); ?></p></div> + <?php + break; + case 'err_admin_del': + ?> + <div id="message" class="error"><p><?php _e("You can't delete the current user."); ?></p></div> + <div id="message" class="updated fade"><p><?php _e('Other users have been deleted.'); ?></p></div> + <?php + break; } endif; if ( isset($errors) ) : ?> diff --git a/wp-inst/wp-includes/comment-functions.php b/wp-inst/wp-includes/comment-functions.php index 82098c0..76d3e42 100644 --- a/wp-inst/wp-includes/comment-functions.php +++ b/wp-inst/wp-includes/comment-functions.php @@ -281,7 +281,7 @@ function comments_popup_link($zero='No Comments', $one='1 Comment', $more='% Com if (!empty($CSSclass)) { echo ' class="'.$CSSclass.'"'; } - echo '>'; + echo 'title="' . __( sprintf('Comment on %s', $post->post_title) ) .'">'; comments_number($zero, $one, $more, $number); echo '</a>'; } @@ -325,7 +325,7 @@ function get_comment_author_link() { $url = get_comment_author_url(); $author = get_comment_author(); - if ( empty( $url ) ) + if ( empty( $url ) || 'http://' == $url ) $return = $author; else $return = "<a href='$url' rel='external nofollow'>$author</a>"; diff --git a/wp-inst/wp-includes/functions-formatting.php b/wp-inst/wp-includes/functions-formatting.php index b9143c7..58661f4 100644 --- a/wp-inst/wp-includes/functions-formatting.php +++ b/wp-inst/wp-includes/functions-formatting.php @@ -41,7 +41,7 @@ function wptexturize($text) { } else { $next = true; } - $curl = preg_replace('/&([^#])(?![a-z12]{1,8};)/', '&$1', $curl); + $curl = preg_replace('/&([^#])(?![a-z1-4]{1,8};)/', '&$1', $curl); $output .= $curl; } return $output; @@ -98,7 +98,7 @@ function seems_utf8($Str) { # by bmorel at ssi dot fr function wp_specialchars( $text, $quotes = 0 ) { // Like htmlspecialchars except don't double-encode HTML entities - $text = preg_replace('/&([^#])(?![a-z12]{1,8};)/', '&$1', $text);- + $text = preg_replace('/&([^#])(?![a-z1-4]{1,8};)/', '&$1', $text);- $text = str_replace('<', '<', $text); $text = str_replace('>', '>', $text); if ( $quotes ) { @@ -349,7 +349,7 @@ function convert_chars($content, $flag = 'obsolete') { $content = preg_replace('/<category>(.+?)<\/category>/','',$content); // Converts lone & characters into & (a.k.a. &) - $content = preg_replace('/&([^#])(?![a-z]{1,8};)/i', '&$1', $content); + $content = preg_replace('/&([^#])(?![a-z1-4]{1,8};)/i', '&$1', $content); // Fix Word pasting $content = strtr($content, $wp_htmltranswinuni); diff --git a/wp-inst/wp-includes/functions.php b/wp-inst/wp-includes/functions.php index d4f7924..cd96216 100644 --- a/wp-inst/wp-includes/functions.php +++ b/wp-inst/wp-includes/functions.php @@ -261,15 +261,18 @@ function url_to_postid($url) { function get_settings($setting) { global $wpdb; - if ( strstr($_SERVER['REQUEST_URI'], 'wp-admin/install.php') || defined('WP_INSTALLING') ) - return false; $value = wp_cache_get($setting, 'options'); if ( false === $value ) { - $value = $wpdb->get_row("SELECT option_value FROM $wpdb->options WHERE option_name = '$setting'"); - if( is_object( $value ) ) { - $value = $value->option_value; + if ( defined('WP_INSTALLING') ) + $wpdb->hide_errors(); + $row = $wpdb->get_row("SELECT option_value FROM $wpdb->options WHERE option_name = '$setting' LIMIT 1"); + if ( defined('WP_INSTALLING') ) + $wpdb->show_errors(); + + if( is_object( $row) ) { // Has to be get_row instead of get_var because of funkiness with 0, false, null values + $value = $row->option_value; wp_cache_set($setting, $value, 'options'); } else { return false; @@ -342,7 +345,7 @@ function update_option($option_name, $newvalue) { // If the new and old values are the same, no need to update. $oldvalue = get_option($option_name); if ( $newvalue == $oldvalue ) - return true; + return false; if ( false === $oldvalue ) { add_option($option_name, $newvalue); diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/about.htm b/wp-inst/wp-includes/js/tinymce/themes/advanced/about.htm index f4130fd..bbd8d13 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/about.htm +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/about.htm @@ -1,52 +1,52 @@ -<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>{$lang_about_title}</title>
- <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
- <script language="javascript" type="text/javascript" src="../../utils/mctabs.js"></script>
- <script language="javascript" type="text/javascript" src="jscripts/about.js"></script>
- <link href="css/dialog_about.css" rel="stylesheet" type="text/css" />
-</head>
-<body id="about" onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none">
- <div class="tabs">
- <ul>
- <li id="general_tab" class="current"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{$lang_about}</a></span></li>
- <li id="help_tab"><span><a href="javascript:mcTabs.displayTab('help_tab','help_panel');" onmousedown="return false;">{$lang_help}</a></span></li>
- <li id="plugins_tab"><span><a href="javascript:mcTabs.displayTab('plugins_tab','plugins_panel');" onmousedown="return false;">{$lang_plugins}</a></span></li>
- </ul>
- </div>
-
- <div class="panel_wrapper">
- <div id="general_panel" class="panel current">
- <h3>{$lang_about_title}</h3>
- <p>Version: {$tinymce_version} ({$tinymce_releasedate})</p>
- <p>TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under <a href="../../license.txt" target="_blank">LGPL</a>
- by Moxiecode Systems AB. It has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances.</p>
- <p>Copyright © 2005, <a href="http://www.moxiecode.com" target="_blank">Moxiecode Systems AB</a>, All rights reserved.</p>
- <p>For more information about this software visit the <a href="http://tinymce.moxiecode.com" target="_blank">TinyMCE website</a>.</p>
-
- <div id="buttoncontainer"></div>
- </div>
-
- <div id="plugins_panel" class="panel">
- <div id="pluginscontainer">
- <h3>{$lang_loaded_plugins}</h3>
-
- <div id="plugintablecontainer">
- </div>
-
- <p> </p>
- </div>
- </div>
-
- <div id="help_panel" class="panel noscroll" style="overflow: visible;">
- <div id="iframecontainer"></div>
- </div>
- </div>
-
- <div class="mceActionPanel">
- <div style="float: right">
- <input type="button" id="cancel" name="cancel" value="{$lang_close}" onclick="tinyMCEPopup.close();" />
- </div>
- </div>
-</body>
-</html>
+<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>{$lang_about_title}</title> + <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script> + <script language="javascript" type="text/javascript" src="../../utils/mctabs.js"></script> + <script language="javascript" type="text/javascript" src="jscripts/about.js"></script> + <link href="css/dialog_about.css" rel="stylesheet" type="text/css" /> +</head> +<body id="about" onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none"> + <div class="tabs"> + <ul> + <li id="general_tab" class="current"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{$lang_about}</a></span></li> + <li id="help_tab"><span><a href="javascript:mcTabs.displayTab('help_tab','help_panel');" onmousedown="return false;">{$lang_help}</a></span></li> + <li id="plugins_tab"><span><a href="javascript:mcTabs.displayTab('plugins_tab','plugins_panel');" onmousedown="return false;">{$lang_plugins}</a></span></li> + </ul> + </div> + + <div class="panel_wrapper"> + <div id="general_panel" class="panel current"> + <h3>{$lang_about_title}</h3> + <p>Version: {$tinymce_version} ({$tinymce_releasedate})</p> + <p>TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under <a href="../../license.txt" target="_blank">LGPL</a> + by Moxiecode Systems AB. It has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances.</p> + <p>Copyright © 2005, <a href="http://www.moxiecode.com" target="_blank">Moxiecode Systems AB</a>, All rights reserved.</p> + <p>For more information about this software visit the <a href="http://tinymce.moxiecode.com" target="_blank">TinyMCE website</a>.</p> + + <div id="buttoncontainer"></div> + </div> + + <div id="plugins_panel" class="panel"> + <div id="pluginscontainer"> + <h3>{$lang_loaded_plugins}</h3> + + <div id="plugintablecontainer"> + </div> + + <p> </p> + </div> + </div> + + <div id="help_panel" class="panel noscroll" style="overflow: visible;"> + <div id="iframecontainer"></div> + </div> + </div> + + <div class="mceActionPanel"> + <div style="float: right"> + <input type="button" id="cancel" name="cancel" value="{$lang_close}" onclick="tinyMCEPopup.close();" /> + </div> + </div> +</body> +</html> diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/anchor.htm b/wp-inst/wp-includes/js/tinymce/themes/advanced/anchor.htm index 6fbe53f..48ba245 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/anchor.htm +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/anchor.htm @@ -1,32 +1,32 @@ -<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>{$lang_insert_anchor_title}</title>
- <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
- <script language="javascript" type="text/javascript" src="jscripts/anchor.js"></script>
-</head>
-<body onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none">
-<form onsubmit="insertAnchor();return false;" action="#">
-
- <table border="0" cellpadding="4" cellspacing="0">
- <tr>
- <td colspan="2" class="title">{$lang_insert_anchor_title}</td>
- </tr>
- <tr>
- <td nowrap="nowrap">{$lang_insert_anchor_name}:</td>
- <td><input name="anchorName" type="text" id="anchorName" value="" style="width: 200px" /></td>
- </tr>
- </table>
-
- <div class="mceActionPanel">
- <div style="float: left">
- <input type="button" id="insert" name="insert" value="{$lang_update}" onclick="insertAnchor();" />
- </div>
-
- <div style="float: right">
- <input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="tinyMCEPopup.close();" />
- </div>
- </div>
-
-</form>
-</body>
-</html>
+<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>{$lang_insert_anchor_title}</title> + <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script> + <script language="javascript" type="text/javascript" src="jscripts/anchor.js"></script> +</head> +<body onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none"> +<form onsubmit="insertAnchor();return false;" action="#"> + + <table border="0" cellpadding="4" cellspacing="0"> + <tr> + <td colspan="2" class="title">{$lang_insert_anchor_title}</td> + </tr> + <tr> + <td nowrap="nowrap">{$lang_insert_anchor_name}:</td> + <td><input name="anchorName" type="text" id="anchorName" value="" style="width: 200px" /></td> + </tr> + </table> + + <div class="mceActionPanel"> + <div style="float: left"> + <input type="button" id="insert" name="insert" value="{$lang_update}" onclick="insertAnchor();" /> + </div> + + <div style="float: right"> + <input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="tinyMCEPopup.close();" /> + </div> + </div> + +</form> +</body> +</html> diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/charmap.htm b/wp-inst/wp-includes/js/tinymce/themes/advanced/charmap.htm index 59d893d..bcebff2 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/charmap.htm +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/charmap.htm @@ -1,52 +1,52 @@ -<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>{$lang_theme_charmap_title}</title>
- <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
- <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
- <script language="javascript" type="text/javascript" src="jscripts/charmap.js"></script>
-</head>
-<body onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none">
-<table align="center" border="0" cellspacing="0" cellpadding="2">
- <tr>
- <td colspan="2" class="title">{$lang_theme_charmap_title}</td>
- </tr>
- <tr>
- <td rowspan="2" align="left" valign="top">
- <script language="javascript" type="text/javascript">renderCharMapHTML();</script>
- </td>
- <td width="100" align="center" valign="top">
- <table border="0" cellpadding="0" cellspacing="0" width="100" style="height: 100px">
- <tr>
- <td class="charmapOver" style="font-size: 40px; height:80px;" id="codeV"> </td>
- </tr>
- <tr>
- <td style="font-size: 10px; font-family: Arial, Helvetica, sans-serif; text-align:center;" id="codeN"> </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td valign="bottom" style="padding-bottom: 3px;">
- <table width="100" align="center" border="0" cellpadding="2" cellspacing="0">
- <tr>
- <td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">HTML-Code</td>
- </tr>
- <tr>
- <td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeA" align="center"> </td>
- </tr>
- <tr>
- <td style="font-size: 1px;"> </td>
- </tr>
- <tr>
- <td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">NUM-Code</td>
- </tr>
- <tr>
- <td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeB" align="center"> </td>
- </tr>
- </table>
- </td>
- </tr>
-</table>
-
-</body>
-</html>
+<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>{$lang_theme_charmap_title}</title> + <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> + <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script> + <script language="javascript" type="text/javascript" src="jscripts/charmap.js"></script> +</head> +<body onload="tinyMCEPopup.executeOnLoad('init();');" style="display: none"> +<table align="center" border="0" cellspacing="0" cellpadding="2"> + <tr> + <td colspan="2" class="title">{$lang_theme_charmap_title}</td> + </tr> + <tr> + <td rowspan="2" align="left" valign="top"> + <script language="javascript" type="text/javascript">renderCharMapHTML();</script> + </td> + <td width="100" align="center" valign="top"> + <table border="0" cellpadding="0" cellspacing="0" width="100" style="height: 100px"> + <tr> + <td class="charmapOver" style="font-size: 40px; height:80px;" id="codeV"> </td> + </tr> + <tr> + <td style="font-size: 10px; font-family: Arial, Helvetica, sans-serif; text-align:center;" id="codeN"> </td> + </tr> + </table> + </td> + </tr> + <tr> + <td valign="bottom" style="padding-bottom: 3px;"> + <table width="100" align="center" border="0" cellpadding="2" cellspacing="0"> + <tr> + <td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">HTML-Code</td> + </tr> + <tr> + <td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeA" align="center"> </td> + </tr> + <tr> + <td style="font-size: 1px;"> </td> + </tr> + <tr> + <td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">NUM-Code</td> + </tr> + <tr> + <td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeB" align="center"> </td> + </tr> + </table> + </td> + </tr> +</table> + +</body> +</html> diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/color_picker.htm b/wp-inst/wp-includes/js/tinymce/themes/advanced/color_picker.htm index 374d846..e35d711 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/color_picker.htm +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/color_picker.htm @@ -1,12 +1,12 @@ -<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
- <title>{$lang_theme_colorpicker_title}</title>
- <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
- <script language="javascript" type="text/javascript" src="jscripts/color_picker.js"></script>
-</head>
-<body onload="tinyMCEPopup.executeOnLoad('init();');" marginheight="3" topmargin="3" leftmargin="3" marginwidth="3" style="display: none">
- <div align="center">
- <script language="javascript" type="text/javascript">renderColorMap();</script>
- </div>
-</body>
-</html>
+<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <title>{$lang_theme_colorpicker_title}</title> + <script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script> + <script language="javascript" type="text/javascript" src="jscripts/color_picker.js"></script> +</head> +<body onload="tinyMCEPopup.executeOnLoad('init();');" marginheight="3" topmargin="3" leftmargin="3" marginwidth="3" style="display: none"> + <div align="center"> + <script language="javascript" type="text/javascript">renderColorMap();</script> + </div> +</body> +</html> diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/about.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/about.js index fc33f85..9cb015d 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/about.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/about.js @@ -1,74 +1,74 @@ -function init() {
- tinyMCEPopup.resizeToInnerSize();
-
- // Give FF some time
- window.setTimeout('insertHelpIFrame();', 10);
-
- var tcont = document.getElementById('plugintablecontainer');
- var plugins = tinyMCE.getParam('plugins', '', true, ',');
- if (plugins.length == 0)
- document.getElementById('plugins_tab').style.display = 'none';
-
- var html = "";
- html += '<table id="plugintable">';
- html += '<thead>';
- html += '<tr>';
- html += '<td>' + tinyMCE.getLang('lang_plugin') + '</td>';
- html += '<td>' + tinyMCE.getLang('lang_author') + '</td>';
- html += '<td>' + tinyMCE.getLang('lang_version') + '</td>';
- html += '</tr>';
- html += '</thead>';
- html += '<tbody>';
-
- for (var i=0; i<plugins.length; i++) {
- var info = getPluginInfo(plugins[i]);
-
- html += '<tr>';
-
- if (info.infourl != null && info.infourl != '')
- html += '<td width="50%" title="' + plugins[i] + '"><a href="' + info.infourl + '" target="mceplugin">' + info.longname + '</a></td>';
- else
- html += '<td width="50%" title="' + plugins[i] + '">' + info.longname + '</td>';
-
- if (info.authorurl != null && info.authorurl != '')
- html += '<td width="35%"><a href="' + info.authorurl + '" target="mceplugin">' + info.author + '</a></td>';
- else
- html += '<td width="35%">' + info.author + '</td>';
-
- html += '<td width="15%">' + info.version + '</td>';
- html += '</tr>';
- }
-
- html += '</tbody>';
- html += '</table>';
-
- tcont.innerHTML = html;
-}
-
-function getPluginInfo(name) {
- var fn = eval('tinyMCEPopup.windowOpener.TinyMCE_' + name + '_getInfo');
-
- if (typeof(fn) != 'undefined')
- return fn();
-
- return {
- longname : name,
- authorurl : '',
- infourl : '',
- author : '--',
- version : '--'
- };
-}
-
-function insertHelpIFrame() {
- var html = '<iframe width="100%" height="300" src="' + tinyMCE.themeURL + "/docs/" + tinyMCE.settings['docs_language'] + "/index.htm" + '"></iframe>';
-
- document.getElementById('iframecontainer').innerHTML = html;
-
- html = '';
- html += '<a href="http://www.moxiecode.com" target="_blank"><img src="http://tinymce.moxiecode.com/images/gotmoxie.png" alt="Got Moxie?" border="0" /></a> ';
- html += '<a href="http://sourceforge.net/projects/tinymce/" target="_blank"><img src="http://sourceforge.net/sflogo.php?group_id=103281" alt="Hosted By Sourceforge" border="0" /></a> ';
- html += '<a href="http://www.freshmeat.net/projects/tinymce" target="_blank"><img src="http://tinymce.moxiecode.com/images/fm.gif" alt="Also on freshmeat" border="0" /></a> ';
-
- document.getElementById('buttoncontainer').innerHTML = html;
-}
+function init() { + tinyMCEPopup.resizeToInnerSize(); + + // Give FF some time + window.setTimeout('insertHelpIFrame();', 10); + + var tcont = document.getElementById('plugintablecontainer'); + var plugins = tinyMCE.getParam('plugins', '', true, ','); + if (plugins.length == 0) + document.getElementById('plugins_tab').style.display = 'none'; + + var html = ""; + html += '<table id="plugintable">'; + html += '<thead>'; + html += '<tr>'; + html += '<td>' + tinyMCE.getLang('lang_plugin') + '</td>'; + html += '<td>' + tinyMCE.getLang('lang_author') + '</td>'; + html += '<td>' + tinyMCE.getLang('lang_version') + '</td>'; + html += '</tr>'; + html += '</thead>'; + html += '<tbody>'; + + for (var i=0; i<plugins.length; i++) { + var info = getPluginInfo(plugins[i]); + + html += '<tr>'; + + if (info.infourl != null && info.infourl != '') + html += '<td width="50%" title="' + plugins[i] + '"><a href="' + info.infourl + '" target="mceplugin">' + info.longname + '</a></td>'; + else + html += '<td width="50%" title="' + plugins[i] + '">' + info.longname + '</td>'; + + if (info.authorurl != null && info.authorurl != '') + html += '<td width="35%"><a href="' + info.authorurl + '" target="mceplugin">' + info.author + '</a></td>'; + else + html += '<td width="35%">' + info.author + '</td>'; + + html += '<td width="15%">' + info.version + '</td>'; + html += '</tr>'; + } + + html += '</tbody>'; + html += '</table>'; + + tcont.innerHTML = html; +} + +function getPluginInfo(name) { + var fn = eval('tinyMCEPopup.windowOpener.TinyMCE_' + name + '_getInfo'); + + if (typeof(fn) != 'undefined') + return fn(); + + return { + longname : name, + authorurl : '', + infourl : '', + author : '--', + version : '--' + }; +} + +function insertHelpIFrame() { + var html = '<iframe width="100%" height="300" src="' + tinyMCE.themeURL + "/docs/" + tinyMCE.settings['docs_language'] + "/index.htm" + '"></iframe>'; + + document.getElementById('iframecontainer').innerHTML = html; + + html = ''; + html += '<a href="http://www.moxiecode.com" target="_blank"><img src="http://tinymce.moxiecode.com/images/gotmoxie.png" alt="Got Moxie?" border="0" /></a> '; + html += '<a href="http://sourceforge.net/projects/tinymce/" target="_blank"><img src="http://sourceforge.net/sflogo.php?group_id=103281" alt="Hosted By Sourceforge" border="0" /></a> '; + html += '<a href="http://www.freshmeat.net/projects/tinymce" target="_blank"><img src="http://tinymce.moxiecode.com/images/fm.gif" alt="Also on freshmeat" border="0" /></a> '; + + document.getElementById('buttoncontainer').innerHTML = html; +} diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/anchor.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/anchor.js index 446a3ce..a89f972 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/anchor.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/anchor.js @@ -1,59 +1,59 @@ -var action, element;
-
-function init() {
- tinyMCEPopup.resizeToInnerSize();
-
- var inst = tinyMCE.getInstanceById(tinyMCE.getWindowArg('editor_id'));
- var anchor = tinyMCE.getParentElement(inst.getFocusElement(), "a", "name");
- var img = inst.getFocusElement();
- action = 'insert';
-
- if (anchor != null) {
- element = anchor;
- action = "update";
- }
-
- if (tinyMCE.getAttrib(img, "class") == "mceItemAnchor") {
- element = img;
- action = "update";
- }
-
- if (action == "update")
- document.forms[0].anchorName.value = element.nodeName == "IMG" ? element.getAttribute("title") : element.getAttribute("name");
-
- document.forms[0].insert.value = tinyMCE.getLang('lang_' + action, 'Insert', true);
-}
-
-function insertAnchor() {
- var inst = tinyMCE.getInstanceById(tinyMCE.getWindowArg('editor_id'));
- var name = document.forms[0].anchorName.value;
-
- tinyMCEPopup.execCommand("mceBeginUndoLevel");
-
- if (action == "update") {
- if (element.nodeName == "IMG")
- element.setAttribute("title", name);
- else
- element.setAttribute("name", name);
- } else {
- var rng = inst.getRng();
-
- if (rng.collapse)
- rng.collapse(false);
-
- name = name.replace(/&/g, '&');
- name = name.replace(/\"/g, '"');
- name = name.replace(/</g, '<');
- name = name.replace(/>/g, '&gr;');
-
- html = '<a name="' + name + '"></a>';
-
- tinyMCEPopup.execCommand("mceInsertContent", false, html);
- tinyMCE.handleVisualAid(inst.getBody(), true, inst.visualAid, inst);
- }
-
- tinyMCEPopup.execCommand("mceEndUndoLevel");
-
- tinyMCE.triggerNodeChange();
- tinyMCEPopup.close();
-}
+var action, element; + +function init() { + tinyMCEPopup.resizeToInnerSize(); + + var inst = tinyMCE.getInstanceById(tinyMCE.getWindowArg('editor_id')); + var anchor = tinyMCE.getParentElement(inst.getFocusElement(), "a", "name"); + var img = inst.getFocusElement(); + action = 'insert'; + + if (anchor != null) { + element = anchor; + action = "update"; + } + + if (tinyMCE.getAttrib(img, "class") == "mceItemAnchor") { + element = img; + action = "update"; + } + + if (action == "update") + document.forms[0].anchorName.value = element.nodeName == "IMG" ? element.getAttribute("title") : element.getAttribute("name"); + + document.forms[0].insert.value = tinyMCE.getLang('lang_' + action, 'Insert', true); +} + +function insertAnchor() { + var inst = tinyMCE.getInstanceById(tinyMCE.getWindowArg('editor_id')); + var name = document.forms[0].anchorName.value; + + tinyMCEPopup.execCommand("mceBeginUndoLevel"); + + if (action == "update") { + if (element.nodeName == "IMG") + element.setAttribute("title", name); + else + element.setAttribute("name", name); + } else { + var rng = inst.getRng(); + + if (rng.collapse) + rng.collapse(false); + + name = name.replace(/&/g, '&'); + name = name.replace(/\"/g, '"'); + name = name.replace(/</g, '<'); + name = name.replace(/>/g, '&gr;'); + + html = '<a name="' + name + '"></a>'; + + tinyMCEPopup.execCommand("mceInsertContent", false, html); + tinyMCE.handleVisualAid(inst.getBody(), true, inst.visualAid, inst); + } + + tinyMCEPopup.execCommand("mceEndUndoLevel"); + + tinyMCE.triggerNodeChange(); + tinyMCEPopup.close(); +} diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/charmap.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/charmap.js index bc9df27..2f758cf 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/charmap.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/charmap.js @@ -1,324 +1,324 @@ -function init() {
- tinyMCEPopup.resizeToInnerSize();
-}
-
-var charmap = new Array();
-
-// for mor details please see w3c.org
-// now here is the complete list ;)
-
-charmap = [
- [' ', ' ', true, 'no-break space'],
- ['&', '&', true, 'ampersand'],
- ['"', '"', true, 'quotation mark'],
-// finance
- ['¢', '¢', true, 'cent sign'],
- ['€', '€', true, 'euro sign'],
- ['£', '£', true, 'pound sign'],
- ['¥', '¥', true, 'yen sign'],
-// signs
- ['©', '©', true, 'copyright sign'],
- ['®', '®', true, 'registered sign'],
- ['™', '™', true, 'trade mark sign'],
- ['‰', '‰', true, 'per mille sign'],
- ['µ', 'µ', true, 'micro sign'],
- ['·', '·', true, 'middle dot'],
- ['•', '•', true, 'bullet'],
- ['…', '…', true, 'three dot leader'],
- ['′', '′', true, 'minutes / feet'],
- ['″', '″', true, 'seconds / inches'],
- ['§', '§', true, 'section sign'],
- ['¶', '¶', true, 'paragraph sign'],
- ['ß', 'ß', true, 'sharp s / ess-zed'],
-// quotations
- ['‹', '‹', true, 'single left-pointing angle quotation mark'],
- ['›', '›', true, 'single right-pointing angle quotation mark'],
- ['«', '«', true, 'left pointing guillemet'],
- ['»', '»', true, 'right pointing guillemet'],
- ['‘', '‘', true, 'left single quotation mark'],
- ['’', '’', true, 'right single quotation mark'],
- ['“', '“', true, 'left double quotation mark'],
- ['”', '”', true, 'right double quotation mark'],
- ['‚', '‚', true, 'single low-9 quotation mark'],
- ['„', '„', true, 'double low-9 quotation mark'],
- ['<', '<', true, 'less-than sign'],
- ['>', '>', true, 'greater-than sign'],
- ['≤', '≤', true, 'less-than or equal to'],
- ['≥', '≥', true, 'greater-than or equal to'],
- ['–', '–', true, 'en dash'],
- ['—', '—', true, 'em dash'],
- ['¯', '¯', true, 'macron'],
- ['‾', '‾', true, 'overline'],
- ['¤', '¤', true, 'currency sign'],
- ['¦', '¦', true, 'broken bar'],
- ['¨', '¨', true, 'diaeresis'],
- ['¡', '¡', true, 'inverted exclamation mark'],
- ['¿', '¿', true, 'turned question mark'],
- ['ˆ', 'ˆ', true, 'circumflex accent'],
- ['˜', '˜', true, 'small tilde'],
- ['°', '°', true, 'degree sign'],
- ['−', '−', true, 'minus sign'],
- ['±', '±', true, 'plus-minus sign'],
- ['÷', '÷', true, 'division sign'],
- ['⁄', '⁄', true, 'fraction slash'],
- ['×', '×', true, 'multiplication sign'],
- ['¹', '¹', true, 'superscript one'],
- ['²', '²', true, 'superscript two'],
- ['³', '³', true, 'superscript three'],
- ['¼', '¼', true, 'fraction one quarter'],
- ['½', '½', true, 'fraction one half'],
- ['¾', '¾', true, 'fraction three quarters'],
-// math / logical
- ['ƒ', 'ƒ', true, 'function / florin'],
- ['∫', '∫', true, 'integral'],
- ['∑', '∑', true, 'n-ary sumation'],
- ['∞', '∞', true, 'infinity'],
- ['√', '√', true, 'square root'],
- ['∼', '∼', false,'similar to'],
- ['≅', '≅', false,'approximately equal to'],
- ['≈', '≈', true, 'almost equal to'],
- ['≠', '≠', true, 'not equal to'],
- ['≡', '≡', true, 'identical to'],
- ['∈', '∈', false,'element of'],
- ['∉', '∉', false,'not an element of'],
- ['∋', '∋', false,'contains as member'],
- ['∏', '∏', true, 'n-ary product'],
- ['∧', '∧', false,'logical and'],
- ['∨', '∨', false,'logical or'],
- ['¬', '¬', true, 'not sign'],
- ['∩', '∩', true, 'intersection'],
- ['∪', '∪', false,'union'],
- ['∂', '∂', true, 'partial differential'],
- ['∀', '∀', false,'for all'],
- ['∃', '∃', false,'there exists'],
- ['∅', '∅', false,'diameter'],
- ['∇', '∇', false,'backward difference'],
- ['∗', '∗', false,'asterisk operator'],
- ['∝', '∝', false,'proportional to'],
- ['∠', '∠', false,'angle'],
-// undefined
- ['´', '´', true, 'acute accent'],
- ['¸', '¸', true, 'cedilla'],
- ['ª', 'ª', true, 'feminine ordinal indicator'],
- ['º', 'º', true, 'masculine ordinal indicator'],
- ['†', '†', true, 'dagger'],
- ['‡', '‡', true, 'double dagger'],
-// alphabetical special chars
- ['À', 'À', true, 'A - grave'],
- ['Á', 'Á', true, 'A - acute'],
- ['Â', 'Â', true, 'A - circumflex'],
- ['Ã', 'Ã', true, 'A - tilde'],
- ['Ä', 'Ä', true, 'A - diaeresis'],
- ['Å', 'Å', true, 'A - ring above'],
- ['Æ', 'Æ', true, 'ligature AE'],
- ['Ç', 'Ç', true, 'C - cedilla'],
- ['È', 'È', true, 'E - grave'],
- ['É', 'É', true, 'E - acute'],
- ['Ê', 'Ê', true, 'E - circumflex'],
- ['Ë', 'Ë', true, 'E - diaeresis'],
- ['Ì', 'Ì', true, 'I - grave'],
- ['Í', 'Í', true, 'I - acute'],
- ['Î', 'Î', true, 'I - circumflex'],
- ['Ï', 'Ï', true, 'I - diaeresis'],
- ['Ð', 'Ð', true, 'ETH'],
- ['Ñ', 'Ñ', true, 'N - tilde'],
- ['Ò', 'Ò', true, 'O - grave'],
- ['Ó', 'Ó', true, 'O - acute'],
- ['Ô', 'Ô', true, 'O - circumflex'],
- ['Õ', 'Õ', true, 'O - tilde'],
- ['Ö', 'Ö', true, 'O - diaeresis'],
- ['Ø', 'Ø', true, 'O - slash'],
- ['Œ', 'Œ', true, 'ligature OE'],
- ['Š', 'Š', true, 'S - caron'],
- ['Ù', 'Ù', true, 'U - grave'],
- ['Ú', 'Ú', true, 'U - acute'],
- ['Û', 'Û', true, 'U - circumflex'],
- ['Ü', 'Ü', true, 'U - diaeresis'],
- ['Ý', 'Ý', true, 'Y - acute'],
- ['Ÿ', 'Ÿ', true, 'Y - diaeresis'],
- ['Þ', 'Þ', true, 'THORN'],
- ['à', 'à', true, 'a - grave'],
- ['á', 'á', true, 'a - acute'],
- ['â', 'â', true, 'a - circumflex'],
- ['ã', 'ã', true, 'a - tilde'],
- ['ä', 'ä', true, 'a - diaeresis'],
- ['å', 'å', true, 'a - ring above'],
- ['æ', 'æ', true, 'ligature ae'],
- ['ç', 'ç', true, 'c - cedilla'],
- ['è', 'è', true, 'e - grave'],
- ['é', 'é', true, 'e - acute'],
- ['ê', 'ê', true, 'e - circumflex'],
- ['ë', 'ë', true, 'e - diaeresis'],
- ['ì', 'ì', true, 'i - grave'],
- ['í', 'í', true, 'i - acute'],
- ['î', 'î', true, 'i - circumflex'],
- ['ï', 'ï', true, 'i - diaeresis'],
- ['ð', 'ð', true, 'eth'],
- ['ñ', 'ñ', true, 'n - tilde'],
- ['ò', 'ò', true, 'o - grave'],
- ['ó', 'ó', true, 'o - acute'],
- ['ô', 'ô', true, 'o - circumflex'],
- ['õ', 'õ', true, 'o - tilde'],
- ['ö', 'ö', true, 'o - diaeresis'],
- ['ø', 'ø', true, 'o slash'],
- ['œ', 'œ', true, 'ligature oe'],
- ['š', 'š', true, 's - caron'],
- ['ù', 'ù', true, 'u - grave'],
- ['ú', 'ú', true, 'u - acute'],
- ['û', 'û', true, 'u - circumflex'],
- ['ü', 'ü', true, 'u - diaeresis'],
- ['ý', 'ý', true, 'y - acute'],
- ['þ', 'þ', true, 'thorn'],
- ['ÿ', 'ÿ', true, 'y - diaeresis'],
-// ['Α', 'Α', true, 'Alpha'],
- ['Β', 'Β', true, 'Beta'],
- ['Γ', 'Γ', true, 'Gamma'],
- ['Δ', 'Δ', true, 'Delta'],
- ['Ε', 'Ε', true, 'Epsilon'],
- ['Ζ', 'Ζ', true, 'Zeta'],
- ['Η', 'Η', true, 'Eta'],
- ['Θ', 'Θ', true, 'Theta'],
- ['Ι', 'Ι', true, 'Iota'],
- ['Κ', 'Κ', true, 'Kappa'],
- ['Λ', 'Λ', true, 'Lambda'],
- ['Μ', 'Μ', true, 'Mu'],
- ['Ν', 'Ν', true, 'Nu'],
- ['Ξ', 'Ξ', true, 'Xi'],
- ['Ο', 'Ο', true, 'Omicron'],
- ['Π', 'Π', true, 'Pi'],
- ['Ρ', 'Ρ', true, 'Rho'],
- ['Σ', 'Σ', true, 'Sigma'],
- ['Τ', 'Τ', true, 'Tau'],
- ['Υ', 'Υ', true, 'Upsilon'],
- ['Φ', 'Φ', true, 'Phi'],
- ['Χ', 'Χ', true, 'Chi'],
- ['Ψ', 'Ψ', true, 'Psi'],
- ['Ω', 'Ω', true, 'Omega'],
- ['α', 'α', true, 'alpha'],
- ['β', 'β', true, 'beta'],
- ['γ', 'γ', true, 'gamma'],
- ['δ', 'δ', true, 'delta'],
- ['ε', 'ε', true, 'epsilon'],
- ['ζ', 'ζ', true, 'zeta'],
- ['η', 'η', true, 'eta'],
- ['θ', 'θ', true, 'theta'],
- ['ι', 'ι', true, 'iota'],
- ['κ', 'κ', true, 'kappa'],
- ['λ', 'λ', true, 'lambda'],
- ['μ', 'μ', true, 'mu'],
- ['ν', 'ν', true, 'nu'],
- ['ξ', 'ξ', true, 'xi'],
- ['ο', 'ο', true, 'omicron'],
- ['π', 'π', true, 'pi'],
- ['ρ', 'ρ', true, 'rho'],
- ['ς', 'ς', true, 'final sigma'],
- ['σ', 'σ', true, 'sigma'],
- ['τ', 'τ', true, 'tau'],
- ['υ', 'υ', true, 'upsilon'],
- ['φ', 'φ', true, 'phi'],
- ['χ', 'χ', true, 'chi'],
- ['ψ', 'ψ', true, 'psi'],
- ['ω', 'ω', true, 'omega'],
-// symbols
- ['ℵ', 'ℵ', false,'alef symbol'],
- ['ϖ', 'ϖ', false,'pi symbol'],
- ['ℜ', 'ℜ', false,'real part symbol'],
- ['ϑ','ϑ', false,'theta symbol'],
- ['ϒ', 'ϒ', false,'upsilon - hook symbol'],
- ['℘', '℘', false,'Weierstrass p'],
- ['ℑ', 'ℑ', false,'imaginary part'],
-// arrows
- ['←', '←', true, 'leftwards arrow'],
- ['↑', '↑', true, 'upwards arrow'],
- ['→', '→', true, 'rightwards arrow'],
- ['↓', '↓', true, 'downwards arrow'],
- ['↔', '↔', true, 'left right arrow'],
- ['↵', '↵', false,'carriage return'],
- ['⇐', '⇐', false,'leftwards double arrow'],
- ['⇑', '⇑', false,'upwards double arrow'],
- ['⇒', '⇒', false,'rightwards double arrow'],
- ['⇓', '⇓', false,'downwards double arrow'],
- ['⇔', '⇔', false,'left right double arrow'],
- ['∴', '∴', false,'therefore'],
- ['⊂', '⊂', false,'subset of'],
- ['⊃', '⊃', false,'superset of'],
- ['⊄', '⊄', false,'not a subset of'],
- ['⊆', '⊆', false,'subset of or equal to'],
- ['⊇', '⊇', false,'superset of or equal to'],
- ['⊕', '⊕', false,'circled plus'],
- ['⊗', '⊗', false,'circled times'],
- ['⊥', '⊥', false,'perpendicular'],
- ['⋅', '⋅', false,'dot operator'],
- ['⌈', '⌈', false,'left ceiling'],
- ['⌉', '⌉', false,'right ceiling'],
- ['⌊', '⌊', false,'left floor'],
- ['⌋', '⌋', false,'right floor'],
- ['⟨', '〈', false,'left-pointing angle bracket'],
- ['⟩', '〉', false,'right-pointing angle bracket'],
- ['◊', '◊', true,'lozenge'],
- ['♠', '♠', false,'black spade suit'],
- ['♣', '♣', true, 'black club suit'],
- ['♥', '♥', true, 'black heart suit'],
- ['♦', '♦', true, 'black diamond suit'],
- [' ', ' ', false,'en space'],
- [' ', ' ', false,'em space'],
- [' ', ' ', false,'thin space'],
- ['‌', '‌', false,'zero width non-joiner'],
- ['‍', '‍', false,'zero width joiner'],
- ['‎', '‎', false,'left-to-right mark'],
- ['‏', '‏', false,'right-to-left mark'],
- ['­', '­', false,'soft hyphen']
-];
-
-function renderCharMapHTML() {
- var charsPerRow = 20, tdWidth=20, tdHeight=20;
- var html = '<table border="0" cellspacing="1" cellpadding="0" width="' + (tdWidth*charsPerRow) + '"><tr height="' + tdHeight + '">';
- var cols=-1;
- for (var i=0; i<charmap.length; i++) {
- if (charmap[i][2]==true) {
- cols++;
- html += ''
- + '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"'
- + ' onmouseover="tinyMCE.switchClass(this,\'charmapOver\');'
- + 'previewChar(\'' + charmap[i][1].substring(1,charmap[i][1].length) + '\',\'' + charmap[i][0].substring(1,charmap[i][0].length) + '\',\'' + charmap[i][3] + '\');"'
- + ' onmouseout="tinyMCE.restoreClass(this,\'charmapOver\');"'
- + ' nowrap="nowrap" onclick="insertChar(\'' + charmap[i][1].substring(2,charmap[i][1].length-1) + '\');"><a style="text-decoration: none;" onfocus="previewChar(\'' + charmap[i][1].substring(1,charmap[i][1].length) + '\',\'' + charmap[i][0].substring(1,charmap[i][0].length) + '\',\'' + charmap[i][3] + '\');" href="javascript:insertChar(\'' + charmap[i][1].substring(2,charmap[i][1].length-1) + '\');" onclick="return false;" onmousedown="return false;" title="' + charmap[i][3] + '">'
- + charmap[i][1]
- + '</a></td>';
- if ((cols+1) % charsPerRow == 0)
- html += '</tr><tr height="' + tdHeight + '">';
- }
- }
- if (cols % charsPerRow > 0) {
- var padd = charsPerRow - (cols % charsPerRow);
- for (var i=0; i<padd-1; i++)
- html += '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"> </td>';
- }
- html += '</tr></table>';
- document.write(html);
-}
-
-function insertChar(chr) {
- tinyMCEPopup.execCommand('mceInsertContent', false, '\&#' + chr + ';');
-
- // Refocus in window
- if (tinyMCEPopup.isWindow)
- window.focus();
-}
-
-function previewChar(codeA, codeB, codeN) {
- var elmA = document.getElementById('codeA');
- var elmB = document.getElementById('codeB');
- var elmV = document.getElementById('codeV');
- var elmN = document.getElementById('codeN');
-
- if (codeA=='#160;') {
- elmV.innerHTML = '__';
- } else {
- elmV.innerHTML = '&' + codeA;
- }
-
- elmB.innerHTML = '&' + codeA;
- elmA.innerHTML = '&' + codeB;
- elmN.innerHTML = codeN;
-}
+function init() { + tinyMCEPopup.resizeToInnerSize(); +} + +var charmap = new Array(); + +// for mor details please see w3c.org +// now here is the complete list ;) + +charmap = [ + [' ', ' ', true, 'no-break space'], + ['&', '&', true, 'ampersand'], + ['"', '"', true, 'quotation mark'], +// finance + ['¢', '¢', true, 'cent sign'], + ['€', '€', true, 'euro sign'], + ['£', '£', true, 'pound sign'], + ['¥', '¥', true, 'yen sign'], +// signs + ['©', '©', true, 'copyright sign'], + ['®', '®', true, 'registered sign'], + ['™', '™', true, 'trade mark sign'], + ['‰', '‰', true, 'per mille sign'], + ['µ', 'µ', true, 'micro sign'], + ['·', '·', true, 'middle dot'], + ['•', '•', true, 'bullet'], + ['…', '…', true, 'three dot leader'], + ['′', '′', true, 'minutes / feet'], + ['″', '″', true, 'seconds / inches'], + ['§', '§', true, 'section sign'], + ['¶', '¶', true, 'paragraph sign'], + ['ß', 'ß', true, 'sharp s / ess-zed'], +// quotations + ['‹', '‹', true, 'single left-pointing angle quotation mark'], + ['›', '›', true, 'single right-pointing angle quotation mark'], + ['«', '«', true, 'left pointing guillemet'], + ['»', '»', true, 'right pointing guillemet'], + ['‘', '‘', true, 'left single quotation mark'], + ['’', '’', true, 'right single quotation mark'], + ['“', '“', true, 'left double quotation mark'], + ['”', '”', true, 'right double quotation mark'], + ['‚', '‚', true, 'single low-9 quotation mark'], + ['„', '„', true, 'double low-9 quotation mark'], + ['<', '<', true, 'less-than sign'], + ['>', '>', true, 'greater-than sign'], + ['≤', '≤', true, 'less-than or equal to'], + ['≥', '≥', true, 'greater-than or equal to'], + ['–', '–', true, 'en dash'], + ['—', '—', true, 'em dash'], + ['¯', '¯', true, 'macron'], + ['‾', '‾', true, 'overline'], + ['¤', '¤', true, 'currency sign'], + ['¦', '¦', true, 'broken bar'], + ['¨', '¨', true, 'diaeresis'], + ['¡', '¡', true, 'inverted exclamation mark'], + ['¿', '¿', true, 'turned question mark'], + ['ˆ', 'ˆ', true, 'circumflex accent'], + ['˜', '˜', true, 'small tilde'], + ['°', '°', true, 'degree sign'], + ['−', '−', true, 'minus sign'], + ['±', '±', true, 'plus-minus sign'], + ['÷', '÷', true, 'division sign'], + ['⁄', '⁄', true, 'fraction slash'], + ['×', '×', true, 'multiplication sign'], + ['¹', '¹', true, 'superscript one'], + ['²', '²', true, 'superscript two'], + ['³', '³', true, 'superscript three'], + ['¼', '¼', true, 'fraction one quarter'], + ['½', '½', true, 'fraction one half'], + ['¾', '¾', true, 'fraction three quarters'], +// math / logical + ['ƒ', 'ƒ', true, 'function / florin'], + ['∫', '∫', true, 'integral'], + ['∑', '∑', true, 'n-ary sumation'], + ['∞', '∞', true, 'infinity'], + ['√', '√', true, 'square root'], + ['∼', '∼', false,'similar to'], + ['≅', '≅', false,'approximately equal to'], + ['≈', '≈', true, 'almost equal to'], + ['≠', '≠', true, 'not equal to'], + ['≡', '≡', true, 'identical to'], + ['∈', '∈', false,'element of'], + ['∉', '∉', false,'not an element of'], + ['∋', '∋', false,'contains as member'], + ['∏', '∏', true, 'n-ary product'], + ['∧', '∧', false,'logical and'], + ['∨', '∨', false,'logical or'], + ['¬', '¬', true, 'not sign'], + ['∩', '∩', true, 'intersection'], + ['∪', '∪', false,'union'], + ['∂', '∂', true, 'partial differential'], + ['∀', '∀', false,'for all'], + ['∃', '∃', false,'there exists'], + ['∅', '∅', false,'diameter'], + ['∇', '∇', false,'backward difference'], + ['∗', '∗', false,'asterisk operator'], + ['∝', '∝', false,'proportional to'], + ['∠', '∠', false,'angle'], +// undefined + ['´', '´', true, 'acute accent'], + ['¸', '¸', true, 'cedilla'], + ['ª', 'ª', true, 'feminine ordinal indicator'], + ['º', 'º', true, 'masculine ordinal indicator'], + ['†', '†', true, 'dagger'], + ['‡', '‡', true, 'double dagger'], +// alphabetical special chars + ['À', 'À', true, 'A - grave'], + ['Á', 'Á', true, 'A - acute'], + ['Â', 'Â', true, 'A - circumflex'], + ['Ã', 'Ã', true, 'A - tilde'], + ['Ä', 'Ä', true, 'A - diaeresis'], + ['Å', 'Å', true, 'A - ring above'], + ['Æ', 'Æ', true, 'ligature AE'], + ['Ç', 'Ç', true, 'C - cedilla'], + ['È', 'È', true, 'E - grave'], + ['É', 'É', true, 'E - acute'], + ['Ê', 'Ê', true, 'E - circumflex'], + ['Ë', 'Ë', true, 'E - diaeresis'], + ['Ì', 'Ì', true, 'I - grave'], + ['Í', 'Í', true, 'I - acute'], + ['Î', 'Î', true, 'I - circumflex'], + ['Ï', 'Ï', true, 'I - diaeresis'], + ['Ð', 'Ð', true, 'ETH'], + ['Ñ', 'Ñ', true, 'N - tilde'], + ['Ò', 'Ò', true, 'O - grave'], + ['Ó', 'Ó', true, 'O - acute'], + ['Ô', 'Ô', true, 'O - circumflex'], + ['Õ', 'Õ', true, 'O - tilde'], + ['Ö', 'Ö', true, 'O - diaeresis'], + ['Ø', 'Ø', true, 'O - slash'], + ['Œ', 'Œ', true, 'ligature OE'], + ['Š', 'Š', true, 'S - caron'], + ['Ù', 'Ù', true, 'U - grave'], + ['Ú', 'Ú', true, 'U - acute'], + ['Û', 'Û', true, 'U - circumflex'], + ['Ü', 'Ü', true, 'U - diaeresis'], + ['Ý', 'Ý', true, 'Y - acute'], + ['Ÿ', 'Ÿ', true, 'Y - diaeresis'], + ['Þ', 'Þ', true, 'THORN'], + ['à', 'à', true, 'a - grave'], + ['á', 'á', true, 'a - acute'], + ['â', 'â', true, 'a - circumflex'], + ['ã', 'ã', true, 'a - tilde'], + ['ä', 'ä', true, 'a - diaeresis'], + ['å', 'å', true, 'a - ring above'], + ['æ', 'æ', true, 'ligature ae'], + ['ç', 'ç', true, 'c - cedilla'], + ['è', 'è', true, 'e - grave'], + ['é', 'é', true, 'e - acute'], + ['ê', 'ê', true, 'e - circumflex'], + ['ë', 'ë', true, 'e - diaeresis'], + ['ì', 'ì', true, 'i - grave'], + ['í', 'í', true, 'i - acute'], + ['î', 'î', true, 'i - circumflex'], + ['ï', 'ï', true, 'i - diaeresis'], + ['ð', 'ð', true, 'eth'], + ['ñ', 'ñ', true, 'n - tilde'], + ['ò', 'ò', true, 'o - grave'], + ['ó', 'ó', true, 'o - acute'], + ['ô', 'ô', true, 'o - circumflex'], + ['õ', 'õ', true, 'o - tilde'], + ['ö', 'ö', true, 'o - diaeresis'], + ['ø', 'ø', true, 'o slash'], + ['œ', 'œ', true, 'ligature oe'], + ['š', 'š', true, 's - caron'], + ['ù', 'ù', true, 'u - grave'], + ['ú', 'ú', true, 'u - acute'], + ['û', 'û', true, 'u - circumflex'], + ['ü', 'ü', true, 'u - diaeresis'], + ['ý', 'ý', true, 'y - acute'], + ['þ', 'þ', true, 'thorn'], + ['ÿ', 'ÿ', true, 'y - diaeresis'], +// ['Α', 'Α', true, 'Alpha'], + ['Β', 'Β', true, 'Beta'], + ['Γ', 'Γ', true, 'Gamma'], + ['Δ', 'Δ', true, 'Delta'], + ['Ε', 'Ε', true, 'Epsilon'], + ['Ζ', 'Ζ', true, 'Zeta'], + ['Η', 'Η', true, 'Eta'], + ['Θ', 'Θ', true, 'Theta'], + ['Ι', 'Ι', true, 'Iota'], + ['Κ', 'Κ', true, 'Kappa'], + ['Λ', 'Λ', true, 'Lambda'], + ['Μ', 'Μ', true, 'Mu'], + ['Ν', 'Ν', true, 'Nu'], + ['Ξ', 'Ξ', true, 'Xi'], + ['Ο', 'Ο', true, 'Omicron'], + ['Π', 'Π', true, 'Pi'], + ['Ρ', 'Ρ', true, 'Rho'], + ['Σ', 'Σ', true, 'Sigma'], + ['Τ', 'Τ', true, 'Tau'], + ['Υ', 'Υ', true, 'Upsilon'], + ['Φ', 'Φ', true, 'Phi'], + ['Χ', 'Χ', true, 'Chi'], + ['Ψ', 'Ψ', true, 'Psi'], + ['Ω', 'Ω', true, 'Omega'], + ['α', 'α', true, 'alpha'], + ['β', 'β', true, 'beta'], + ['γ', 'γ', true, 'gamma'], + ['δ', 'δ', true, 'delta'], + ['ε', 'ε', true, 'epsilon'], + ['ζ', 'ζ', true, 'zeta'], + ['η', 'η', true, 'eta'], + ['θ', 'θ', true, 'theta'], + ['ι', 'ι', true, 'iota'], + ['κ', 'κ', true, 'kappa'], + ['λ', 'λ', true, 'lambda'], + ['μ', 'μ', true, 'mu'], + ['ν', 'ν', true, 'nu'], + ['ξ', 'ξ', true, 'xi'], + ['ο', 'ο', true, 'omicron'], + ['π', 'π', true, 'pi'], + ['ρ', 'ρ', true, 'rho'], + ['ς', 'ς', true, 'final sigma'], + ['σ', 'σ', true, 'sigma'], + ['τ', 'τ', true, 'tau'], + ['υ', 'υ', true, 'upsilon'], + ['φ', 'φ', true, 'phi'], + ['χ', 'χ', true, 'chi'], + ['ψ', 'ψ', true, 'psi'], + ['ω', 'ω', true, 'omega'], +// symbols + ['ℵ', 'ℵ', false,'alef symbol'], + ['ϖ', 'ϖ', false,'pi symbol'], + ['ℜ', 'ℜ', false,'real part symbol'], + ['ϑ','ϑ', false,'theta symbol'], + ['ϒ', 'ϒ', false,'upsilon - hook symbol'], + ['℘', '℘', false,'Weierstrass p'], + ['ℑ', 'ℑ', false,'imaginary part'], +// arrows + ['←', '←', true, 'leftwards arrow'], + ['↑', '↑', true, 'upwards arrow'], + ['→', '→', true, 'rightwards arrow'], + ['↓', '↓', true, 'downwards arrow'], + ['↔', '↔', true, 'left right arrow'], + ['↵', '↵', false,'carriage return'], + ['⇐', '⇐', false,'leftwards double arrow'], + ['⇑', '⇑', false,'upwards double arrow'], + ['⇒', '⇒', false,'rightwards double arrow'], + ['⇓', '⇓', false,'downwards double arrow'], + ['⇔', '⇔', false,'left right double arrow'], + ['∴', '∴', false,'therefore'], + ['⊂', '⊂', false,'subset of'], + ['⊃', '⊃', false,'superset of'], + ['⊄', '⊄', false,'not a subset of'], + ['⊆', '⊆', false,'subset of or equal to'], + ['⊇', '⊇', false,'superset of or equal to'], + ['⊕', '⊕', false,'circled plus'], + ['⊗', '⊗', false,'circled times'], + ['⊥', '⊥', false,'perpendicular'], + ['⋅', '⋅', false,'dot operator'], + ['⌈', '⌈', false,'left ceiling'], + ['⌉', '⌉', false,'right ceiling'], + ['⌊', '⌊', false,'left floor'], + ['⌋', '⌋', false,'right floor'], + ['⟨', '〈', false,'left-pointing angle bracket'], + ['⟩', '〉', false,'right-pointing angle bracket'], + ['◊', '◊', true,'lozenge'], + ['♠', '♠', false,'black spade suit'], + ['♣', '♣', true, 'black club suit'], + ['♥', '♥', true, 'black heart suit'], + ['♦', '♦', true, 'black diamond suit'], + [' ', ' ', false,'en space'], + [' ', ' ', false,'em space'], + [' ', ' ', false,'thin space'], + ['‌', '‌', false,'zero width non-joiner'], + ['‍', '‍', false,'zero width joiner'], + ['‎', '‎', false,'left-to-right mark'], + ['‏', '‏', false,'right-to-left mark'], + ['­', '­', false,'soft hyphen'] +]; + +function renderCharMapHTML() { + var charsPerRow = 20, tdWidth=20, tdHeight=20; + var html = '<table border="0" cellspacing="1" cellpadding="0" width="' + (tdWidth*charsPerRow) + '"><tr height="' + tdHeight + '">'; + var cols=-1; + for (var i=0; i<charmap.length; i++) { + if (charmap[i][2]==true) { + cols++; + html += '' + + '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"' + + ' onmouseover="tinyMCE.switchClass(this,\'charmapOver\');' + + 'previewChar(\'' + charmap[i][1].substring(1,charmap[i][1].length) + '\',\'' + charmap[i][0].substring(1,charmap[i][0].length) + '\',\'' + charmap[i][3] + '\');"' + + ' onmouseout="tinyMCE.restoreClass(this,\'charmapOver\');"' + + ' nowrap="nowrap" onclick="insertChar(\'' + charmap[i][1].substring(2,charmap[i][1].length-1) + '\');"><a style="text-decoration: none;" onfocus="previewChar(\'' + charmap[i][1].substring(1,charmap[i][1].length) + '\',\'' + charmap[i][0].substring(1,charmap[i][0].length) + '\',\'' + charmap[i][3] + '\');" href="javascript:insertChar(\'' + charmap[i][1].substring(2,charmap[i][1].length-1) + '\');" onclick="return false;" onmousedown="return false;" title="' + charmap[i][3] + '">' + + charmap[i][1] + + '</a></td>'; + if ((cols+1) % charsPerRow == 0) + html += '</tr><tr height="' + tdHeight + '">'; + } + } + if (cols % charsPerRow > 0) { + var padd = charsPerRow - (cols % charsPerRow); + for (var i=0; i<padd-1; i++) + html += '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"> </td>'; + } + html += '</tr></table>'; + document.write(html); +} + +function insertChar(chr) { + tinyMCEPopup.execCommand('mceInsertContent', false, '\&#' + chr + ';'); + + // Refocus in window + if (tinyMCEPopup.isWindow) + window.focus(); +} + +function previewChar(codeA, codeB, codeN) { + var elmA = document.getElementById('codeA'); + var elmB = document.getElementById('codeB'); + var elmV = document.getElementById('codeV'); + var elmN = document.getElementById('codeN'); + + if (codeA=='#160;') { + elmV.innerHTML = '__'; + } else { + elmV.innerHTML = '&' + codeA; + } + + elmB.innerHTML = '&' + codeA; + elmA.innerHTML = '&' + codeB; + elmN.innerHTML = codeN; +} diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/color_picker.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/color_picker.js index aab668e..1d585aa 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/color_picker.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/color_picker.js @@ -1,107 +1,107 @@ -function init() {
- if (tinyMCE.isMSIE)
- tinyMCEPopup.resizeToInnerSize();
-}
-
-function selectColor() {
- var color = document.getElementById("selectedColorBox").value;
-
- tinyMCEPopup.execCommand(tinyMCE.getWindowArg('command'), false, color);
- tinyMCEPopup.close();
-}
-
-function showColor(color) {
- document.getElementById("selectedColor").style.backgroundColor = color;
- document.getElementById("selectedColorBox").value = color;
-}
-
-var colors = new Array(
- "#000000","#000033","#000066","#000099","#0000cc","#0000ff","#330000","#330033",
- "#330066","#330099","#3300cc","#3300ff","#660000","#660033","#660066","#660099",
- "#6600cc","#6600ff","#990000","#990033","#990066","#990099","#9900cc","#9900ff",
- "#cc0000","#cc0033","#cc0066","#cc0099","#cc00cc","#cc00ff","#ff0000","#ff0033",
- "#ff0066","#ff0099","#ff00cc","#ff00ff","#003300","#003333","#003366","#003399",
- "#0033cc","#0033ff","#333300","#333333","#333366","#333399","#3333cc","#3333ff",
- "#663300","#663333","#663366","#663399","#6633cc","#6633ff","#993300","#993333",
- "#993366","#993399","#9933cc","#9933ff","#cc3300","#cc3333","#cc3366","#cc3399",
- "#cc33cc","#cc33ff","#ff3300","#ff3333","#ff3366","#ff3399","#ff33cc","#ff33ff",
- "#006600","#006633","#006666","#006699","#0066cc","#0066ff","#336600","#336633",
- "#336666","#336699","#3366cc","#3366ff","#666600","#666633","#666666","#666699",
- "#6666cc","#6666ff","#996600","#996633","#996666","#996699","#9966cc","#9966ff",
- "#cc6600","#cc6633","#cc6666","#cc6699","#cc66cc","#cc66ff","#ff6600","#ff6633",
- "#ff6666","#ff6699","#ff66cc","#ff66ff","#009900","#009933","#009966","#009999",
- "#0099cc","#0099ff","#339900","#339933","#339966","#339999","#3399cc","#3399ff",
- "#669900","#669933","#669966","#669999","#6699cc","#6699ff","#999900","#999933",
- "#999966","#999999","#9999cc","#9999ff","#cc9900","#cc9933","#cc9966","#cc9999",
- "#cc99cc","#cc99ff","#ff9900","#ff9933","#ff9966","#ff9999","#ff99cc","#ff99ff",
- "#00cc00","#00cc33","#00cc66","#00cc99","#00cccc","#00ccff","#33cc00","#33cc33",
- "#33cc66","#33cc99","#33cccc","#33ccff","#66cc00","#66cc33","#66cc66","#66cc99",
- "#66cccc","#66ccff","#99cc00","#99cc33","#99cc66","#99cc99","#99cccc","#99ccff",
- "#cccc00","#cccc33","#cccc66","#cccc99","#cccccc","#ccccff","#ffcc00","#ffcc33",
- "#ffcc66","#ffcc99","#ffcccc","#ffccff","#00ff00","#00ff33","#00ff66","#00ff99",
- "#00ffcc","#00ffff","#33ff00","#33ff33","#33ff66","#33ff99","#33ffcc","#33ffff",
- "#66ff00","#66ff33","#66ff66","#66ff99","#66ffcc","#66ffff","#99ff00","#99ff33",
- "#99ff66","#99ff99","#99ffcc","#99ffff","#ccff00","#ccff33","#ccff66","#ccff99",
- "#ccffcc","#ccffff","#ffff00","#ffff33","#ffff66","#ffff99","#ffffcc","#ffffff"
-);
-
-function convertRGBToHex(col) {
- var re = new RegExp("rgb\\s*\\(\\s*([0-9]+).*,\\s*([0-9]+).*,\\s*([0-9]+).*\\)", "gi");
-
- var rgb = col.replace(re, "$1,$2,$3").split(',');
- if (rgb.length == 3) {
- r = parseInt(rgb[0]).toString(16);
- g = parseInt(rgb[1]).toString(16);
- b = parseInt(rgb[2]).toString(16);
-
- r = r.length == 1 ? '0' + r : r;
- g = g.length == 1 ? '0' + g : g;
- b = b.length == 1 ? '0' + b : b;
-
- return "#" + r + g + b;
- }
-
- return col;
-}
-
-function convertHexToRGB(col) {
- if (col.indexOf('#') != -1) {
- col = col.replace(new RegExp('[^0-9A-F]', 'gi'), '');
-
- r = parseInt(col.substring(0, 2), 16);
- g = parseInt(col.substring(2, 4), 16);
- b = parseInt(col.substring(4, 6), 16);
-
- return "rgb(" + r + "," + g + "," + b + ")";
- }
-
- return col;
-}
-
-function renderColorMap() {
- var html = "";
- var inputColor = convertRGBToHex(tinyMCE.getWindowArg('input_color'));
-
- html += '<table border="0" cellspacing="1" cellpadding="0">'
- + '<tr>';
- for (var i=0; i<colors.length; i++) {
- html += '<td bgcolor="' + colors[i] + '">'
- + '<a href="javascript:selectColor();" onfocus="showColor(\'' + colors[i] + '\');" onmouseover="showColor(\'' + colors[i] + '\');">'
- + '<img border="0" src="images/spacer.gif" width="10" height="10" title="' + colors[i] + '" alt="' + colors[i] + '" /></a></td>';
- if ((i+1) % 18 == 0)
- html += '</tr><tr>';
- }
- html += '<tr><td colspan="18">'
- + '<table width="100%" border="0" cellspacing="0" cellpadding="0">'
- + '<tr><td>'
- + '<img id="selectedColor" style="background-color:' + tinyMCE.getWindowArg('input_color') + '" border="0" src="images/spacer.gif" width="80" height="16" />'
- + '</td><td align="right">'
- + '<input id="selectedColorBox" name="selectedColorBox" type="text" size="7" maxlength="7" style="width:65px" value="' + inputColor + '" />'
- + '</td></tr>'
- + '</table>'
- + '<input type="button" id="insert" name="insert" value="{$lang_theme_colorpicker_apply}" style="margin-top:3px" onclick="selectColor();">'
- + '</td></tr>'
- + '</table>';
-
- document.write(html);
+function init() { + if (tinyMCE.isMSIE) + tinyMCEPopup.resizeToInnerSize(); +} + +function selectColor() { + var color = document.getElementById("selectedColorBox").value; + + tinyMCEPopup.execCommand(tinyMCE.getWindowArg('command'), false, color); + tinyMCEPopup.close(); +} + +function showColor(color) { + document.getElementById("selectedColor").style.backgroundColor = color; + document.getElementById("selectedColorBox").value = color; +} + +var colors = new Array( + "#000000","#000033","#000066","#000099","#0000cc","#0000ff","#330000","#330033", + "#330066","#330099","#3300cc","#3300ff","#660000","#660033","#660066","#660099", + "#6600cc","#6600ff","#990000","#990033","#990066","#990099","#9900cc","#9900ff", + "#cc0000","#cc0033","#cc0066","#cc0099","#cc00cc","#cc00ff","#ff0000","#ff0033", + "#ff0066","#ff0099","#ff00cc","#ff00ff","#003300","#003333","#003366","#003399", + "#0033cc","#0033ff","#333300","#333333","#333366","#333399","#3333cc","#3333ff", + "#663300","#663333","#663366","#663399","#6633cc","#6633ff","#993300","#993333", + "#993366","#993399","#9933cc","#9933ff","#cc3300","#cc3333","#cc3366","#cc3399", + "#cc33cc","#cc33ff","#ff3300","#ff3333","#ff3366","#ff3399","#ff33cc","#ff33ff", + "#006600","#006633","#006666","#006699","#0066cc","#0066ff","#336600","#336633", + "#336666","#336699","#3366cc","#3366ff","#666600","#666633","#666666","#666699", + "#6666cc","#6666ff","#996600","#996633","#996666","#996699","#9966cc","#9966ff", + "#cc6600","#cc6633","#cc6666","#cc6699","#cc66cc","#cc66ff","#ff6600","#ff6633", + "#ff6666","#ff6699","#ff66cc","#ff66ff","#009900","#009933","#009966","#009999", + "#0099cc","#0099ff","#339900","#339933","#339966","#339999","#3399cc","#3399ff", + "#669900","#669933","#669966","#669999","#6699cc","#6699ff","#999900","#999933", + "#999966","#999999","#9999cc","#9999ff","#cc9900","#cc9933","#cc9966","#cc9999", + "#cc99cc","#cc99ff","#ff9900","#ff9933","#ff9966","#ff9999","#ff99cc","#ff99ff", + "#00cc00","#00cc33","#00cc66","#00cc99","#00cccc","#00ccff","#33cc00","#33cc33", + "#33cc66","#33cc99","#33cccc","#33ccff","#66cc00","#66cc33","#66cc66","#66cc99", + "#66cccc","#66ccff","#99cc00","#99cc33","#99cc66","#99cc99","#99cccc","#99ccff", + "#cccc00","#cccc33","#cccc66","#cccc99","#cccccc","#ccccff","#ffcc00","#ffcc33", + "#ffcc66","#ffcc99","#ffcccc","#ffccff","#00ff00","#00ff33","#00ff66","#00ff99", + "#00ffcc","#00ffff","#33ff00","#33ff33","#33ff66","#33ff99","#33ffcc","#33ffff", + "#66ff00","#66ff33","#66ff66","#66ff99","#66ffcc","#66ffff","#99ff00","#99ff33", + "#99ff66","#99ff99","#99ffcc","#99ffff","#ccff00","#ccff33","#ccff66","#ccff99", + "#ccffcc","#ccffff","#ffff00","#ffff33","#ffff66","#ffff99","#ffffcc","#ffffff" +); + +function convertRGBToHex(col) { + var re = new RegExp("rgb\\s*\\(\\s*([0-9]+).*,\\s*([0-9]+).*,\\s*([0-9]+).*\\)", "gi"); + + var rgb = col.replace(re, "$1,$2,$3").split(','); + if (rgb.length == 3) { + r = parseInt(rgb[0]).toString(16); + g = parseInt(rgb[1]).toString(16); + b = parseInt(rgb[2]).toString(16); + + r = r.length == 1 ? '0' + r : r; + g = g.length == 1 ? '0' + g : g; + b = b.length == 1 ? '0' + b : b; + + return "#" + r + g + b; + } + + return col; +} + +function convertHexToRGB(col) { + if (col.indexOf('#') != -1) { + col = col.replace(new RegExp('[^0-9A-F]', 'gi'), ''); + + r = parseInt(col.substring(0, 2), 16); + g = parseInt(col.substring(2, 4), 16); + b = parseInt(col.substring(4, 6), 16); + + return "rgb(" + r + "," + g + "," + b + ")"; + } + + return col; +} + +function renderColorMap() { + var html = ""; + var inputColor = convertRGBToHex(tinyMCE.getWindowArg('input_color')); + + html += '<table border="0" cellspacing="1" cellpadding="0">' + + '<tr>'; + for (var i=0; i<colors.length; i++) { + html += '<td bgcolor="' + colors[i] + '">' + + '<a href="javascript:selectColor();" onfocus="showColor(\'' + colors[i] + '\');" onmouseover="showColor(\'' + colors[i] + '\');">' + + '<img border="0" src="images/spacer.gif" width="10" height="10" title="' + colors[i] + '" alt="' + colors[i] + '" /></a></td>'; + if ((i+1) % 18 == 0) + html += '</tr><tr>'; + } + html += '<tr><td colspan="18">' + + '<table width="100%" border="0" cellspacing="0" cellpadding="0">' + + '<tr><td>' + + '<img id="selectedColor" style="background-color:' + tinyMCE.getWindowArg('input_color') + '" border="0" src="images/spacer.gif" width="80" height="16" />' + + '</td><td align="right">' + + '<input id="selectedColorBox" name="selectedColorBox" type="text" size="7" maxlength="7" style="width:65px" value="' + inputColor + '" />' + + '</td></tr>' + + '</table>' + + '<input type="button" id="insert" name="insert" value="{$lang_theme_colorpicker_apply}" style="margin-top:3px" onclick="selectColor();">' + + '</td></tr>' + + '</table>'; + + document.write(html); }
\ No newline at end of file diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/image.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/image.js index 894a0ff..537d713 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/image.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/image.js @@ -1,82 +1,82 @@ -var url = tinyMCE.getParam("external_image_list_url");
-if (url != null) {
- // Fix relative
- if (url.charAt(0) != '/' && url.indexOf('://') == -1)
- url = tinyMCE.documentBasePath + "/" + url;
-
- document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '"></sc'+'ript>');
-}
-
-function insertImage() {
- if (window.opener) {
- var src = document.forms[0].src.value;
- var alt = document.forms[0].alt.value;
- var border = document.forms[0].border.value;
- var vspace = document.forms[0].vspace.value;
- var hspace = document.forms[0].hspace.value;
- var width = document.forms[0].width.value;
- var height = document.forms[0].height.value;
- var align = document.forms[0].align.options[document.forms[0].align.selectedIndex].value;
-
- window.opener.tinyMCE.insertImage(src, alt, border, hspace, vspace, width, height, align);
- top.close();
- }
-}
-
-function init() {
- tinyMCEPopup.resizeToInnerSize();
-
- document.getElementById('srcbrowsercontainer').innerHTML = getBrowserHTML('srcbrowser','src','image','theme_advanced_image');
-
- var formObj = document.forms[0];
-
- for (var i=0; i<document.forms[0].align.options.length; i++) {
- if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align'))
- document.forms[0].align.options.selectedIndex = i;
- }
-
- formObj.src.value = tinyMCE.getWindowArg('src');
- formObj.alt.value = tinyMCE.getWindowArg('alt');
- formObj.border.value = tinyMCE.getWindowArg('border');
- formObj.vspace.value = tinyMCE.getWindowArg('vspace');
- formObj.hspace.value = tinyMCE.getWindowArg('hspace');
- formObj.width.value = tinyMCE.getWindowArg('width');
- formObj.height.value = tinyMCE.getWindowArg('height');
- formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
-
- // Handle file browser
- if (isVisible('srcbrowser'))
- document.getElementById('src').style.width = '180px';
-
- // Auto select image in list
- if (typeof(tinyMCEImageList) != "undefined" && tinyMCEImageList.length > 0) {
- for (var i=0; i<formObj.image_list.length; i++) {
- if (formObj.image_list.options[i].value == tinyMCE.getWindowArg('src'))
- formObj.image_list.options[i].selected = true;
- }
- }
-}
-
-var preloadImg = new Image();
-
-function resetImageData() {
- var formObj = document.forms[0];
- formObj.width.value = formObj.height.value = "";
-}
-
-function updateImageData() {
- var formObj = document.forms[0];
-
- if (formObj.width.value == "")
- formObj.width.value = preloadImg.width;
-
- if (formObj.height.value == "")
- formObj.height.value = preloadImg.height;
-}
-
-function getImageData() {
- preloadImg = new Image();
- tinyMCE.addEvent(preloadImg, "load", updateImageData);
- tinyMCE.addEvent(preloadImg, "error", function () {var formObj = document.forms[0];formObj.width.value = formObj.height.value = "";});
- preloadImg.src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], document.forms[0].src.value);
-}
+var url = tinyMCE.getParam("external_image_list_url"); +if (url != null) { + // Fix relative + if (url.charAt(0) != '/' && url.indexOf('://') == -1) + url = tinyMCE.documentBasePath + "/" + url; + + document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '"></sc'+'ript>'); +} + +function insertImage() { + if (window.opener) { + var src = document.forms[0].src.value; + var alt = document.forms[0].alt.value; + var border = document.forms[0].border.value; + var vspace = document.forms[0].vspace.value; + var hspace = document.forms[0].hspace.value; + var width = document.forms[0].width.value; + var height = document.forms[0].height.value; + var align = document.forms[0].align.options[document.forms[0].align.selectedIndex].value; + + window.opener.tinyMCE.insertImage(src, alt, border, hspace, vspace, width, height, align); + top.close(); + } +} + +function init() { + tinyMCEPopup.resizeToInnerSize(); + + document.getElementById('srcbrowsercontainer').innerHTML = getBrowserHTML('srcbrowser','src','image','theme_advanced_image'); + + var formObj = document.forms[0]; + + for (var i=0; i<document.forms[0].align.options.length; i++) { + if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align')) + document.forms[0].align.options.selectedIndex = i; + } + + formObj.src.value = tinyMCE.getWindowArg('src'); + formObj.alt.value = tinyMCE.getWindowArg('alt'); + formObj.border.value = tinyMCE.getWindowArg('border'); + formObj.vspace.value = tinyMCE.getWindowArg('vspace'); + formObj.hspace.value = tinyMCE.getWindowArg('hspace'); + formObj.width.value = tinyMCE.getWindowArg('width'); + formObj.height.value = tinyMCE.getWindowArg('height'); + formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true); + + // Handle file browser + if (isVisible('srcbrowser')) + document.getElementById('src').style.width = '180px'; + + // Auto select image in list + if (typeof(tinyMCEImageList) != "undefined" && tinyMCEImageList.length > 0) { + for (var i=0; i<formObj.image_list.length; i++) { + if (formObj.image_list.options[i].value == tinyMCE.getWindowArg('src')) + formObj.image_list.options[i].selected = true; + } + } +} + +var preloadImg = new Image(); + +function resetImageData() { + var formObj = document.forms[0]; + formObj.width.value = formObj.height.value = ""; +} + +function updateImageData() { + var formObj = document.forms[0]; + + if (formObj.width.value == "") + formObj.width.value = preloadImg.width; + + if (formObj.height.value == "") + formObj.height.value = preloadImg.height; +} + +function getImageData() { + preloadImg = new Image(); + tinyMCE.addEvent(preloadImg, "load", updateImageData); + tinyMCE.addEvent(preloadImg, "error", function () {var formObj = document.forms[0];formObj.width.value = formObj.height.value = "";}); + preloadImg.src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], document.forms[0].src.value); +} diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/link.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/link.js index e23d392..c687844 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/link.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/link.js @@ -1,64 +1,64 @@ -var url = tinyMCE.getParam("external_link_list_url");
-if (url != null) {
- // Fix relative
- if (url.charAt(0) != '/' && url.indexOf('://') == -1)
- url = tinyMCE.documentBasePath + "/" + url;
-
- document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '"></sc'+'ript>');
-}
-
-function init() {
- tinyMCEPopup.resizeToInnerSize();
-
- document.getElementById('hrefbrowsercontainer').innerHTML = getBrowserHTML('hrefbrowser','href','file','theme_advanced_link');
-
- var formObj = document.forms[0];
-
- for (var i=0; i<document.forms[0].target.options.length; i++) {
- var option = document.forms[0].target.options[i];
-
- if (option.value == tinyMCE.getWindowArg('target'))
- option.selected = true;
- }
-
- document.forms[0].href.value = tinyMCE.getWindowArg('href');
- document.forms[0].linktitle.value = tinyMCE.getWindowArg('title');
- document.forms[0].insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
-
- addClassesToList('styleSelect', 'theme_advanced_link_styles');
- selectByValue(formObj, 'styleSelect', tinyMCE.getWindowArg('className'), true);
-
- // Handle file browser
- if (isVisible('hrefbrowser'))
- document.getElementById('href').style.width = '180px';
-
- // Auto select link in list
- if (typeof(tinyMCELinkList) != "undefined" && tinyMCELinkList.length > 0) {
- var formObj = document.forms[0];
-
- for (var i=0; i<formObj.link_list.length; i++) {
- if (formObj.link_list.options[i].value == tinyMCE.getWindowArg('href'))
- formObj.link_list.options[i].selected = true;
- }
- }
-}
-
-function insertLink() {
- if (window.opener) {
- var href = document.forms[0].href.value;
- var target = document.forms[0].target.options[document.forms[0].target.selectedIndex].value;
- var title = document.forms[0].linktitle.value;
- var style_class = document.forms[0].styleSelect.value;
- var dummy;
-
- // Make anchors absolute
- if (href.charAt(0) == '#')
- href = tinyMCE.settings['document_base_url'] + href;
-
- if (target == '_self')
- target = '';
-
- window.opener.tinyMCE.insertLink(href, target, title, dummy, style_class);
- tinyMCEPopup.close();
- }
-}
+var url = tinyMCE.getParam("external_link_list_url"); +if (url != null) { + // Fix relative + if (url.charAt(0) != '/' && url.indexOf('://') == -1) + url = tinyMCE.documentBasePath + "/" + url; + + document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '"></sc'+'ript>'); +} + +function init() { + tinyMCEPopup.resizeToInnerSize(); + + document.getElementById('hrefbrowsercontainer').innerHTML = getBrowserHTML('hrefbrowser','href','file','theme_advanced_link'); + + var formObj = document.forms[0]; + + for (var i=0; i<document.forms[0].target.options.length; i++) { + var option = document.forms[0].target.options[i]; + + if (option.value == tinyMCE.getWindowArg('target')) + option.selected = true; + } + + document.forms[0].href.value = tinyMCE.getWindowArg('href'); + document.forms[0].linktitle.value = tinyMCE.getWindowArg('title'); + document.forms[0].insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true); + + addClassesToList('styleSelect', 'theme_advanced_link_styles'); + selectByValue(formObj, 'styleSelect', tinyMCE.getWindowArg('className'), true); + + // Handle file browser + if (isVisible('hrefbrowser')) + document.getElementById('href').style.width = '180px'; + + // Auto select link in list + if (typeof(tinyMCELinkList) != "undefined" && tinyMCELinkList.length > 0) { + var formObj = document.forms[0]; + + for (var i=0; i<formObj.link_list.length; i++) { + if (formObj.link_list.options[i].value == tinyMCE.getWindowArg('href')) + formObj.link_list.options[i].selected = true; + } + } +} + +function insertLink() { + if (window.opener) { + var href = document.forms[0].href.value; + var target = document.forms[0].target.options[document.forms[0].target.selectedIndex].value; + var title = document.forms[0].linktitle.value; + var style_class = document.forms[0].styleSelect.value; + var dummy; + + // Make anchors absolute + if (href.charAt(0) == '#') + href = tinyMCE.settings['document_base_url'] + href; + + if (target == '_self') + target = ''; + + window.opener.tinyMCE.insertLink(href, target, title, dummy, style_class); + tinyMCEPopup.close(); + } +} diff --git a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js index bfbee3f..9dda809 100644 --- a/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js +++ b/wp-inst/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js @@ -1,53 +1,53 @@ -function saveContent() {
- tinyMCE.setContent(document.getElementById('htmlSource').value);
- tinyMCE.closeWindow(window);
-}
-
-// Fixes some charcode issues
-function fixContent(html) {
- html = html.replace(new RegExp('<(p|hr|table|tr|td|ol|ul|object|embed|li|blockquote)', 'gi'),'\n<$1');
- html = html.replace(new RegExp('<\/(p|ol|ul|li|table|tr|td|blockquote|object)>', 'gi'),'</$1>\n');
- html = tinyMCE.regexpReplace(html, '<br />','<br />\n','gi');
- html = tinyMCE.regexpReplace(html, '\n\n','\n','gi');
- return html;
-}
-
-function onLoadInit() {
- tinyMCEPopup.resizeToInnerSize();
-
- document.forms[0].htmlSource.value = fixContent(tinyMCE.getContent(tinyMCE.getWindowArg('editor_id')));
- resizeInputs();
- setWrap('off');
-}
-
-function setWrap(val) {
- // hard soft off
- document.forms[0].htmlSource.wrap = val;
-}
-
-function toggleWordWrap(elm) {
- if (elm.checked)
- setWrap('soft');
- else
- setWrap('off');
-}
-
-var wHeight=0, wWidth=0, owHeight=0, owWidth=0;
-
-function resizeInputs() {
- if (!tinyMCE.isMSIE) {
- wHeight = self.innerHeight-80;
- wWidth = self.innerWidth-16;
- } else {
- wHeight = document.body.clientHeight - 80;
- wWidth = document.body.clientWidth - 16;
- }
-
- document.forms[0].htmlSource.style.height = Math.abs(wHeight) + 'px';
- document.forms[0].htmlSource.style.width = Math.abs(wWidth) + 'px';
-}
-
-function renderWordWrap() {
- if (tinyMCE.isMSIE)
- document.write('<input type="checkbox" name="wraped" id="wraped" onclick="toggleWordWrap(this);" class="wordWrapCode" /><label for="wraped">{$lang_theme_code_wordwrap}</label>');
-}
+function saveContent() { + tinyMCE.setContent(document.getElementById('htmlSource').value); + tinyMCE.closeWindow(window); +} + +// Fixes some charcode issues +function fixContent(html) { + html = html.replace(new RegExp('<(p|hr|table|tr|td|ol|ul|object|embed|li|blockquote)', 'gi'),'\n<$1'); + html = html.replace(new RegExp('<\/(p|ol|ul|li|table|tr|td|blockquote|object)>', 'gi'),'</$1>\n'); + html = tinyMCE.regexpReplace(html, '<br />','<br />\n','gi'); + html = tinyMCE.regexpReplace(html, '\n\n','\n','gi'); + return html; +} + +function onLoadInit() { + tinyMCEPopup.resizeToInnerSize(); + + document.forms[0].htmlSource.value = fixContent(tinyMCE.getContent(tinyMCE.getWindowArg('editor_id'))); + resizeInputs(); + setWrap('off'); +} + +function setWrap(val) { + // hard soft off + document.forms[0].htmlSource.wrap = val; +} + +function toggleWordWrap(elm) { + if (elm.checked) + setWrap('soft'); + else + setWrap('off'); +} + +var wHeight=0, wWidth=0, owHeight=0, owWidth=0; + +function resizeInputs() { + if (!tinyMCE.isMSIE) { + wHeight = self.innerHeight-80; + wWidth = self.innerWidth-16; + } else { + wHeight = document.body.clientHeight - 80; + wWidth = document.body.clientWidth - 16; + } + + document.forms[0].htmlSource.style.height = Math.abs(wHeight) + 'px'; + document.forms[0].htmlSource.style.width = Math.abs(wWidth) + 'px'; +} + +function renderWordWrap() { + if (tinyMCE.isMSIE) + document.write('<input type="checkbox" name="wraped" id="wraped" onclick="toggleWordWrap(this);" class="wordWrapCode" /><label for="wraped">{$lang_theme_code_wordwrap}</label>'); +} diff --git a/wp-inst/wp-includes/pluggable-functions.php b/wp-inst/wp-includes/pluggable-functions.php index 7f211c1..606e666 100644 --- a/wp-inst/wp-includes/pluggable-functions.php +++ b/wp-inst/wp-includes/pluggable-functions.php @@ -197,6 +197,8 @@ if ( !function_exists('wp_redirect') ) : function wp_redirect($location) { global $is_IIS; + $location = str_replace( array("\n", "\r"), '', $location); + if ($is_IIS) header("Refresh: 0;url=$location"); else diff --git a/wp-inst/wp-includes/rss-functions.php b/wp-inst/wp-includes/rss-functions.php index f835926..6efe646 100644 --- a/wp-inst/wp-includes/rss-functions.php +++ b/wp-inst/wp-includes/rss-functions.php @@ -69,7 +69,7 @@ class MagpieRSS { $error_col = xml_get_current_column_number($this->parser); $errormsg = "$xml_error at line $error_line, column $error_col"; - //$this->error( $errormsg ); + $this->error( $errormsg ); } } @@ -356,9 +356,22 @@ class MagpieRSS { } } -function map_attrs($k, $v) { - return "$k=\"$v\""; + function map_attrs($k, $v) { + return "$k=\"$v\""; } + + function error( $errormsg, $lvl = E_USER_WARNING ) { + // append PHP's error message if track_errors enabled + if ( isset($php_errormsg) ) { + $errormsg .= " ($php_errormsg)"; + } + if ( MAGPIE_DEBUG ) { + trigger_error( $errormsg, $lvl); + } else { + error_log( $errormsg, 0); + } + } + } require_once( dirname(__FILE__) . '/class-snoopy.php'); diff --git a/wp-inst/wp-settings.php b/wp-inst/wp-settings.php index 7fffb14..8f0dbfa 100644 --- a/wp-inst/wp-settings.php +++ b/wp-inst/wp-settings.php @@ -38,10 +38,11 @@ if ( empty( $_SERVER['REQUEST_URI'] ) ) { if ( strpos($_SERVER['SCRIPT_FILENAME'], 'php.cgi') == strlen($_SERVER['SCRIPT_FILENAME']) - 7 ) $_SERVER['SCRIPT_FILENAME'] = $_SERVER['PATH_TRANSLATED']; -// Fix for PHP as CGI hosts that set PATH_INFO to PHP_SELF value -if ( isset($_SERVER['PATH_INFO']) && $_SERVER['PATH_INFO'] == $_SERVER['PHP_SELF'] ) +// Fix for Dreamhost and other PHP as CGI hosts +if ( strstr( $_SERVER['SCRIPT_NAME'], 'php.cgi' ) ) unset($_SERVER['PATH_INFO']); + if ( !(phpversion() >= '4.1') ) die( 'Your server is running PHP version ' . phpversion() . ' but WordPress requires at least 4.1' ); |