HTML/CSS for WordPress

40
HTML/CSS for WordPress Presented By: Kanchha Kaji Prajapati (Creativekaji) +

Transcript of HTML/CSS for WordPress

Page 1: HTML/CSS for WordPress

HTML/CSS for WordPress

Presented By: Kanchha Kaji Prajapati (Creativekaji)

+

Page 2: HTML/CSS for WordPress

Kanchha Kaji Prajapati (creativekaji)

Facebook: www.facebook.com/creativekaji Twitter: www.twitter.com/creativekaji

Email: [email protected] Website: Creativekaji.com

Page 3: HTML/CSS for WordPress

Why HTML/CSS on WordPress? Most of our HTML/CSS is converting on WordPress

To reduce double work

To reduce time and effort of designer and developer

To Know something about WordPress

Page 4: HTML/CSS for WordPress

Setup WordPressDownload WordPress from https://wordpress.org/

Page 5: HTML/CSS for WordPress

Create a database

Page 6: HTML/CSS for WordPress

Extract on your local server

Page 7: HTML/CSS for WordPress

Finally, Run it from browser and setup WordPress

Page 8: HTML/CSS for WordPress
Page 9: HTML/CSS for WordPress
Page 10: HTML/CSS for WordPress

What is Underscores? A startup theme

Released in 2012 by automattic

Maintained on Github

Collective knowledge of the WordPress.com Theme Team

1,000 hour head start

Page 11: HTML/CSS for WordPress

What it isn't

Not a plug and play theme

Not a parent theme

Page 12: HTML/CSS for WordPress

But Why Underscores?

Page 13: HTML/CSS for WordPress
Page 14: HTML/CSS for WordPress

Fine work of WordPress maker team

Come up with default pages saves hours

Less overhead than a full theme

Most of developer are using it

Reduce time and effort

It will become your own theme

Page 15: HTML/CSS for WordPress

Download Underscores from http://underscores.me/

How to get Underscores theme?

Page 16: HTML/CSS for WordPress

Extract zip file and paste it on theme file directory

Page 17: HTML/CSS for WordPress

Activate new theme form backend dashboard

Page 18: HTML/CSS for WordPress

New Website first look… Not so cool hum.

Page 19: HTML/CSS for WordPress

Expecting something like this?

Page 20: HTML/CSS for WordPress

HTML Structure 1 – Header & Navigation

Example

Page 21: HTML/CSS for WordPress

HTML Structure 2 – Site Content, Primary and Secondary

Example

Page 22: HTML/CSS for WordPress

HTML Structure 3 – Post list (article)

Page 23: HTML/CSS for WordPress

Example

Page 24: HTML/CSS for WordPress

HTML Structure 4 – Sidebar (Widget list)

Example

Page 25: HTML/CSS for WordPress

HTML Structure 5 – site footer

Example

Page 26: HTML/CSS for WordPress

Some major working files for designers• functions.php Enqueue style and js files

• header.php Write header contents

• footer.php Write footer contents

• screenshot.png To recognize your theme in theme list

• style.css Main CSS file

Page 27: HTML/CSS for WordPress

Styling default elements – style.css

• Typography• Color• Buttons• Navigation• Form fields• Widgets• Post and page• Archive page• Comment section• And more . . .

Page 28: HTML/CSS for WordPress

Does have any alternative of _S?

Sage by Roots Bones Quark Html5blank _tk

Blankslate Responsive Twenty Sixteen Backbone PageLines

The answer is YES, & may be these;

Page 29: HTML/CSS for WordPress

Now, let’s talk about child theme

Page 30: HTML/CSS for WordPress

If you modify a theme directly and it is updated, then your modifications may be lost

Can speed up development time.

A great way to learn about WordPress theme development.

WHY SHOULD YOU USE A WORDPRESS CHILD THEME?

Page 31: HTML/CSS for WordPress

1. The child theme directory2. style.css3. functions.php

How to Create a Child Theme

Page 32: HTML/CSS for WordPress

Tips: Do not style, if the parent theme have options Let’s try to use enqueue_style rather than @import CSS.

Page 33: HTML/CSS for WordPress
Page 34: HTML/CSS for WordPress

Now, Let’s do practical

Page 35: HTML/CSS for WordPress

CREATE CUSTOM TEMPLATE

TASK:

Page 36: HTML/CSS for WordPress

1) Create a blank file in theme directory on named template-home.php

2) Open the file and write a template name

Let’s follow these steps:

<?php

/** * Template Name: Home Page * * @package wpsite * */

Page 37: HTML/CSS for WordPress

3) Go to dashboard and add a new page, choose template and publish it.

Page 38: HTML/CSS for WordPress

4) Choose added page as static page for front page and save changes

Page 39: HTML/CSS for WordPress

5) Visit your new front page.

Now, you can work as normal Slice in WordPress .

COOL !!!

Page 40: HTML/CSS for WordPress

THANK YOU

ANY QUESTION?