views:

31

answers:

2

Hi,

Hoping someone can assist - I'm currently developing a website in HTML/CSS that will eventually be converted into a WordPress CMS - this is the first time I am attempting this and have a few queries regarding this:

1) Within the current site I am developing, I want to have a "Search" box feature by where the user can search on any content within the site - now my question is here, is it worth developing this feature here at the HTML/CSS stage or can/should I just go straight to WordPress and hopefully use WP Search functionality, I am assuming this exists and if it does, how do I use it in WP?

Can people provide the code involved in adding a Search feature and is it customizable?

2) As I am a newbie to WP, how difficult is it to convert one of my HTML/CSS web pages into a WP CMS page by where the admin person can change the text as well as any images embedded in the page?

What php/WP calls are required?

Any decent examples someone can point me to, that demonstrates a HTML/CSS page being converted for WP, to be used as a CMS.

Thanks

+1  A: 

WordPress does implement its own search functionality, I don't think it's worth reinventing it. You can call it with get_search_form and a searchform.php file on your theme's folder to style it:

<?php get_search_form(); ?>

Admins can change practically all of your theme's text with the latest version of WordPress. The menus are customizable, sidebar widgets (and titles) are customizable, and the theme itself can be edited from the admin dashboard. Check this post to learn more about WordPress 3.0.

As for examples, I myself have done this tons of time, but I learnt by reading WordPress' default theme code and css. WordPress Codex is a good resource for newbies, check the "Design and Layout" section, where you can read about template tags, files, and more. This specifical link may come pretty handy: WordPress Lessons - Designing your WordPress Site.

If you have any more questions, feel free to post them on S.O. and good luck with that template!

Fernando
A: 

As suggested use the inbuilt functionality provided by Wordpress:

<?php get_search_form(); ?>

If you don't have a searchform.php page in your theme, WP will simply use its default search form.

<form role="search" method="get" id="searchform" action="http://yourblog.example.com/" >
    <div><label class="screen-reader-text" for="s">Search for:</label>
    <input type="text" value="" name="s" id="s" />
    <input type="submit" id="searchsubmit" value="Search" />
    </div>
</form>

2) As I am a newbie to WP, how difficult is it to convert one of my HTML/CSS web pages into a WP CMS page by where the admin person can change the text as well as any images embedded in the page?

Its not all that difficult, its just requires you to put place each tag in an appropriate place (in a nutshell). The following article on how to create a wordpress theme from scratch should assist you.

Russell Dias