Custom WordPress theme for UW School of Social Work. Based on the UW WordPress Theme.
To get started using this theme, all you have to do is install it and the UW WordPress Theme on your WordPress website. Make sure you activate this child theme.
-
Download zip files for both the UW WordPress Theme and this child theme. Please note: You may need to update the name of the zip file. If it includes -master in the file name (e.g. uw_wp_theme-master.zip), you will need to REMOVE the -master part. The file name you upload to WordPress in the next step needs to be uw_wp_theme.zip.
-
Log into your WordPress admin.
-
Go to
Appearance > Themes
and click the Add New button. -
Click the Upload Theme button.
-
Drag and drop the UW WordPress Theme zip file to the file upload area and click the Install Now button.
-
Do not activate this theme! You're not quite done yet.
-
Go back to
Appearance > Themes
and click the Add New button. -
Click the Upload Theme button.
-
Drag and drop the UW School of Social Work zip file to the file upload area and click the Install Now button.
-
Click the Activate link.
You're all set and ready to go!
All of the settings, shortcodes, widgets, and templates from the parent theme are available to you here in this child theme. Additionally, you can extend and override the theme as needed from within the child theme.
Override with caution. If you stray too far from the original theme, it will make updating the parent theme difficult to impossible without also updating your child theme code.
Included are a few tools that can get you started for advanced coding with the theme. Includes
- Gulp
- SCSS css processor
- BrowserSync for testing and local development
- NodeJS and NPM installed before you start. We recommend using the latest versions or any stable supported version.
- A command line/terminal tool
- (Optional) Local installed and running for use with BrowserSync.
-
Copy all the files out of the /dev/ folder and into the main socialwork folder. (delete the /dev/ folder when you're done.)
-
Update the style.scss file with your desired theme information.
-
Open uw_wp_child_theme in your terminal application.
-
Install the node packages using npm.
npm install
-
Open
gulpfile.babel.js
and edit line 20http://your-site.local
to match your Local development site URL. -
Run
gulp
in the command line to start building your files.
Once you've done those steps you can start using Gulp to create stylesheets. Gulp can also be expanded to run other tasks for the theme.
-
Follow Child Theme best practices from WordPress
-
Follow WordPress best practices for theme development
-
Code to the WordPress Coding Standards for PHP, HTML, CSS, JavaScript and documentation
-
Don't code the way we coded just because we coded it that way. Do what makes sense for your situation. Will your code make sense to you in 6 months or 6 years? What about another developer in 6 months or 6 years? Make sure it makes sense!
-
Use the tools that make sense for your project.
-
Document! Keep a record of the changes you are making in the child theme. Make comments in your code so you and other devs know what you were trying to accomplish.
These are some of the tools we've found useful as we've worked on the theme. These are particularly helpful if you are working with at least 1 other dev on the same codebase.
-
Use Local for local development
-
Use VS Code or Sublime Text as your IDE
-
Use the WordPress Coding standards (see #3 above) with PHP_CodeSniffer. This can be difficult to get set up right, but it's worth it once you do.
-
Use some kind of automation workflow tool like Gulp
-
Save your work in git