Hide the toolbar on all subsequent links in the theme preview. props linuxologos, fixes #19610.
git-svn-id: http://svn.automattic.com/wordpress/trunk@19617 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
d56fe066da
commit
3f890507d4
|
@ -1231,7 +1231,7 @@ function preview_theme_ob_filter_callback( $matches ) {
|
||||||
)
|
)
|
||||||
return $matches[1] . "#$matches[2] onclick=$matches[2]return false;" . $matches[4];
|
return $matches[1] . "#$matches[2] onclick=$matches[2]return false;" . $matches[4];
|
||||||
|
|
||||||
$link = add_query_arg( array('preview' => 1, 'template' => $_GET['template'], 'stylesheet' => @$_GET['stylesheet'] ), $matches[3] );
|
$link = add_query_arg( array( 'preview' => 1, 'template' => $_GET['template'], 'stylesheet' => @$_GET['stylesheet'], 'preview_iframe' => 1 ), $matches[3] );
|
||||||
if ( 0 === strpos($link, 'preview=1') )
|
if ( 0 === strpos($link, 'preview=1') )
|
||||||
$link = "?$link";
|
$link = "?$link";
|
||||||
return $matches[1] . esc_attr( $link ) . $matches[4];
|
return $matches[1] . esc_attr( $link ) . $matches[4];
|
||||||
|
|
Loading…
Reference in New Issue