Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
noblogs-wp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
39
Issues
39
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
ai
noblogs-wp
Commits
0761e710
Commit
0761e710
authored
Nov 22, 2014
by
lechuck
Committed by
lucha
Oct 29, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update wordpress to 4.0.1
parent
4d189154
Changes
45
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
45 changed files
with
266 additions
and
110 deletions
+266
-110
readme.html
readme.html
+1
-1
wp-admin/about.php
wp-admin/about.php
+8
-0
wp-admin/includes/class-wp-plugin-install-list-table.php
wp-admin/includes/class-wp-plugin-install-list-table.php
+3
-1
wp-admin/includes/image.php
wp-admin/includes/image.php
+6
-0
wp-admin/includes/plugin-install.php
wp-admin/includes/plugin-install.php
+8
-3
wp-admin/includes/post.php
wp-admin/includes/post.php
+11
-5
wp-admin/js/editor-expand.js
wp-admin/js/editor-expand.js
+20
-1
wp-admin/js/editor-expand.min.js
wp-admin/js/editor-expand.min.js
+1
-1
wp-admin/js/media.js
wp-admin/js/media.js
+8
-4
wp-admin/js/media.min.js
wp-admin/js/media.min.js
+1
-1
wp-admin/plugin-install.php
wp-admin/plugin-install.php
+19
-0
wp-admin/press-this.php
wp-admin/press-this.php
+1
-1
wp-admin/upload.php
wp-admin/upload.php
+1
-1
wp-includes/canonical.php
wp-includes/canonical.php
+2
-6
wp-includes/class-phpass.php
wp-includes/class-phpass.php
+8
-0
wp-includes/css/media-views-rtl.css
wp-includes/css/media-views-rtl.css
+8
-3
wp-includes/css/media-views-rtl.min.css
wp-includes/css/media-views-rtl.min.css
+1
-1
wp-includes/css/media-views.css
wp-includes/css/media-views.css
+8
-3
wp-includes/css/media-views.min.css
wp-includes/css/media-views.min.css
+1
-1
wp-includes/formatting.php
wp-includes/formatting.php
+21
-8
wp-includes/http.php
wp-includes/http.php
+4
-4
wp-includes/js/media-grid.js
wp-includes/js/media-grid.js
+3
-2
wp-includes/js/media-grid.min.js
wp-includes/js/media-grid.min.js
+1
-1
wp-includes/js/media-views.js
wp-includes/js/media-views.js
+12
-6
wp-includes/js/media-views.min.js
wp-includes/js/media-views.min.js
+1
-1
wp-includes/js/mediaelement/flashmediaelement.swf
wp-includes/js/mediaelement/flashmediaelement.swf
+0
-0
wp-includes/js/mediaelement/mediaelement-and-player.min.js
wp-includes/js/mediaelement/mediaelement-and-player.min.js
+16
-17
wp-includes/js/quicktags.js
wp-includes/js/quicktags.js
+2
-2
wp-includes/js/quicktags.min.js
wp-includes/js/quicktags.min.js
+1
-1
wp-includes/js/tinymce/plugins/wpeditimage/plugin.js
wp-includes/js/tinymce/plugins/wpeditimage/plugin.js
+19
-3
wp-includes/js/tinymce/plugins/wpeditimage/plugin.min.js
wp-includes/js/tinymce/plugins/wpeditimage/plugin.min.js
+1
-1
wp-includes/js/tinymce/plugins/wpview/plugin.js
wp-includes/js/tinymce/plugins/wpview/plugin.js
+6
-6
wp-includes/js/tinymce/plugins/wpview/plugin.min.js
wp-includes/js/tinymce/plugins/wpview/plugin.min.js
+1
-1
wp-includes/js/tinymce/wp-tinymce.js.gz
wp-includes/js/tinymce/wp-tinymce.js.gz
+0
-0
wp-includes/kses.php
wp-includes/kses.php
+1
-1
wp-includes/link-template.php
wp-includes/link-template.php
+5
-3
wp-includes/media-template.php
wp-includes/media-template.php
+11
-9
wp-includes/media.php
wp-includes/media.php
+13
-4
wp-includes/ms-functions.php
wp-includes/ms-functions.php
+3
-1
wp-includes/pluggable.php
wp-includes/pluggable.php
+9
-3
wp-includes/post.php
wp-includes/post.php
+6
-1
wp-includes/session.php
wp-includes/session.php
+6
-1
wp-includes/user.php
wp-includes/user.php
+3
-0
wp-includes/version.php
wp-includes/version.php
+1
-1
wp-login.php
wp-login.php
+4
-0
No files found.
readme.html
View file @
0761e710
...
...
@@ -9,7 +9,7 @@
<body>
<h1
id=
"logo"
>
<a
href=
"https://wordpress.org/"
><img
alt=
"WordPress"
src=
"wp-admin/images/wordpress-logo.png"
/></a>
<br
/>
Version 4.0
<br
/>
Version 4.0
.1
</h1>
<p
style=
"text-align: center"
>
Semantic Personal Publishing Platform
</p>
...
...
wp-admin/about.php
View file @
0761e710
...
...
@@ -41,6 +41,14 @@ include( ABSPATH . 'wp-admin/admin-header.php' );
</a>
</h2>
<div
class=
"changelog point-releases"
>
<h3>
<?php
echo
_n
(
'Maintenance and Security Release'
,
'Maintenance and Security Releases'
,
1
);
?>
</h3>
<p>
<?php
printf
(
_n
(
'<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bug.'
,
'<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bugs.'
,
23
),
'4.0.1'
,
number_format_i18n
(
23
)
);
?>
<?php
printf
(
__
(
'For more information, see <a href="%s">the release notes</a>.'
),
'http://codex.wordpress.org/Version_4.0.1'
);
?>
</p>
</div>
<div
class=
"changelog"
>
<div
class=
"about-overview"
>
<?php
if
(
(
$locale
=
get_locale
()
)
&&
'en_'
===
substr
(
$locale
,
0
,
3
)
)
:
?>
...
...
wp-admin/includes/class-wp-plugin-install-list-table.php
View file @
0761e710
...
...
@@ -273,7 +273,9 @@ class WP_Plugin_Install_List_Table extends WP_List_Table {
return
;
}
if
(
'top'
==
$which
)
{
?>
if
(
'top'
==
$which
)
{
wp_referer_field
();
?>
<div
class=
"tablenav top"
>
<div
class=
"alignleft actions"
>
<?php
...
...
wp-admin/includes/image.php
View file @
0761e710
...
...
@@ -401,6 +401,12 @@ function wp_read_image_metadata( $file ) {
}
}
foreach
(
$meta
as
&
$value
)
{
if
(
is_string
(
$value
)
)
{
$value
=
wp_kses_post
(
$value
);
}
}
/**
* Filter the array of meta data read from an image's exif data.
*
...
...
wp-admin/includes/plugin-install.php
View file @
0761e710
...
...
@@ -235,10 +235,15 @@ function install_plugins_favorites_form() {
function
display_plugins_table
()
{
global
$wp_list_table
;
if
(
current_filter
()
==
'install_plugins_favorites'
&&
empty
(
$_GET
[
'user'
]
)
&&
!
get_user_option
(
'wporg_favorites'
)
)
return
;
if
(
current_filter
()
==
'install_plugins_favorites'
&&
empty
(
$_GET
[
'user'
]
)
&&
!
get_user_option
(
'wporg_favorites'
)
)
{
return
;
}
$wp_list_table
->
display
();
?>
<form
id=
"plugin-filter"
action=
""
method=
"post"
>
<?php
$wp_list_table
->
display
();
?>
</form>
<?php
}
add_action
(
'install_plugins_search'
,
'display_plugins_table'
);
add_action
(
'install_plugins_popular'
,
'display_plugins_table'
);
...
...
wp-admin/includes/post.php
View file @
0761e710
...
...
@@ -1205,12 +1205,18 @@ function get_sample_permalink_html( $id, $new_title = null, $new_slug = null ) {
$return
.
=
'<span id="change-permalinks"><a href="options-permalink.php" class="button button-small" target="_blank">'
.
__
(
'Change Permalinks'
)
.
"</a></span>
\n
"
;
}
}
else
{
if
(
function_exists
(
'mb_strlen'
)
&&
mb_strlen
(
$post_name
)
>
30
)
{
$post_name_abridged
=
mb_substr
(
$post_name
,
0
,
14
)
.
'…'
.
mb_substr
(
$post_name
,
-
14
);
}
elseif
(
strlen
(
$post_name
)
>
30
)
{
$post_name_abridged
=
substr
(
$post_name
,
0
,
14
)
.
'…'
.
substr
(
$post_name
,
-
14
);
if
(
function_exists
(
'mb_strlen'
)
)
{
if
(
mb_strlen
(
$post_name
)
>
30
)
{
$post_name_abridged
=
mb_substr
(
$post_name
,
0
,
14
)
.
'…'
.
mb_substr
(
$post_name
,
-
14
);
}
else
{
$post_name_abridged
=
$post_name
;
}
}
else
{
$post_name_abridged
=
$post_name
;
if
(
strlen
(
$post_name
)
>
30
)
{
$post_name_abridged
=
substr
(
$post_name
,
0
,
14
)
.
'…'
.
substr
(
$post_name
,
-
14
);
}
else
{
$post_name_abridged
=
$post_name
;
}
}
$post_name_html
=
'<span id="editable-post-name" title="'
.
$title
.
'">'
.
$post_name_abridged
.
'</span>'
;
...
...
wp-admin/js/editor-expand.js
View file @
0761e710
...
...
@@ -2,7 +2,7 @@
window
.
wp
=
window
.
wp
||
{};
jQuery
(
document
).
ready
(
function
(
$
)
{
jQuery
(
document
).
ready
(
function
(
$
)
{
var
$window
=
$
(
window
),
$document
=
$
(
document
),
$adminBar
=
$
(
'
#wpadminbar
'
),
...
...
@@ -148,6 +148,11 @@ jQuery( document ).ready( function($) {
// We need to wait for TinyMCE to initialize.
$document
.
on
(
'
tinymce-editor-init.editor-expand
'
,
function
(
event
,
editor
)
{
var
hideFloatPanels
=
_
.
debounce
(
function
()
{
!
$
(
'
.mce-floatpanel:hover
'
).
length
&&
tinymce
.
ui
.
FloatPanel
.
hideAll
();
$
(
'
.mce-tooltip
'
).
hide
();
},
1000
,
true
);
// Make sure it's the main editor.
if
(
editor
.
id
!==
'
content
'
)
{
return
;
...
...
@@ -224,6 +229,8 @@ jQuery( document ).ready( function($) {
// Adjust when switching editor modes.
function
mceShow
()
{
$window
.
on
(
'
scroll.mce-float-panels
'
,
hideFloatPanels
);
setTimeout
(
function
()
{
editor
.
execCommand
(
'
wpAutoResize
'
);
adjust
();
...
...
@@ -231,6 +238,8 @@ jQuery( document ).ready( function($) {
}
function
mceHide
()
{
$window
.
off
(
'
scroll.mce-float-panels
'
);
setTimeout
(
function
()
{
var
top
=
$contentWrap
.
offset
().
top
;
...
...
@@ -251,6 +260,8 @@ jQuery( document ).ready( function($) {
editor
.
on
(
'
hide
'
,
mceHide
);
// Adjust when the editor resizes.
editor
.
on
(
'
setcontent wp-autoresize wp-toolbar-toggle
'
,
adjust
);
$window
.
off
(
'
scroll.mce-float-panels
'
).
on
(
'
scroll.mce-float-panels
'
,
hideFloatPanels
);
};
mceUnbind
=
function
()
{
...
...
@@ -258,6 +269,8 @@ jQuery( document ).ready( function($) {
editor
.
off
(
'
show
'
,
mceShow
);
editor
.
off
(
'
hide
'
,
mceHide
);
editor
.
off
(
'
setcontent wp-autoresize wp-toolbar-toggle
'
,
adjust
);
$window
.
off
(
'
scroll.mce-float-panels
'
);
};
if
(
$wrap
.
hasClass
(
'
wp-editor-expand
'
)
)
{
...
...
@@ -590,6 +603,12 @@ jQuery( document ).ready( function($) {
}
adjust
();
}).
on
(
'
wp-window-resized.editor-expand
'
,
function
()
{
if
(
mceEditor
&&
!
mceEditor
.
isHidden
()
)
{
mceEditor
.
execCommand
(
'
wpAutoResize
'
);
}
else
{
textEditorResize
();
}
});
$textEditor
.
on
(
'
focus.editor-expand input.editor-expand propertychange.editor-expand
'
,
textEditorResize
);
...
...
wp-admin/js/editor-expand.min.js
View file @
0761e710
window
.
wp
=
window
.
wp
||
{},
jQuery
(
document
).
ready
(
function
(
a
){
function
b
(){
var
a
=
m
.
width
();
R
=
{
windowHeight
:
m
.
height
(),
windowWidth
:
a
,
adminBarHeight
:
a
>
600
?
o
.
outerHeight
():
0
,
toolsHeight
:
s
.
outerHeight
()
||
0
,
menuBarHeight
:
z
.
outerHeight
()
||
0
,
visualTopHeight
:
t
.
outerHeight
()
||
0
,
textTopHeight
:
v
.
outerHeight
()
||
0
,
bottomHeight
:
y
.
outerHeight
()
||
0
,
statusBarHeight
:
A
.
outerHeight
()
||
0
,
sideSortablesHeight
:
B
.
height
()
||
0
},
R
.
menuBarHeight
<
3
&&
(
R
.
menuBarHeight
=
0
)}
function
c
(
a
){
var
b
,
c
,
d
,
e
,
f
,
g
=
jQuery
.
ui
.
keyCode
,
h
=
a
.
keyCode
,
i
=
document
.
createRange
(),
j
=
w
[
0
].
selectionStart
,
k
=
w
[
0
].
selectionEnd
,
l
=
x
[
0
].
firstChild
,
m
=
10
;
if
(
!
j
||!
k
||
j
===
k
){
try
{
i
.
setStart
(
l
,
j
),
i
.
setEnd
(
l
,
k
+
1
)}
catch
(
n
){}
b
=
i
.
getBoundingClientRect
(),
b
.
height
&&
(
c
=
b
.
top
-
m
,
d
=
c
+
b
.
height
+
m
,
e
=
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
textTopHeight
,
f
=
R
.
windowHeight
-
R
.
bottomHeight
,
e
>
c
&&
(
h
===
g
.
UP
||
h
===
g
.
LEFT
||
h
===
g
.
BACKSPACE
)?
window
.
scrollTo
(
window
.
pageXOffset
,
c
+
window
.
pageYOffset
-
e
):
d
>
f
&&
window
.
scrollTo
(
window
.
pageXOffset
,
d
+
window
.
pageYOffset
-
f
))}}
function
d
(){
if
(
!
(
k
&&!
k
.
isHidden
()
||!
k
&&
"
tinymce
"
===
Q
)){
var
a
,
b
=
w
.
height
();
x
.
width
(
w
.
width
()
-
22
),
x
.
text
(
w
.
val
()
+
"
"
),
a
=
x
.
height
(),
P
>
a
&&
(
a
=
P
),
a
!==
b
&&
(
w
.
height
(
a
),
e
())}}
function
e
(
a
){
if
(
!
E
||!
E
.
settings
.
visible
){
var
c
,
e
,
f
,
g
,
h
,
i
,
j
,
l
,
o
,
q
=
m
.
scrollTop
(),
F
=
"
scroll
"
!==
a
,
G
=
k
&&!
k
.
isHidden
(),
M
=
P
,
Q
=
D
.
offset
().
top
,
S
=
1
,
T
=
r
.
width
();(
F
||!
R
.
windowHeight
)
&&
b
(),
G
||
"
resize
"
!==
a
||
d
(),
G
?(
c
=
t
,
e
=
u
,
j
=
R
.
visualTopHeight
):(
c
=
v
,
e
=
w
,
j
=
R
.
textTopHeight
),
i
=
c
.
parent
().
offset
().
top
,
l
=
e
.
offset
().
top
,
o
=
e
.
outerHeight
(),
h
=
G
?
P
+
j
:
P
+
20
,
h
=
o
>
h
+
5
,
h
?((
!
H
||
F
)
&&
q
>=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
&&
q
<=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
+
o
-
M
?(
H
=!
0
,
s
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
+
R
.
toolsHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}),
c
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())})):(
H
||
F
)
&&
(
q
<=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
?(
H
=!
1
,
s
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())})):
q
>=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
+
o
-
M
&&
(
H
=!
1
,
s
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
+
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}))),(
!
I
||
F
)
&&
q
+
R
.
windowHeight
<=
l
+
o
+
R
.
bottomHeight
+
R
.
statusBarHeight
+
S
?(
I
=!
0
,
A
.
css
({
position
:
"
fixed
"
,
bottom
:
R
.
bottomHeight
,
width
:
T
-
2
*
S
}),
y
.
css
({
position
:
"
fixed
"
,
bottom
:
0
,
width
:
T
})):(
I
||
F
)
&&
q
+
R
.
windowHeight
>
l
+
o
+
R
.
bottomHeight
+
R
.
statusBarHeight
-
S
&&
(
I
=!
1
,
A
.
add
(
y
).
attr
(
"
style
"
,
""
))):
F
&&
(
s
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}),
A
.
add
(
y
).
attr
(
"
style
"
,
""
)),
C
.
width
()
<
300
&&
R
.
windowWidth
>
600
&&
n
.
height
()
>
B
.
height
()
+
Q
+
120
&&
R
.
windowHeight
<
o
?(
R
.
sideSortablesHeight
+
N
+
O
>
R
.
windowHeight
||
J
||
K
?
Q
>=
q
+
N
?(
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
):
q
>
L
?
J
?(
J
=!
1
,
f
=
B
.
offset
().
top
-
R
.
adminBarHeight
,
g
=
p
.
offset
().
top
,
g
<
f
+
R
.
sideSortablesHeight
+
O
&&
(
f
=
g
-
R
.
sideSortablesHeight
-
12
),
B
.
css
({
position
:
"
absolute
"
,
top
:
f
,
bottom
:
""
})):
!
K
&&
R
.
sideSortablesHeight
+
B
.
offset
().
top
+
O
<
q
+
R
.
windowHeight
&&
(
K
=!
0
,
B
.
css
({
position
:
"
fixed
"
,
top
:
"
auto
"
,
bottom
:
O
})):
L
>
q
&&
(
K
?(
K
=!
1
,
f
=
B
.
offset
().
top
-
O
,
g
=
p
.
offset
().
top
,
g
<
f
+
R
.
sideSortablesHeight
+
O
&&
(
f
=
g
-
R
.
sideSortablesHeight
-
12
),
B
.
css
({
position
:
"
absolute
"
,
top
:
f
,
bottom
:
""
})):
!
J
&&
B
.
offset
().
top
>=
q
+
N
&&
(
J
=!
0
,
B
.
css
({
position
:
"
fixed
"
,
top
:
N
,
bottom
:
""
}))):(
q
>=
Q
-
N
?
B
.
css
({
position
:
"
fixed
"
,
top
:
N
}):
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
),
L
=
q
):(
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
),
F
&&
(
r
.
css
({
paddingTop
:
R
.
toolsHeight
}),
G
?
u
.
css
({
paddingTop
:
R
.
visualTopHeight
+
R
.
menuBarHeight
}):(
w
.
css
({
marginTop
:
R
.
textTopHeight
}),
x
.
width
(
T
-
20
-
2
*
S
)))}}
function
f
(){
d
(),
e
()}
function
g
(
a
){
for
(
var
b
=
1
;
6
>
b
;
b
++
)
setTimeout
(
a
,
500
*
b
)}
function
h
(){
clearTimeout
(
l
),
l
=
setTimeout
(
e
,
100
)}
function
i
(){
window
.
pageYOffset
&&
window
.
pageYOffset
>
M
&&
window
.
scrollTo
(
window
.
pageXOffset
,
0
),
q
.
addClass
(
"
wp-editor-expand
"
),
m
.
on
(
"
scroll.editor-expand resize.editor-expand
"
,
function
(
a
){
e
(
a
.
type
),
h
()}),
n
.
on
(
"
wp-collapse-menu.editor-expand postboxes-columnchange.editor-expand editor-classchange.editor-expand
"
,
e
).
on
(
"
postbox-toggled.editor-expand
"
,
function
(){
!
J
&&!
K
&&
window
.
pageYOffset
>
N
&&
(
K
=!
0
,
window
.
scrollBy
(
0
,
-
1
),
e
(),
window
.
scrollBy
(
0
,
1
)),
e
()}),
w
.
on
(
"
focus.editor-expand input.editor-expand propertychange.editor-expand
"
,
d
),
w
.
on
(
"
keyup.editor-expand
"
,
c
),
F
(),
E
&&
E
.
pubsub
.
subscribe
(
"
hidden
"
,
f
),
k
&&
(
k
.
settings
.
wp_autoresize_on
=!
0
,
k
.
execCommand
(
"
wpAutoResizeOn
"
),
k
.
isHidden
()
||
k
.
execCommand
(
"
wpAutoResize
"
)),(
!
k
||
k
.
isHidden
())
&&
d
(),
e
()}
function
j
(){
var
b
=
window
.
getUserSetting
(
"
ed_size
"
);
window
.
pageYOffset
&&
window
.
pageYOffset
>
M
&&
window
.
scrollTo
(
window
.
pageXOffset
,
0
),
q
.
removeClass
(
"
wp-editor-expand
"
),
m
.
off
(
"
.editor-expand
"
),
n
.
off
(
"
.editor-expand
"
),
w
.
off
(
"
.editor-expand
"
),
G
(),
E
&&
E
.
pubsub
.
unsubscribe
(
"
hidden
"
,
f
),
a
.
each
([
t
,
v
,
s
,
z
,
y
,
A
,
r
,
u
,
w
,
B
],
function
(
a
,
b
){
b
&&
b
.
attr
(
"
style
"
,
""
)}),
H
=
I
=
J
=
K
=!
1
,
k
&&
(
k
.
settings
.
wp_autoresize_on
=!
1
,
k
.
execCommand
(
"
wpAutoResizeOff
"
),
k
.
isHidden
()
||
(
w
.
hide
(),
b
&&
k
.
theme
.
resizeTo
(
null
,
b
))),
b
&&
w
.
height
(
b
)}
var
k
,
l
,
m
=
a
(
window
),
n
=
a
(
document
),
o
=
a
(
"
#wpadminbar
"
),
p
=
a
(
"
#wpfooter
"
),
q
=
a
(
"
#postdivrich
"
),
r
=
a
(
"
#wp-content-wrap
"
),
s
=
a
(
"
#wp-content-editor-tools
"
),
t
=
a
(),
u
=
a
(),
v
=
a
(
"
#ed_toolbar
"
),
w
=
a
(
"
#content
"
),
x
=
a
(
'
<div id="content-textarea-clone"></div>
'
),
y
=
a
(
"
#post-status-info
"
),
z
=
a
(),
A
=
a
(),
B
=
a
(
"
#side-sortables
"
),
C
=
a
(
"
#postbox-container-1
"
),
D
=
a
(
"
#post-body
"
),
E
=
window
.
wp
.
editor
&&
window
.
wp
.
editor
.
fullscreen
,
F
=
function
(){},
G
=
function
(){},
H
=!
1
,
I
=!
1
,
J
=!
1
,
K
=!
1
,
L
=
0
,
M
=
130
,
N
=
56
,
O
=
20
,
P
=
300
,
Q
=
window
.
getUserSetting
(
"
editor
"
),
R
=
{
windowHeight
:
0
,
windowWidth
:
0
,
adminBarHeight
:
0
,
toolsHeight
:
0
,
menuBarHeight
:
0
,
visualTopHeight
:
0
,
textTopHeight
:
0
,
bottomHeight
:
0
,
statusBarHeight
:
0
,
sideSortablesHeight
:
0
};
x
.
insertAfter
(
w
),
x
.
css
({
"
font-family
"
:
w
.
css
(
"
font-family
"
),
"
font-size
"
:
w
.
css
(
"
font-size
"
),
"
line-height
"
:
w
.
css
(
"
line-height
"
),
"
white-space
"
:
"
pre-wrap
"
,
"
word-wrap
"
:
"
break-word
"
}),
n
.
on
(
"
tinymce-editor-init.editor-expand
"
,
function
(
a
,
b
){
function
c
(){
var
a
,
c
,
d
=
b
.
selection
.
getNode
();
return
c
=
b
.
plugins
.
wpview
&&
(
a
=
b
.
plugins
.
wpview
.
getView
(
d
))?
a
.
getBoundingClientRect
():
d
.
getBoundingClientRect
(),
c
.
height
?
c
:
!
1
}
function
f
(
a
){
var
d
,
e
,
f
,
g
,
h
=
tinymce
.
util
.
VK
,
i
=
a
.
keyCode
,
j
=
c
(),
k
=
10
;
j
&&
(
47
>=
i
&&
i
!==
h
.
SPACEBAR
&&
i
!==
h
.
ENTER
&&
i
!==
h
.
DELETE
&&
i
!==
h
.
BACKSPACE
&&
i
!==
h
.
UP
&&
i
!==
h
.
LEFT
&&
i
!==
h
.
DOWN
&&
i
!==
h
.
UP
||
i
>=
91
&&
93
>=
i
||
i
>=
112
&&
123
>=
i
||
144
===
i
||
145
===
i
||
(
d
=
j
.
top
+
b
.
iframeElement
.
getBoundingClientRect
().
top
,
e
=
d
+
j
.
height
,
d
-=
k
,
e
+=
k
,
f
=
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
menuBarHeight
+
R
.
visualTopHeight
,
g
=
R
.
windowHeight
-
R
.
bottomHeight
-
R
.
statusBarHeight
,
g
-
f
<
j
.
height
||
(
f
>
d
&&
(
i
===
h
.
UP
||
i
===
h
.
LEFT
||
i
===
h
.
BACKSPACE
)?
window
.
scrollTo
(
window
.
pageXOffset
,
d
+
window
.
pageYOffset
-
f
):
e
>
g
&&
window
.
scrollTo
(
window
.
pageXOffset
,
e
+
window
.
pageYOffset
-
g
))))}
function
h
(){
setTimeout
(
function
(){
b
.
execCommand
(
"
wpAutoResize
"
),
e
()},
300
)}
function
i
(){
setTimeout
(
function
(){
var
a
=
r
.
offset
().
top
;
window
.
pageYOffset
>
a
&&
window
.
scrollTo
(
window
.
pageXOffset
,
a
-
R
.
adminBarHeight
),
d
(),
e
()},
100
),
e
()}
"
content
"
===
b
.
id
&&
(
k
=
b
,
b
.
settings
.
autoresize_min_height
=
P
,
t
=
r
.
find
(
"
.mce-toolbar-grp
"
),
u
=
r
.
find
(
"
.mce-edit-area
"
),
A
=
r
.
find
(
"
.mce-statusbar
"
),
z
=
r
.
find
(
"
.mce-menubar
"
),
F
=
function
(){
b
.
on
(
"
keyup
"
,
f
),
b
.
on
(
"
show
"
,
h
),
b
.
on
(
"
hide
"
,
i
),
b
.
on
(
"
setcontent wp-autoresize wp-toolbar-toggle
"
,
e
)},
G
=
function
(){
b
.
off
(
"
keyup
"
,
f
),
b
.
off
(
"
show
"
,
h
),
b
.
off
(
"
hide
"
,
i
),
b
.
off
(
"
setcontent wp-autoresize wp-toolbar-toggle
"
,
e
)},
q
.
hasClass
(
"
wp-editor-expand
"
)
&&
(
F
(),
g
(
e
)))}),
q
.
hasClass
(
"
wp-editor-expand
"
)
&&
(
i
(),
r
.
hasClass
(
"
html-active
"
)
&&
g
(
function
(){
e
(),
d
()})),
a
(
"
#adv-settings .editor-expand
"
).
show
(),
a
(
"
#editor-expand-toggle
"
).
on
(
"
change.editor-expand
"
,
function
(){
a
(
this
).
prop
(
"
checked
"
)?(
i
(),
window
.
setUserSetting
(
"
editor_expand
"
,
"
on
"
)):(
j
(),
window
.
setUserSetting
(
"
editor_expand
"
,
"
off
"
))}),
window
.
editorExpand
=
{
on
:
i
,
off
:
j
}});
\ No newline at end of file
window
.
wp
=
window
.
wp
||
{},
jQuery
(
document
).
ready
(
function
(
a
){
function
b
(){
var
a
=
m
.
width
();
R
=
{
windowHeight
:
m
.
height
(),
windowWidth
:
a
,
adminBarHeight
:
a
>
600
?
o
.
outerHeight
():
0
,
toolsHeight
:
s
.
outerHeight
()
||
0
,
menuBarHeight
:
z
.
outerHeight
()
||
0
,
visualTopHeight
:
t
.
outerHeight
()
||
0
,
textTopHeight
:
v
.
outerHeight
()
||
0
,
bottomHeight
:
y
.
outerHeight
()
||
0
,
statusBarHeight
:
A
.
outerHeight
()
||
0
,
sideSortablesHeight
:
B
.
height
()
||
0
},
R
.
menuBarHeight
<
3
&&
(
R
.
menuBarHeight
=
0
)}
function
c
(
a
){
var
b
,
c
,
d
,
e
,
f
,
g
=
jQuery
.
ui
.
keyCode
,
h
=
a
.
keyCode
,
i
=
document
.
createRange
(),
j
=
w
[
0
].
selectionStart
,
k
=
w
[
0
].
selectionEnd
,
l
=
x
[
0
].
firstChild
,
m
=
10
;
if
(
!
j
||!
k
||
j
===
k
){
try
{
i
.
setStart
(
l
,
j
),
i
.
setEnd
(
l
,
k
+
1
)}
catch
(
n
){}
b
=
i
.
getBoundingClientRect
(),
b
.
height
&&
(
c
=
b
.
top
-
m
,
d
=
c
+
b
.
height
+
m
,
e
=
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
textTopHeight
,
f
=
R
.
windowHeight
-
R
.
bottomHeight
,
e
>
c
&&
(
h
===
g
.
UP
||
h
===
g
.
LEFT
||
h
===
g
.
BACKSPACE
)?
window
.
scrollTo
(
window
.
pageXOffset
,
c
+
window
.
pageYOffset
-
e
):
d
>
f
&&
window
.
scrollTo
(
window
.
pageXOffset
,
d
+
window
.
pageYOffset
-
f
))}}
function
d
(){
if
(
!
(
k
&&!
k
.
isHidden
()
||!
k
&&
"
tinymce
"
===
Q
)){
var
a
,
b
=
w
.
height
();
x
.
width
(
w
.
width
()
-
22
),
x
.
text
(
w
.
val
()
+
"
"
),
a
=
x
.
height
(),
P
>
a
&&
(
a
=
P
),
a
!==
b
&&
(
w
.
height
(
a
),
e
())}}
function
e
(
a
){
if
(
!
E
||!
E
.
settings
.
visible
){
var
c
,
e
,
f
,
g
,
h
,
i
,
j
,
l
,
o
,
q
=
m
.
scrollTop
(),
F
=
"
scroll
"
!==
a
,
G
=
k
&&!
k
.
isHidden
(),
M
=
P
,
Q
=
D
.
offset
().
top
,
S
=
1
,
T
=
r
.
width
();(
F
||!
R
.
windowHeight
)
&&
b
(),
G
||
"
resize
"
!==
a
||
d
(),
G
?(
c
=
t
,
e
=
u
,
j
=
R
.
visualTopHeight
):(
c
=
v
,
e
=
w
,
j
=
R
.
textTopHeight
),
i
=
c
.
parent
().
offset
().
top
,
l
=
e
.
offset
().
top
,
o
=
e
.
outerHeight
(),
h
=
G
?
P
+
j
:
P
+
20
,
h
=
o
>
h
+
5
,
h
?((
!
H
||
F
)
&&
q
>=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
&&
q
<=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
+
o
-
M
?(
H
=!
0
,
s
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
+
R
.
toolsHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}),
c
.
css
({
position
:
"
fixed
"
,
top
:
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())})):(
H
||
F
)
&&
(
q
<=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
?(
H
=!
1
,
s
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())})):
q
>=
i
-
R
.
toolsHeight
-
R
.
adminBarHeight
+
o
-
M
&&
(
H
=!
1
,
s
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
o
-
M
+
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}))),(
!
I
||
F
)
&&
q
+
R
.
windowHeight
<=
l
+
o
+
R
.
bottomHeight
+
R
.
statusBarHeight
+
S
?(
I
=!
0
,
A
.
css
({
position
:
"
fixed
"
,
bottom
:
R
.
bottomHeight
,
width
:
T
-
2
*
S
}),
y
.
css
({
position
:
"
fixed
"
,
bottom
:
0
,
width
:
T
})):(
I
||
F
)
&&
q
+
R
.
windowHeight
>
l
+
o
+
R
.
bottomHeight
+
R
.
statusBarHeight
-
S
&&
(
I
=!
1
,
A
.
add
(
y
).
attr
(
"
style
"
,
""
))):
F
&&
(
s
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
}),
G
&&
z
.
length
&&
z
.
css
({
position
:
"
absolute
"
,
top
:
0
,
width
:
T
-
2
*
S
}),
c
.
css
({
position
:
"
absolute
"
,
top
:
R
.
menuBarHeight
,
width
:
T
-
2
*
S
-
(
G
?
0
:
c
.
outerWidth
()
-
c
.
width
())}),
A
.
add
(
y
).
attr
(
"
style
"
,
""
)),
C
.
width
()
<
300
&&
R
.
windowWidth
>
600
&&
n
.
height
()
>
B
.
height
()
+
Q
+
120
&&
R
.
windowHeight
<
o
?(
R
.
sideSortablesHeight
+
N
+
O
>
R
.
windowHeight
||
J
||
K
?
Q
>=
q
+
N
?(
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
):
q
>
L
?
J
?(
J
=!
1
,
f
=
B
.
offset
().
top
-
R
.
adminBarHeight
,
g
=
p
.
offset
().
top
,
g
<
f
+
R
.
sideSortablesHeight
+
O
&&
(
f
=
g
-
R
.
sideSortablesHeight
-
12
),
B
.
css
({
position
:
"
absolute
"
,
top
:
f
,
bottom
:
""
})):
!
K
&&
R
.
sideSortablesHeight
+
B
.
offset
().
top
+
O
<
q
+
R
.
windowHeight
&&
(
K
=!
0
,
B
.
css
({
position
:
"
fixed
"
,
top
:
"
auto
"
,
bottom
:
O
})):
L
>
q
&&
(
K
?(
K
=!
1
,
f
=
B
.
offset
().
top
-
O
,
g
=
p
.
offset
().
top
,
g
<
f
+
R
.
sideSortablesHeight
+
O
&&
(
f
=
g
-
R
.
sideSortablesHeight
-
12
),
B
.
css
({
position
:
"
absolute
"
,
top
:
f
,
bottom
:
""
})):
!
J
&&
B
.
offset
().
top
>=
q
+
N
&&
(
J
=!
0
,
B
.
css
({
position
:
"
fixed
"
,
top
:
N
,
bottom
:
""
}))):(
q
>=
Q
-
N
?
B
.
css
({
position
:
"
fixed
"
,
top
:
N
}):
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
),
L
=
q
):(
B
.
attr
(
"
style
"
,
""
),
J
=
K
=!
1
),
F
&&
(
r
.
css
({
paddingTop
:
R
.
toolsHeight
}),
G
?
u
.
css
({
paddingTop
:
R
.
visualTopHeight
+
R
.
menuBarHeight
}):(
w
.
css
({
marginTop
:
R
.
textTopHeight
}),
x
.
width
(
T
-
20
-
2
*
S
)))}}
function
f
(){
d
(),
e
()}
function
g
(
a
){
for
(
var
b
=
1
;
6
>
b
;
b
++
)
setTimeout
(
a
,
500
*
b
)}
function
h
(){
clearTimeout
(
l
),
l
=
setTimeout
(
e
,
100
)}
function
i
(){
window
.
pageYOffset
&&
window
.
pageYOffset
>
M
&&
window
.
scrollTo
(
window
.
pageXOffset
,
0
),
q
.
addClass
(
"
wp-editor-expand
"
),
m
.
on
(
"
scroll.editor-expand resize.editor-expand
"
,
function
(
a
){
e
(
a
.
type
),
h
()}),
n
.
on
(
"
wp-collapse-menu.editor-expand postboxes-columnchange.editor-expand editor-classchange.editor-expand
"
,
e
).
on
(
"
postbox-toggled.editor-expand
"
,
function
(){
!
J
&&!
K
&&
window
.
pageYOffset
>
N
&&
(
K
=!
0
,
window
.
scrollBy
(
0
,
-
1
),
e
(),
window
.
scrollBy
(
0
,
1
)),
e
()}).
on
(
"
wp-window-resized.editor-expand
"
,
function
(){
k
&&!
k
.
isHidden
()?
k
.
execCommand
(
"
wpAutoResize
"
):
d
()}),
w
.
on
(
"
focus.editor-expand input.editor-expand propertychange.editor-expand
"
,
d
),
w
.
on
(
"
keyup.editor-expand
"
,
c
),
F
(),
E
&&
E
.
pubsub
.
subscribe
(
"
hidden
"
,
f
),
k
&&
(
k
.
settings
.
wp_autoresize_on
=!
0
,
k
.
execCommand
(
"
wpAutoResizeOn
"
),
k
.
isHidden
()
||
k
.
execCommand
(
"
wpAutoResize
"
)),(
!
k
||
k
.
isHidden
())
&&
d
(),
e
()}
function
j
(){
var
b
=
window
.
getUserSetting
(
"
ed_size
"
);
window
.
pageYOffset
&&
window
.
pageYOffset
>
M
&&
window
.
scrollTo
(
window
.
pageXOffset
,
0
),
q
.
removeClass
(
"
wp-editor-expand
"
),
m
.
off
(
"
.editor-expand
"
),
n
.
off
(
"
.editor-expand
"
),
w
.
off
(
"
.editor-expand
"
),
G
(),
E
&&
E
.
pubsub
.
unsubscribe
(
"
hidden
"
,
f
),
a
.
each
([
t
,
v
,
s
,
z
,
y
,
A
,
r
,
u
,
w
,
B
],
function
(
a
,
b
){
b
&&
b
.
attr
(
"
style
"
,
""
)}),
H
=
I
=
J
=
K
=!
1
,
k
&&
(
k
.
settings
.
wp_autoresize_on
=!
1
,
k
.
execCommand
(
"
wpAutoResizeOff
"
),
k
.
isHidden
()
||
(
w
.
hide
(),
b
&&
k
.
theme
.
resizeTo
(
null
,
b
))),
b
&&
w
.
height
(
b
)}
var
k
,
l
,
m
=
a
(
window
),
n
=
a
(
document
),
o
=
a
(
"
#wpadminbar
"
),
p
=
a
(
"
#wpfooter
"
),
q
=
a
(
"
#postdivrich
"
),
r
=
a
(
"
#wp-content-wrap
"
),
s
=
a
(
"
#wp-content-editor-tools
"
),
t
=
a
(),
u
=
a
(),
v
=
a
(
"
#ed_toolbar
"
),
w
=
a
(
"
#content
"
),
x
=
a
(
'
<div id="content-textarea-clone"></div>
'
),
y
=
a
(
"
#post-status-info
"
),
z
=
a
(),
A
=
a
(),
B
=
a
(
"
#side-sortables
"
),
C
=
a
(
"
#postbox-container-1
"
),
D
=
a
(
"
#post-body
"
),
E
=
window
.
wp
.
editor
&&
window
.
wp
.
editor
.
fullscreen
,
F
=
function
(){},
G
=
function
(){},
H
=!
1
,
I
=!
1
,
J
=!
1
,
K
=!
1
,
L
=
0
,
M
=
130
,
N
=
56
,
O
=
20
,
P
=
300
,
Q
=
window
.
getUserSetting
(
"
editor
"
),
R
=
{
windowHeight
:
0
,
windowWidth
:
0
,
adminBarHeight
:
0
,
toolsHeight
:
0
,
menuBarHeight
:
0
,
visualTopHeight
:
0
,
textTopHeight
:
0
,
bottomHeight
:
0
,
statusBarHeight
:
0
,
sideSortablesHeight
:
0
};
x
.
insertAfter
(
w
),
x
.
css
({
"
font-family
"
:
w
.
css
(
"
font-family
"
),
"
font-size
"
:
w
.
css
(
"
font-size
"
),
"
line-height
"
:
w
.
css
(
"
line-height
"
),
"
white-space
"
:
"
pre-wrap
"
,
"
word-wrap
"
:
"
break-word
"
}),
n
.
on
(
"
tinymce-editor-init.editor-expand
"
,
function
(
b
,
c
){
function
f
(){
var
a
,
b
,
d
=
c
.
selection
.
getNode
();
return
b
=
c
.
plugins
.
wpview
&&
(
a
=
c
.
plugins
.
wpview
.
getView
(
d
))?
a
.
getBoundingClientRect
():
d
.
getBoundingClientRect
(),
b
.
height
?
b
:
!
1
}
function
h
(
a
){
var
b
,
d
,
e
,
g
,
h
=
tinymce
.
util
.
VK
,
i
=
a
.
keyCode
,
j
=
f
(),
k
=
10
;
j
&&
(
47
>=
i
&&
i
!==
h
.
SPACEBAR
&&
i
!==
h
.
ENTER
&&
i
!==
h
.
DELETE
&&
i
!==
h
.
BACKSPACE
&&
i
!==
h
.
UP
&&
i
!==
h
.
LEFT
&&
i
!==
h
.
DOWN
&&
i
!==
h
.
UP
||
i
>=
91
&&
93
>=
i
||
i
>=
112
&&
123
>=
i
||
144
===
i
||
145
===
i
||
(
b
=
j
.
top
+
c
.
iframeElement
.
getBoundingClientRect
().
top
,
d
=
b
+
j
.
height
,
b
-=
k
,
d
+=
k
,
e
=
R
.
adminBarHeight
+
R
.
toolsHeight
+
R
.
menuBarHeight
+
R
.
visualTopHeight
,
g
=
R
.
windowHeight
-
R
.
bottomHeight
-
R
.
statusBarHeight
,
g
-
e
<
j
.
height
||
(
e
>
b
&&
(
i
===
h
.
UP
||
i
===
h
.
LEFT
||
i
===
h
.
BACKSPACE
)?
window
.
scrollTo
(
window
.
pageXOffset
,
b
+
window
.
pageYOffset
-
e
):
d
>
g
&&
window
.
scrollTo
(
window
.
pageXOffset
,
d
+
window
.
pageYOffset
-
g
))))}
function
i
(){
m
.
on
(
"
scroll.mce-float-panels
"
,
l
),
setTimeout
(
function
(){
c
.
execCommand
(
"
wpAutoResize
"
),
e
()},
300
)}
function
j
(){
m
.
off
(
"
scroll.mce-float-panels
"
),
setTimeout
(
function
(){
var
a
=
r
.
offset
().
top
;
window
.
pageYOffset
>
a
&&
window
.
scrollTo
(
window
.
pageXOffset
,
a
-
R
.
adminBarHeight
),
d
(),
e
()},
100
),
e
()}
var
l
=
_
.
debounce
(
function
(){
!
a
(
"
.mce-floatpanel:hover
"
).
length
&&
tinymce
.
ui
.
FloatPanel
.
hideAll
(),
a
(
"
.mce-tooltip
"
).
hide
()},
1
e3
,
!
0
);
"
content
"
===
c
.
id
&&
(
k
=
c
,
c
.
settings
.
autoresize_min_height
=
P
,
t
=
r
.
find
(
"
.mce-toolbar-grp
"
),
u
=
r
.
find
(
"
.mce-edit-area
"
),
A
=
r
.
find
(
"
.mce-statusbar
"
),
z
=
r
.
find
(
"
.mce-menubar
"
),
F
=
function
(){
c
.
on
(
"
keyup
"
,
h
),
c
.
on
(
"
show
"
,
i
),
c
.
on
(
"
hide
"
,
j
),
c
.
on
(
"
setcontent wp-autoresize wp-toolbar-toggle
"
,
e
),
m
.
off
(
"
scroll.mce-float-panels
"
).
on
(
"
scroll.mce-float-panels
"
,
l
)},
G
=
function
(){
c
.
off
(
"
keyup
"
,
h
),
c
.
off
(
"
show
"
,
i
),
c
.
off
(
"
hide
"
,
j
),
c
.
off
(
"
setcontent wp-autoresize wp-toolbar-toggle
"
,
e
),
m
.
off
(
"
scroll.mce-float-panels
"
)},
q
.
hasClass
(
"
wp-editor-expand
"
)
&&
(
F
(),
g
(
e
)))}),
q
.
hasClass
(
"
wp-editor-expand
"
)
&&
(
i
(),
r
.
hasClass
(
"
html-active
"
)
&&
g
(
function
(){
e
(),
d
()})),
a
(
"
#adv-settings .editor-expand
"
).
show
(),
a
(
"
#editor-expand-toggle
"
).
on
(
"
change.editor-expand
"
,
function
(){
a
(
this
).
prop
(
"
checked
"
)?(
i
(),
window
.
setUserSetting
(
"
editor_expand
"
,
"
on
"
)):(
j
(),
window
.
setUserSetting
(
"
editor_expand
"
,
"
off
"
))}),
window
.
editorExpand
=
{
on
:
i
,
off
:
j
}});
\ No newline at end of file
wp-admin/js/media.js
View file @
0761e710
...
...
@@ -72,11 +72,15 @@ var findPosts;
};
$
(
document
).
ready
(
function
()
{
var
$mediaGridWrap
=
$
(
'
#wp-media-grid
'
);
// Open up a manage media frame into the grid.
wp
.
media
&&
wp
.
media
({
frame
:
'
manage
'
,
container
:
$
(
'
#wpbody-content > .wrap
'
)
}).
open
();
if
(
$mediaGridWrap
.
length
&&
window
.
wp
&&
window
.
wp
.
media
)
{
window
.
wp
.
media
({
frame
:
'
manage
'
,
container
:
$mediaGridWrap
}).
open
();
}
$
(
'
#find-posts-submit
'
).
click
(
function
(
event
)
{
if
(
!
$
(
'
#find-posts-response input[type="radio"]:checked
'
).
length
)
...
...
wp-admin/js/media.min.js
View file @
0761e710
var
findPosts
;
!
function
(
a
){
findPosts
=
{
open
:
function
(
b
,
c
){
var
d
=
a
(
"
.ui-find-overlay
"
);
return
0
===
d
.
length
&&
(
a
(
"
body
"
).
append
(
'
<div class="ui-find-overlay"></div>
'
),
findPosts
.
overlay
()),
d
.
show
(),
b
&&
c
&&
a
(
"
#affected
"
).
attr
(
"
name
"
,
b
).
val
(
c
),
a
(
"
#find-posts
"
).
show
(),
a
(
"
#find-posts-input
"
).
focus
().
keyup
(
function
(
a
){
27
==
a
.
which
&&
findPosts
.
close
()}),
findPosts
.
send
(),
!
1
},
close
:
function
(){
a
(
"
#find-posts-response
"
).
html
(
""
),
a
(
"
#find-posts
"
).
hide
(),
a
(
"
.ui-find-overlay
"
).
hide
()},
overlay
:
function
(){
a
(
"
.ui-find-overlay
"
).
on
(
"
click
"
,
function
(){
findPosts
.
close
()})},
send
:
function
(){
var
b
=
{
ps
:
a
(
"
#find-posts-input
"
).
val
(),
action
:
"
find_posts
"
,
_ajax_nonce
:
a
(
"
#_ajax_nonce
"
).
val
()},
c
=
a
(
"
.find-box-search .spinner
"
);
c
.
show
(),
a
.
ajax
(
ajaxurl
,{
type
:
"
POST
"
,
data
:
b
,
dataType
:
"
json
"
}).
always
(
function
(){
c
.
hide
()}).
done
(
function
(
b
){
b
.
success
||
a
(
"
#find-posts-response
"
).
text
(
attachMediaBoxL10n
.
error
),
a
(
"
#find-posts-response
"
).
html
(
b
.
data
)}).
fail
(
function
(){
a
(
"
#find-posts-response
"
).
text
(
attachMediaBoxL10n
.
error
)})}},
a
(
document
).
ready
(
function
(){
wp
.
media
&&
wp
.
media
({
frame
:
"
manage
"
,
container
:
a
(
"
#wpbody-content > .wrap
"
)}).
open
(),
a
(
"
#find-posts-submit
"
).
click
(
function
(
b
){
a
(
'
#find-posts-response input[type="radio"]:checked
'
).
length
||
b
.
preventDefault
()}),
a
(
"
#find-posts .find-box-search :input
"
).
keypress
(
function
(
a
){
return
13
==
a
.
which
?(
findPosts
.
send
(),
!
1
):
void
0
}),
a
(
"
#find-posts-search
"
).
click
(
findPosts
.
send
),
a
(
"
#find-posts-close
"
).
click
(
findPosts
.
close
),
a
(
"
#doaction, #doaction2
"
).
click
(
function
(
b
){
a
(
'
select[name^="action"]
'
).
each
(
function
(){
"
attach
"
===
a
(
this
).
val
()
&&
(
b
.
preventDefault
(),
findPosts
.
open
())})}),
a
(
"
.find-box-inside
"
).
on
(
"
click
"
,
"
tr
"
,
function
(){
a
(
this
).
find
(
"
.found-radio input
"
).
prop
(
"
checked
"
,
!
0
)})})}(
jQuery
);
\ No newline at end of file
var
findPosts
;
!
function
(
a
){
findPosts
=
{
open
:
function
(
b
,
c
){
var
d
=
a
(
"
.ui-find-overlay
"
);
return
0
===
d
.
length
&&
(
a
(
"
body
"
).
append
(
'
<div class="ui-find-overlay"></div>
'
),
findPosts
.
overlay
()),
d
.
show
(),
b
&&
c
&&
a
(
"
#affected
"
).
attr
(
"
name
"
,
b
).
val
(
c
),
a
(
"
#find-posts
"
).
show
(),
a
(
"
#find-posts-input
"
).
focus
().
keyup
(
function
(
a
){
27
==
a
.
which
&&
findPosts
.
close
()}),
findPosts
.
send
(),
!
1
},
close
:
function
(){
a
(
"
#find-posts-response
"
).
html
(
""
),
a
(
"
#find-posts
"
).
hide
(),
a
(
"
.ui-find-overlay
"
).
hide
()},
overlay
:
function
(){
a
(
"
.ui-find-overlay
"
).
on
(
"
click
"
,
function
(){
findPosts
.
close
()})},
send
:
function
(){
var
b
=
{
ps
:
a
(
"
#find-posts-input
"
).
val
(),
action
:
"
find_posts
"
,
_ajax_nonce
:
a
(
"
#_ajax_nonce
"
).
val
()},
c
=
a
(
"
.find-box-search .spinner
"
);
c
.
show
(),
a
.
ajax
(
ajaxurl
,{
type
:
"
POST
"
,
data
:
b
,
dataType
:
"
json
"
}).
always
(
function
(){
c
.
hide
()}).
done
(
function
(
b
){
b
.
success
||
a
(
"
#find-posts-response
"
).
text
(
attachMediaBoxL10n
.
error
),
a
(
"
#find-posts-response
"
).
html
(
b
.
data
)}).
fail
(
function
(){
a
(
"
#find-posts-response
"
).
text
(
attachMediaBoxL10n
.
error
)})}},
a
(
document
).
ready
(
function
(){
var
b
=
a
(
"
#wp-media-grid
"
);
b
.
length
&&
window
.
wp
&&
window
.
wp
.
media
&&
window
.
wp
.
media
({
frame
:
"
manage
"
,
container
:
b
}).
open
(),
a
(
"
#find-posts-submit
"
).
click
(
function
(
b
){
a
(
'
#find-posts-response input[type="radio"]:checked
'
).
length
||
b
.
preventDefault
()}),
a
(
"
#find-posts .find-box-search :input
"
).
keypress
(
function
(
a
){
return
13
==
a
.
which
?(
findPosts
.
send
(),
!
1
):
void
0
}),
a
(
"
#find-posts-search
"
).
click
(
findPosts
.
send
),
a
(
"
#find-posts-close
"
).
click
(
findPosts
.
close
),
a
(
"
#doaction, #doaction2
"
).
click
(
function
(
b
){
a
(
'
select[name^="action"]
'
).
each
(
function
(){
"
attach
"
===
a
(
this
).
val
()
&&
(
b
.
preventDefault
(),
findPosts
.
open
())})}),
a
(
"
.find-box-inside
"
).
on
(
"
click
"
,
"
tr
"
,
function
(){
a
(
this
).
find
(
"
.found-radio input
"
).
prop
(
"
checked
"
,
!
0
)})})}(
jQuery
);
\ No newline at end of file
wp-admin/plugin-install.php
View file @
0761e710
...
...
@@ -24,8 +24,27 @@ if ( is_multisite() && ! is_network_admin() ) {
$wp_list_table
=
_get_list_table
(
'WP_Plugin_Install_List_Table'
);
$pagenum
=
$wp_list_table
->
get_pagenum
();
if
(
!
empty
(
$_REQUEST
[
'_wp_http_referer'
]
)
)
{
$location
=
remove_query_arg
(
'_wp_http_referer'
,
wp_unslash
(
$_SERVER
[
'REQUEST_URI'
]
)
);
if
(
!
empty
(
$_REQUEST
[
'paged'
]
)
)
{
$location
=
add_query_arg
(
'paged'
,
(
int
)
$_REQUEST
[
'paged'
],
$location
);
}
wp_redirect
(
$location
);
exit
;
}
$wp_list_table
->
prepare_items
();
$total_pages
=
$wp_list_table
->
get_pagination_arg
(
'total_pages'
);
if
(
$pagenum
>
$total_pages
&&
$total_pages
>
0
)
{
wp_redirect
(
add_query_arg
(
'paged'
,
$total_pages
)
);
exit
;
}
$title
=
__
(
'Add Plugins'
);
$parent_file
=
'plugins.php'
;
...
...
wp-admin/press-this.php
View file @
0761e710
...
...
@@ -63,7 +63,7 @@ function press_it() {
// Error handling for media_sideload.
if
(
is_wp_error
(
$upload
)
)
{
wp_delete_post
(
$post_ID
);
wp_die
(
$upload
);
wp_die
(
esc_html
(
$upload
->
get_error_message
()
)
);
}
else
{
// Post formats.
if
(
isset
(
$_POST
[
'post_format'
]
)
)
{
...
...
wp-admin/upload.php
View file @
0761e710
...
...
@@ -57,7 +57,7 @@ if ( 'grid' === $mode ) {
require_once
(
ABSPATH
.
'wp-admin/admin-header.php'
);
?>
<div
class=
"wrap"
>
<div
class=
"wrap"
id=
"wp-media-grid"
>
<h2>
<?php
echo
esc_html
(
$title
);
...
...
wp-includes/canonical.php
View file @
0761e710
...
...
@@ -360,10 +360,6 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
else
unset
(
$redirect
[
'port'
]);
if
(
!
empty
(
$user_home
[
'scheme'
]
)
&&
$user_home
[
'scheme'
]
===
'https'
)
{
$redirect
[
'scheme'
]
=
'https'
;
}
// trailing /index.php
$redirect
[
'path'
]
=
preg_replace
(
'|/'
.
preg_quote
(
$wp_rewrite
->
index
,
'|'
)
.
'/*?$|'
,
'/'
,
$redirect
[
'path'
]);
...
...
@@ -421,7 +417,7 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
(
strtolower
(
$original
[
'host'
])
!=
'www.'
.
strtolower
(
$redirect
[
'host'
])
&&
'www.'
.
strtolower
(
$original
[
'host'
])
!=
strtolower
(
$redirect
[
'host'
])
)
)
$redirect
[
'host'
]
=
$original
[
'host'
];
$compare_original
=
array
(
$original
[
'
scheme'
],
$original
[
'
host'
],
$original
[
'path'
]
);
$compare_original
=
array
(
$original
[
'host'
],
$original
[
'path'
]
);
if
(
!
empty
(
$original
[
'port'
]
)
)
$compare_original
[]
=
$original
[
'port'
];
...
...
@@ -429,7 +425,7 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
if
(
!
empty
(
$original
[
'query'
]
)
)
$compare_original
[]
=
$original
[
'query'
];
$compare_redirect
=
array
(
$redirect
[
'
scheme'
],
$redirect
[
'
host'
],
$redirect
[
'path'
]
);
$compare_redirect
=
array
(
$redirect
[
'host'
],
$redirect
[
'path'
]
);
if
(
!
empty
(
$redirect
[
'port'
]
)
)
$compare_redirect
[]
=
$redirect
[
'port'
];
...
...
wp-includes/class-phpass.php
View file @
0761e710
...
...
@@ -214,6 +214,10 @@ class PasswordHash {
function
HashPassword
(
$password
)
{
if
(
strlen
(
$password
)
>
4096
)
{
return
'*'
;
}
$random
=
''
;
if
(
CRYPT_BLOWFISH
==
1
&&
!
$this
->
portable_hashes
)
{
...
...
@@ -249,6 +253,10 @@ class PasswordHash {
function
CheckPassword
(
$password
,
$stored_hash
)
{
if
(
strlen
(
$password
)
>
4096
)
{
return
false
;
}
$hash
=
$this
->
crypt_private
(
$password
,
$stored_hash
);
if
(
$hash
[
0
]
==
'*'
)
$hash
=
crypt
(
$password
,
$stored_hash
);
...
...
wp-includes/css/media-views-rtl.css
View file @
0761e710
...
...
@@ -7,6 +7,14 @@
box-sizing
:
content-box
;
}
.media-frame
input
,
.media-frame
select
,
.media-frame
textarea
{
-webkit-box-sizing
:
border-box
;
-moz-box-sizing
:
border-box
;
box-sizing
:
border-box
;
}
.media-modal
,
.media-frame
{
font-family
:
"Open Sans"
,
sans-serif
;
...
...
@@ -56,9 +64,6 @@
.media-frame
select
{
font-family
:
"Open Sans"
,
sans-serif
;
font-size
:
12px
;
-webkit-box-sizing
:
border-box
;
-moz-box-sizing
:
border-box
;
box-sizing
:
border-box
;
border-width
:
1px
;
border-style
:
solid
;
border-color
:
#dfdfdf
;
...
...
wp-includes/css/media-views-rtl.min.css
View file @
0761e710
This diff is collapsed.
Click to expand it.
wp-includes/css/media-views.css
View file @
0761e710
...
...
@@ -7,6 +7,14 @@
box-sizing
:
content-box
;
}
.media-frame
input
,
.media-frame
select
,
.media-frame
textarea
{
-webkit-box-sizing
:
border-box
;
-moz-box-sizing
:
border-box
;
box-sizing
:
border-box
;
}
.media-modal
,
.media-frame
{
font-family
:
"Open Sans"
,
sans-serif
;
...
...
@@ -56,9 +64,6 @@
.media-frame
select
{
font-family
:
"Open Sans"
,
sans-serif
;
font-size
:
12px
;
-webkit-box-sizing
:
border-box
;
-moz-box-sizing
:
border-box
;
box-sizing
:
border-box
;
border-width
:
1px
;
border-style
:
solid
;
border-color
:
#dfdfdf
;
...
...
wp-includes/css/media-views.min.css
View file @
0761e710
This diff is collapsed.
Click to expand it.
wp-includes/formatting.php
View file @
0761e710
...
...
@@ -28,7 +28,7 @@
* @return string The string replaced with html entities
*/
function
wptexturize
(
$text
,
$reset
=
false
)
{
global
$wp_cockneyreplace
;
global
$wp_cockneyreplace
,
$shortcode_tags
;
static
$static_characters
,
$static_replacements
,
$dynamic_characters
,
$dynamic_replacements
,
$default_no_texturize_tags
,
$default_no_texturize_shortcodes
,
$run_texturize
=
true
;
...
...
@@ -205,21 +205,34 @@ function wptexturize($text, $reset = false) {
// Look for shortcodes and HTML elements.
$tagnames
=
array_keys
(
$shortcode_tags
);
$tagregexp
=
join
(
'|'
,
array_map
(
'preg_quote'
,
$tagnames
)
);
$tagregexp
=
"(?:
$tagregexp
)(?![
\\
w-])"
;
// Excerpt of get_shortcode_regex().
$comment_regex
=
'!'
// Start of comment, after the <.
.
'(?:'
// Unroll the loop: Consume everything until --> is found.
.
'-(?!->)'
// Dash not followed by end of comment.
.
'[^\-]*+'
// Consume non-dashes.
.
')*+'
// Loop possessively.
.
'-->'
;
// End of comment.
$regex
=
'/('
// Capture the entire match.
.
'<'
// Find start of element.
.
'(?(?=!--)'
// Is this a comment?
.
'.+?--\s*>'
// Find end of comment
.
$comment_regex
// Find end of comment
.
'|'
.
'[^>]+>'
// Find end of element
.
')'
.
'|'
.
'\['
// Find start of shortcode.
.
'\[?'
// Shortcodes may begin with [[
.
'[\/\[]?'
// Shortcodes may begin with [/ or [[
.
$tagregexp
// Only match registered shortcodes, because performance.
.
'(?:'
.
'[^\[\]<>]
'
// Shortcodes do not contain other shortcodes
.
.
'[^\[\]<>]
+'
// Shortcodes do not contain other shortcodes. Quantifier critical
.
.
'|'
.
'<[^
>]+
>'
// HTML elements permitted. Prevents matching ] before >.
.
')
++'
.
'<[^
\[\]>]*
>'
// HTML elements permitted. Prevents matching ] before >.
.
')
*+'
// Possessive critical.
.
'\]'
// Find end of shortcode.
.
'\]?'
// Shortcodes may end with ]]
.
')/s'
;
...
...
@@ -241,12 +254,12 @@ function wptexturize($text, $reset = false) {
continue
;
}
elseif
(
'['
===
$first
&&
1
===
preg_match
(
'/^\[
(?:[^\[\]<>]|<[^>]+>)+
+\]$/'
,
$curl
)
)
{
}
elseif
(
'['
===
$first
&&
1
===
preg_match
(
'/^\[
\/?'
.
$tagregexp
.
'(?:[^\[\]<>]+|<[^\[\]>]*>)*
+\]$/'
,
$curl
)
)
{
// This is a shortcode delimiter.
_wptexturize_pushpop_element
(
$curl
,
$no_texturize_shortcodes_stack
,
$no_texturize_shortcodes
);
}
elseif
(
'['
===
$first
&&
1
===
preg_match
(
'/^\[
\[?(?:[^\[\]<>]|<[^>]+>)+
+\]\]?$/'
,
$curl
)
)
{
}
elseif
(
'['
===
$first
&&
1
===
preg_match
(
'/^\[
[\/\[]?'
.
$tagregexp
.
'(?:[^\[\]<>]+|<[^\[\]>]*>)*
+\]\]?$/'
,
$curl
)
)
{
// This is an escaped shortcode delimiter.
// Do not texturize.
...
...
wp-includes/http.php
View file @
0761e710
...
...
@@ -444,8 +444,9 @@ function send_origin_headers() {
* @return mixed URL or false on failure.
*/
function
wp_http_validate_url
(
$url
)
{
$original_url
=
$url
;
$url
=
wp_kses_bad_protocol
(
$url
,
array
(
'http'
,
'https'
)
);
if
(
!
$url
)
if
(
!
$url
||
strtolower
(
$url
)
!==
strtolower
(
$original_url
)
)
return
false
;
$parsed_url
=
@
parse_url
(
$url
);
...
...
@@ -455,7 +456,7 @@ function wp_http_validate_url( $url ) {
if
(
isset
(
$parsed_url
[
'user'
]
)
||
isset
(
$parsed_url
[
'pass'
]
)
)
return
false
;
if
(
false
!==
strp
os
(
$parsed_url
[
'host'
],
':
'
)
)
if
(
false
!==
strp
brk
(
$parsed_url
[
'host'
],
':#?[]
'
)
)
return
false
;
$parsed_home
=
@
parse_url
(
get_option
(
'home'
)
);
...
...
@@ -473,8 +474,7 @@ function wp_http_validate_url( $url ) {
}
if
(
$ip
)
{
$parts
=
array_map
(
'intval'
,
explode
(
'.'
,
$ip
)
);
if
(
'127.0.0.1'
===
$ip
||
(
10
===
$parts
[
0
]
)
if
(
127
===
$parts
[
0
]
||
10
===
$parts
[
0
]
||
(
172
===
$parts
[
0
]
&&
16
<=
$parts
[
1
]
&&
31
>=
$parts
[
1
]
)
||
(
192
===
$parts
[
0
]
&&
168
===
$parts
[
1
]
)
)
{
...
...
wp-includes/js/media-grid.js
View file @
0761e710
...
...
@@ -577,10 +577,11 @@
return
(
this
.
getCurrentIndex
()
-
1
)
>
-
1
;
},
/**
* Respond to the keyboard events: right arrow, left arrow, escape.
* Respond to the keyboard events: right arrow, left arrow, except when
* focus is in a textarea or input field.
*/
keyEvent
:
function
(
event
)
{
if
(
'
INPUT
'
===
event
.
target
.
tagName
&&
!
(
event
.
target
.
readOnly
||
event
.
target
.
disabled
)
)
{
if
(
(
'
INPUT
'
===
event
.
target
.
nodeName
||
'
TEXTAREA
'
===
event
.
target
.
nodeName
)
&&
!
(
event
.
target
.
readOnly
||
event
.
target
.
disabled
)
)
{
return
;
}
...
...
wp-includes/js/media-grid.min.js
View file @
0761e710
This diff is collapsed.
Click to expand it.
wp-includes/js/media-views.js
View file @
0761e710
...
...
@@ -5850,7 +5850,7 @@
controller
:
this
.
controller
,
priority
:
-
60
,
click
:
function
()
{
var
model
,
chang
ed
=
[],
self
=
this
,
var
changed
=
[],
remov
ed
=
[],
self
=
this
,
selection
=
this
.
controller
.
state
().
get
(
'
selection
'
),
library
=
this
.
controller
.
state
().
get
(
'
library
'
);
...
...
@@ -5869,22 +5869,28 @@
return
;
}
while
(
selection
.
length
>
0
)
{
model
=
selection
.
at
(
0
);
selection
.
each
(
function
(
model
)
{
if
(
!
model
.
get
(
'
nonces
'
)[
'
delete
'
]
)
{
removed
.
push
(
model
);
return
;
}
if
(
media
.
view
.
settings
.
mediaTrash
&&
'
trash
'
===
model
.
get
(
'
status
'
)
)
{
model
.
set
(
'
status
'
,
'
inherit
'
);
changed
.
push
(
model
.
save
()
);
selection
.
remove
(
model
);
removed
.
push
(
model
);
}
else
if
(
media
.
view
.
settings
.
mediaTrash
)
{
model
.
set
(
'
status
'
,
'
trash
'
);
changed
.
push
(
model
.
save
()
);
selection
.
remove
(
model
);
removed
.
push
(
model
);
}
else
{
model
.
destroy
();
}
}
}
);
if
(
changed
.
length
)
{
selection
.
remove
(
removed
);
$
.
when
.
apply
(
null
,
changed
).
then
(
function
()
{
library
.
_requery
(
true
);
self
.
controller
.
trigger
(
'
selection:action:done
'
);
...
...
wp-includes/js/media-views.min.js
View file @
0761e710
This diff is collapsed.
Click to expand it.
wp-includes/js/mediaelement/flashmediaelement.swf