Hide the toolbar on all subsequent links in the theme preview. props linuxologos, fixes #19610.

git-svn-id: https://develop.svn.wordpress.org/trunk@19617 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2011-12-20 22:10:47 +00:00
parent 242f736374
commit 1af5a43882
1 changed files with 1 additions and 1 deletions

View File

@ -1231,7 +1231,7 @@ function preview_theme_ob_filter_callback( $matches ) {
)
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') )
$link = "?$link";
return $matches[1] . esc_attr( $link ) . $matches[4];