32
1 WORDCAMP KATHMANDU NEPAL 2016

"Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Embed Size (px)

Citation preview

Page 1: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

1

WORDCAMP KATHMANDU NEPAL 2016

Page 2: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Sudeep Balchhaudi @meissudeepLead Theme Developer at eVisionthemes

Page 3: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Ensuring

chances of theme

acceptance in wordpress.org directory

Page 4: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

style.css Heading Component

Page 5: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Component of style.css

Page 6: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

The GPL License

Page 7: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

style.css

Ensure your Theme is GPL

Page 8: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Readme.txt

Declare licenses of any resources included such as external Library, Fonts , Images.

Page 9: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

No Hardcoded Scripts and Style

Page 10: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Minification of Scripts or Styles

Minification is allowed but Presence of main file is required.

Page 11: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

If your theme name is “Bizlight” with a folder name of “bizlight”. Your theme prefix is bizlight

Prefix

Page 12: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

PHP function names. PHP class names. PHP global variables. Action/Filter hooks. Script handles. Style handles. Image size names.

Page 13: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

PHP function names.

Page 14: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

PHP class names.

Page 15: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

PHP global variables.

Page 16: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Action/Filter hooks.

Page 17: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Script handles.

Page 18: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Style handles.

Page 19: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Image size names.

Page 20: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Third-party script/style handles

Exception on prefixing

Page 21: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Validating , Sanitizing & Escaping

Page 22: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Conditions such as “is_email “ can be use to validate the data to be email. Eg: • absint • validate_file

Check User Input

Page 23: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

For sanitizing email field sanitize_email() is used Eg: • sanitize_html_class() • sanitize_key() • sanitize_text_field() • sanitize_title()

Cleaning User Input

Page 24: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Escaping every thing on Output Eg: esc_html() esc_textarea()

Securing Output

Page 25: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

__( 'Hello, dear user!', 'my-text-domain' ); _e( 'Your Ad here', 'my-text-domain' ); Learn the difference between __ and _e

Translation Of Hardcoded Strings

Page 26: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Screenshots (1200x900) Content creation Plugin Territory (shortcodes , contact forms, SEO options etc.)

Some Other Short Listed

Page 27: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Finalizing & Testing

Code HandlingContent Handling

Page 28: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

• wp-config.php • define('WP_DEBUG', true);

• Use of plugin such as • Theme check • Developer

Code Handling

Page 29: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

• Theme Unit Test data https://codex.wordpress.org/Theme_Unit_Test

• Use of plugin such as• FakerPress• Monster Widget

Content Handling

Page 30: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

https://make.wordpress.org/themes/handbook/review/required/https://codex.wordpress.org/Validating_Sanitizing_and_Escaping_User_Datahttp://themereview.co/prefix-all-the-things/ (Justin Tadlock)

Reference

Page 31: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Thank youSudeep Balchhaudi

@meissudeepsudipbalchhaudi.com.np

Do contribution and follow #themereview

Page 32: "Ensuring chances of theme acceptance in wordpress.org directory" on WordCamp Kathmandu 2016

Sudeep Balchhaudi @meissudeep

queries

Do contribution and follow #themereview