Dernières publications

Anniviers Ski

Cette application vous facilitera la vie lors de vos journées de ski dans le Val d’Anniviers en Valais. Elle couvre les stations de Chandolin, Grimentz, St-Luc, Zinal et Vercorin (disponible pour l’instant seulement sur iPhone).
Voici la liste complète des fonctionnalités:
- L’horaire des bus navettes (prise en compte haute saison/ basse saison et jours fériés)
- Le plan des pistes et des installations ouvertes en temps réel
- Webcams
- Bulletin météo et prévisions avalanches pour Anniviers
- Multilingue (fr, de, en)
- Liste des numéros utiles

AnniviersSki_screenshoot1 AnniviersSki_screenshoot2 AnniviersSki_screenshoot3

Anniviers Ski - CreaSystem Sarl

Create a Website with Wordpress

My first article is surprisingly not about Java but .. Wordpress. Although I am not a Wordpress expert, I founded it so surprisingly simple to set up a Website with this tool.

Wordpress is a free opensource project which allow you to create a Blog very easily. With only a few changes, you can turn Wordpress into a CMS, which allow you to create a full featured website with it.
Because I have found all parts of informations disseminated in many websites, I have decided to group this Information in a step-by-step tutorial, which need no programming skills, to use Wordpress like a CMS and create and deploy a website with it.

Step 1 Installation

You can install Wordpress on your local computer (for test purpose), or remote with FTP on your Internet provider.

Download Wordpress

Go to Wordpress and download the latest version (This tutorial was written with wordpress 2.8.4). You can install it in french from fr.wordpress.org.
Once you have dowloaded the zip file, extract it on your local computer.

Follow the 5 minutes guide to install it

Follow the 5 minutes guide and make sure you have Wordpress up and running. Don’t forget to change the default password

Customize the appearance

Select the appearance menu and click « Add New Themes ». Search a new Theme, Install it and activate it.

Screenshoot Wordpress Add New Theme

Screenshoot Wordpress Add New Theme

Step 2 Create static and dynamic pages


Create a home page

Go to the Page Menu and open the default about Page. Rename it with the title Welcome and uncheck the box « Allow Comments ». Click on update page to save your changes.

Screenshoot Wordpress Disable comments

Screenshoot Wordpress Disable comments

To activate it, go to the menu Settings -> Reading, then Set the Font page Display to « a static page » and choose « Welcome » and save your changes.

Screenshoot Wordpress welcome page

Screenshoot Wordpress welcome page

Go to your Website and make sure you get the welcome page.
Note: the message « Comments are closed. » is not really nice on a home page, but don’t worry, we gonna make it disappear later on in this tutorial. Just keep going ….

Create a page for a blog or news

To create a dynamic page where you can post your articles or news, go to « Pages » -> « add New ». Create an page with title « News » and fill the body with a welcome message on the news page. Leave the « Allow comments » checkbox selected this time, we authorize our reader to give us feedback.

Screenshoot Wordpress News Page

Screenshoot Wordpress News Page

When it’s done, publish the News page and go to the menu « Settings » -> « Reading » and select for the posts page : « News ». Save your changes and go to your website to see the News pages. You should see an post called « Hello World! », which is a dummy article created by Wordpress during the installation.
If you don’t see the News page’s link, it’s may be that your theme does not display your page’s list per default. To display a navigation links to your pages, just go the menu « Appearance » -> « Widgets ».

Screenshoot Wordpress Widgets

Screenshoot Wordpress Widgets

Drag the « Pages » widget on your sidebar.

Screenshoot Wordpress Pages Widget

Screenshoot Wordpress Pages Widget

This time you must see the links to your pages.

Remove the comments on static pages

If you don’t want to see comments on your static pages (like the homepage), you need to remoce them by opening the page.php of your theme located in /wp-content/themes/yourtheme/page.php.
Replace the line:

<?php comments_template();?>

With this one:

<?php if (!is_page()) comments_template();?>

Save and upload the file to your server, go to your home page and yeah ! the comments are gone !

Add a contact form

Go to the « Plugins » menu and click on « Add New ». Search for « Contact Form 7″, install it and activate the plugin.
Click on the new « Contact » menu and customize your contact form. Check that you have entered a valid email address under « mailTo ». Copy the code generated on the top on the page into the clipboard.

Screenshoot Wordpress contact form

Screenshoot Wordpress contact form

Now that we have installed and configure a contact form, we need to create a new page to display it. Click on « Pages » -> « Add New ». Name it « Contact », put a welcome text in the body and paste the content of the clipboad.

Screenshoot Wordpress page with contact form

Screenshoot Wordpress page with contact form

Don’t forget to disable comments. Click on publish and test your contact form.

Step 3 Customize you website


Change the order of page Links

If you look at our Pages links on the home page, you should see first « Contact », « News » and « Welcome », which is not really the order we want. This is because Wordpress sort it alphabetically per default. To change this, edit your « News » page and set the Attribut order to « 1″ on the right of the page. Set it to « 2″ for the « Contact » page and leave it to « 0″ for the « Welcome » page.

Screenshoot Wordpress page order

Screenshoot Wordpress page order

You don’t see any change ? No worries, you problably need to set the sorting option of the « Pages » widget. Go to « Appearance » -> « Widget », click on the arrow of Pages and set the Sort by to « Page order ».

Screenshoot Wordpress Pages widget

Screenshoot Wordpress Pages widget

Save it and now your links are correctly sorted!

change the url’s style

If you look at the url of your website, they don’t look very explicit : http://www.yoursite.com/?page_id=9 for your contact page for example. To change this, go to « Settings » -> « Permalink » and set this Custom Structure: /%postname%/.

Screenshoot Wordpress Permalinks

Screenshoot Wordpress Permalinks

Now your Url will use the name of your post: http://www.yoursite.com/contact

Conclusion

Congratulation, you are done ! As you see, it’s pretty simple to use Wordpress like a CMS, and customize it to your needs.
This tutorial will be soon updated with these sections:

  • Multilangage support
  • Search Engine Optimization (SEO)
  • Sitemap

Stay tuned !
Logo CreaSystem mini David Gerber