Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
WP Plugins
ETH Escape Headspace
Commits
46a6ddc2
Commit
46a6ddc2
authored
Feb 15, 2016
by
Erick Hitter
Browse files
Raw footer output
parent
4d92cdeb
Changes
1
Show whitespace changes
Inline
Side-by-side
eth-escape-headspace.php
View file @
46a6ddc2
...
...
@@ -45,9 +45,7 @@ class ETH_Escape_HeadSpace2 {
private
$hs_string_keys
=
array
(
'_headspace_description'
,
'_headspace_metakey'
,
'_headspace_page_title'
,
'_headspace_raw'
,
'_headspace_raw_footer'
,
);
private
$hs_array_keys
=
array
(
...
...
@@ -75,6 +73,7 @@ class ETH_Escape_HeadSpace2 {
*/
private
function
__construct
()
{
add_action
(
'wp_head'
,
array
(
$this
,
'action_wp_head'
)
);
add_action
(
'wp_footer'
,
array
(
$this
,
'action_wp_footer'
)
);
}
/**
...
...
@@ -163,7 +162,7 @@ class ETH_Escape_HeadSpace2 {
}
// Raw output should follow all other output
if
(
isset
(
$hs_data
[
'_headspace_raw'
]
)
)
{
if
(
isset
(
$hs_data
[
'_headspace_raw'
]
)
&&
!
empty
(
$hs_data
[
'_headspace_raw'
]
)
)
{
$output
[]
=
$hs_data
[
'_headspace_raw'
];
}
...
...
@@ -175,6 +174,17 @@ class ETH_Escape_HeadSpace2 {
// Mark end of output
echo
"
\n
<!-- Escape HeadSpace2 -->
\n
"
;
}
/**
*
*/
public
function
action_wp_footer
()
{
$output
=
get_post_meta
(
get_the_ID
(),
'_headspace_raw_footer'
,
true
);
if
(
!
empty
(
$output
)
)
{
echo
$output
.
"
\n
"
;
}
}
}
ETH_Escape_HeadSpace2
::
get_instance
();
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment