Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

esc in url home and value search form #355

Merged
merged 2 commits into from
Oct 6, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@
<div class="page-header hidden-xs">
<?php if ( is_home() ) : ?>
<h1 class="site-title">
<a href="<?php echo home_url(); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<?php bloginfo( 'name' ); ?>
</a>
</h1>
<h2 class="site-description"><?php bloginfo( 'description' ); ?></h2>
<?php else : ?>
<div class="site-title h1">
<a href="<?php echo home_url(); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<?php bloginfo( 'name' ); ?>
</a>
</div>
Expand All @@ -69,7 +69,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand visible-xs-block" href="<?php echo home_url(); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<a class="navbar-brand visible-xs-block" href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
<?php bloginfo( 'name' ); ?>
</a>
</div>
Expand All @@ -91,7 +91,7 @@
<?php _e( 'Search:', 'odin' ); ?>
</label>
<div class="form-group">
<input type="search" class="form-control" name="s" id="navbar-search" />
<input type="search" value="<?php echo get_search_query(); ?>" class="form-control" name="s" id="navbar-search" />
</div>
<button type="submit" class="btn btn-default"><?php _e( 'Search', 'odin' ); ?></button>
</form>
Expand Down