Plugin
WordPress Project Setup Guideline

Foundation For Excellence: The Standard WordPress Enterprise Project Guideline

The WordPress New Setup:-

  1. Always Download the latest version of WordPress from WordPress.org and use it. (Link-https://wordpress.org/download/)
  2. If you are working on a Staging server like a Beta server then make it a project folder inside the WordPress Folder.

    E.g:- For xyzbeta server- https://xyz beta.com/wordpress/projectname
    E.g:- For Local server- xampp/htdocs/wordpress/projectname
  3. Make a new Database and the database name should start with the “wp_” prefix. E.g :- wp_projectname
  4. Set Username as “wpadmin” and set Strong Password like “3g%rQ14$AC^Y”.
  5. If the client doesn’t give an email address then use your testing Email address.
  6. If any updates are required for the themeplugins of WordPress then first update it and then start development.
  7. If Clients provide a purchased WordPress Theme then it’s good no need to change anything. but if we use any default WordPress Theme then we need to customize it.

    Select one of themes from default WordPress Themes and remove remaining all themes.
0_Q4lzkEeBSXtqzwRD
  • Change theme name of Selected theme to “devtheme”.
  • E.g: “Twenty Twenty One to Dev Theme”
  • “twentytwentyone to devtheme”
  • “Twenty_Twnety_One” to Dev_Theme”
  • Change screenshot.png image with your customized theme screenshot.png in the theme folder.
DEVTHEME

CSS And JS

  1. Check out the wp_enqueue_style() function for adding custom CSS files into WordPress.

    Reference Link:

    https://developer.wordpress.org/reference/functions/wp_enqueue_style/
  2. Where to place a custom.css file inside the theme folder?

    wordpress/projectname/wp- content/themes/themename/assets/css/custom.css
  3. Open a function.php file and add wp_enqueue_style() function to call custom.css files into WordPress.

    Path of function file: wordpress/projectname/wp-content/themes/themename/functions.php

    E.g:- wp_enqueue_style( ‘custom-css-style’, get_template_directory_uri().’/assets/css/custom.css’, array(), ‘custom_css’ );
  4. Check out the wp_enqueue_script() function for adding custom JS files into wordpress.

    Reference Link

    https://developer.wordpress.org/reference/functions/wp_enqueue_script/
  5. Where to place a custom.js file inside the theme folder?

    wordpress/projectname/wp-content/themes/themename/assets/js/custom.js

  6. Open a function.php file and add wp_enqueue_script() function to call custom.js files into WordPress.

    Path of function file:

    wordpress/projectname/wp-content/themes/themename/functions.php
    Open a function.php file and add wp_enqueue_script() function to call custom.js files into WordPress.

    Path of function file:

    wordpress/projectname/wp-content/themes/themename/functions.php

    E.g:- wp_enqueue_script( ‘custom-js’, get_template_directory_uri() . ‘/assets/js/custom.js’, array(), ‘custom_js’ );

Create Widgets:-

  1. Check out the register_sidebar() function for how to create widgets.

    https://developer.wordpress.org/reference/functions/register_sidebar/
  2. Open a function.php file and add register_sidebar() function to create widgets.

    Path of function file:
    wordpress/projectname/wp-content/themes/themename/functions.php

    Reference Link:
    https://developer.wordpress.org/reference/functions/register_sidebar/

Create Custom Template

  1. Create a custom template

    Reference Link:
    https://developer.wordpress.org/reference/functions/register_sidebar/

    Create your template file (your_template_name.php) inside the theme folder wordpress/projectname/wp-content/themes/themename

    Copy code from page.php file and paste it into your_template_name.php file.

    Path of page.php file wordpress/projectname/wp-content/themes/themename/page.php
    Then add a Template code on top of the your_template_name.php file.

    E.g:- Template Name : Full_Width_Page

    Note: Don’t leave space between words of your Template Name

General Rules To Follow

  1. Maintain theme structure in all files and templates.
0_1b15YseH-HY2Lrqb
  1. Remove unused plugins, images.
  2. Don’t use outdated plugins, use only the latest plugin which is compatible with your version of WordPress.
0_M1rVrxzuYCXlSli_
  1. Change all default fonts from style.css and replace them with PSD / XD / FIGMA fonts or project-related fonts.
  2. Always check all forms working properly or not like: email sending, validation, email format, etc.
  3. Always Create code Using WordPress Standard Like WordPress Hooks, Filters, Functions.
  4. Before Project submission checks properly and remove unnecessary code, commented code, and commented CSS.
  5. When you start work on any existing project, get backup of that project before starting working or customization.
  6. WooCommerce :
  • Maintain structure like theme structure.
  • Do not make any changes in plugins files.
  • Customized WooCommerce files in your theme folder.
  • Follow the below steps :
  • Create a WooCommerce folder in your theme folder.
  • Copy required files of the “templates” folder from the WooCommerce plugin and paste them on the WooCommerce folder in your theme folder.
  • Now you can customize and update files in the WooCommerce folder of your theme.
  1. Security :
  • When Project Is Completed Then Add Wordfence Plugin For Security.
  • Follow Below Steps :
  • Scan The Whole Site Using Wordfence Plugin.
0_SdbDqh5rhp3jGXJS
  • Enable brute force protection
0_8C7b0VCmUmBEI1JM
CONTACT US !