Template for the wordpress searchform.php

The standart wordpress searchform is not saved as a file.

This is okay as long as you do not want to change something in that file.
But at that time you want to configure the searchform on your blog or website you need to create the searchform.php yourself.

How to create the wordpress searchform.php

1. Create a file named “searchform.php”
2. Copy this code and paste it into the file:

<form role="search" method="get" id="searchform" action="<?php echo home_url( '/' ); ?>">
<div><label class="screen-reader-text" for="s">Search for:</label>
<input type="text" value="" placeholder="Search..." name="s" id="s" />
<input type="submit" id="searchsubmit" value="Search" />

3. Upload the searchform.php into your theme folder.

That’s it, now you can start configuring it!

Hope it helped 🙂
– Kev