How to edit an already existing Wordpress theme? - wordpress

I know it can be a very dummy question but I'm trying to figure out how I can develop and make changes in an already existing wordpress page (write new code, etc)? Before the changes go online, I must be able to save it somehow and I also need approval from its owner.
What is the best practice for it? It has some paid plugins also, I was thinking that I should create a parallel wordpress site exporting everything from the existing one and work locally.. how does it sound? Any suggestions?
I work on mac and use Docker.
Many thanks in advance!
Cheers!

Have a read on Wordpress Developers relating to Child Themes. Tou can get started here - https://developer.wordpress.org/themes/advanced-topics/child-themes/
This will allow you to activate a child theme over a normal theme and any changes you make to its functions.php will not be overridden when the parent theme updates.
You will just need to maintain the code incase major updates are undertaken on the parent theme.

Related

Do i keep the child theme or move/use parent theme only? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
Not sure its the right place to ask this question,
I have a website that we use mainly for marketing our services, online service bookings and selling bit of products. the site hasn’t been updated since 2017, both the Avada parent and child theme need an update to version 6.2, remove products/WooCommerce and replace the booking system to a new app.
I would like to start managed/update/customise my site but I have no knowledge in coding such as CSS, functions...Etc however I prefer at this point to start with Avada fusion builder as I can easily learn quickly and get results to get my website up and running and then learn coding as I go.
I have installed wordpress on my local ubuntu server using 5.4.1 wordpress/php7.4/apache docker image and MariaDB database Image. i have imported the live site database, content and updates all the plugins and fixed all the small issues.
the site is now up and running on my local server however few things are broken due to the customisation, theme and wordpress version updates. i’m just trying to have a plan what is the best way for me and how to do it.
Before I start update the website, I would like plan how to structure it so it will be easier for me to manage the site in the future. I did some research and it seems that now days for most customisation, you don’t need a child theme as it can do most of CSS customisation and functions by using the WordPress/Avada parent theme and plugin. as explain above the website will have standard pages for the services with style customisation and an online booking system.
The Avada Theme/fusion builder and wordpress has a section to do the custom CSS locally on the page and globally. for the functions codes you can use snippets or similar plugin. if i understand, the customisation are store in the database when you move to a new version of wordpress/theme as well as the plugin store in the content files, meaning when you do your backup you don’t loose it.
if all the customisation are backed up and i don’t need the child theme any more is there a way to copy or use migration plugin to move the customisation from the child theme back to the parent theme? it looks like child theme is not necessary for most websites at it use to be.
My questions are:
Per above scope, future update/upgrades and easy management do I need a child theme or better use parent theme/plugin to do the customisation?
How do I move the child theme configuration back to latest version parent theme?
If keeping the child theme structure, how do I update/migrate/move the old child theme to the new version child theme?
Can i use the old child theme with the new parent theme? or its better/recommended to use the new child theme version.
please check this video, that explain the above, about not using child theme https://youtu.be/30JdAarTAFU
Thank you for your help in advance.
glad to see you actually make an effort to understand this. I will try to answer your questions best I can. I have been working with Avada for last 3 years.
Per above scope, future update/upgrades and easy management do I need
a child theme or better use parent theme/plugin to do the
customisation?
I will always have a child theme. The reason for this is very simple - every site needs to be customised in some way. Yes, page builders help but don't have every option for everything. I use Elementor these days and I believe this is the best builder on the market today, yet I still find myself writing small bits of code to change things that are not supplied with it.
Since you are looking to update your site. You should not remove the child theme because there might be some functions or templates that are used.
How do I move the child theme configuration back to latest version
parent theme?
If there were any custom css you will need to copy it and paste it into the theme 'Custom CSS' option page in the backend of your website.
Any template or functions.php file will need to be moved back to parent theme. However, if you have these files and you moved it back to parent you will overwrite these with any updates to the theme.
I really don't recommend removing child-theme.
If keeping the child theme structure, how do I update/migrate/move the
old child theme to the new version child theme?
You need to update the parent and not the child theme. The whole idea is to never update child theme so none of your files will be overwritten. Also, the core child theme will consist (in most cases) of functions.php and style.css - and both are empty. So if you update the child theme you will be basically removing whats there already.
Can i use the old child theme with the new parent theme? or its
better/recommended to use the new child theme version.
Yes, this is the main reason for having child themes.
Updating Avada
I will assume the version of Avada is 4.0.3 and the newest one is 6.*. The process is very easy:
1. Update WordPress (5.4.1 is the newest today).
2. Download new files from the theme website.
3. Upload the files to parent theme.
4. Login to your admin account on your website. There you should see the installation.
5. Once completed, check all the pages (especially where the builder is present) for any errors.
There might need to make some small changes to the header.php and footer.php
Let me know how it went.

Wordpress Custom Theme - Applying Updates

I haven't been able to look this information up online. Perhaps I am not searching correctly.
I'm looking for information on the best practices. I have a custom built Wordpress theme that I want to implement on several similar websites. On each of the websites, I then intend to implement a child theme so that parts of each site can be customized, while still utilizing the parent theme.
I don't want my parent theme to be downloadable for other users, just myself.
I'm sure that "copying and pasting" the main theme from one of the sites to the others isn't best practice, because if an update needed to be made, I'd have to do it across all the sites. Ideally, I'd like to able to apply an update, and then within the dashboard of each of the sites, just "update" the theme.
What would be the best practice for this? Or am I misinformed about how this all works? Any insight would be appreciated.
You can perhaps try multisite - https://codex.wordpress.org/Create_A_Network.

Customize a WordPress theme based on another one - alternatives to grandchild themes

I have a client who has asked me to develop a WordPress theme based on an existing one. My first thought was to create a child theme, but - his clients will need to have custom themes based on the one he's asking me for.
I know "grandchild themes" are a bad practice - I don't like them, either. I can create a new parent theme based on the original theme, and then, he'll have child themes of this to be released to his clients.
In order to let the final users easily upgrade their child themes, would it be appropriate to make a branch of the existing theme using Subversion? I'm not very familiar with version control, so I'm not sure if this is the best choice. What I need is to have every theme up to date whenever the one it relies on releases a new version.
None of these themes will be listed at WordPress.org, I think.
Sorry for my bad English.
Thanks a lot.
AFAICS, you want to implement vendor branches. Using vendor branches allows you to keep your child themes synced with parents.

Using an admin theme with an already installed theme in Wordpress

All,
I recently bought the following admin theme:
http://themeforest.net/item/white-label-a-full-featured-admin-skin/270758
I also already have the following theme installed and am using it on my website:
http://themeforest.net/item/alyeska-responsive-wordpress-theme/164366
I want to use some features of the first admin theme but not have any issues with the already existing themes that I have installed in Wordpress.
Does anyone know how to use an Admin theme and the features in it without affecting the current shortcodes, css, etc that I'm already using on my own site?
Thanks for any help in advance!
I'm sorry to tell you, but that admin theme you bought is not for WordPress. It's meant to be an HTML start to a backend of a web application.
UPDATE
Alternatively, I'm not sure if you're meaning to take some things from the admin theme and using them in your WordPress theme. If so, please be sure to be more clear in your question as to what you want to do.
No, there are no real WordPress admin themes. The dev cycle changes the admin styles and functions very regularly, with major changes every 3 months or so. This would break any admin themes and makes it a nightmare to maintain, thus no ones does it.
ps. You can change some basic styles like colors/logo and if you know what you doing a bit more. But the link you showed, there is no way, unless you plan on never updated your install , ever.

Do I have to Upgrade WordPress to "pro" if I want to edit the CSS?

I started using WordPress just a few hours ago because I need to develop a couple of blogs to a client. I understand that WordPress is the best solution if you want something fast but flexible. But, the first thing that I wanted to do was just change the font of the post and I didn't find how to do it (for all the posts, because I changed it on this one using the HTML editor). I've read something about editing the CSS, but it turns that I need to buy the Pro upgrade to be able to use the custom design.
Is this the same if I use WordPress in my server?
I need someone to guide me on this one. I need WordPress as customizable as it can be. But, I prefer not to pay! :) Unless that's the only way to do it.
If you use WordPress on your own server, you can do anything you like to it - it's open source. The "Pro" upgrade is just for WordPress blogs hosted on the commercial WordPress.com platform.
Do note that running your own installation means you're responsible for adding plugins, themes, keeping the code up-to-date, etc. That has a cost too, even if it's not money directly out of your pocket.
If you are using wordpress on your own server - you are free to do anything with it. The best way to customize your site then is using a child theme. It will contain your customization, overriding styles from previously loaded parent theme (and/or adding some scripts). You will be able to upgrade parent theme then without loosing your customization (until parent theme owners deprecate something you use, but it must not happen often). There are some plugins for simplifying working with it as well. There are also some easier customization ways, if you want just minor changes - such as Custom CSS in Jetpack plugin, which works in similar way, as far as I know.
If you're using a wordpress.com account, you have less freedom in modifying things, consider using paid custom CSS plugin maybe. Or maybe mentioned above jetpack will do.
Also, as mentioned in other answers - there are wordpress codex, wordpress.org forums, and wordpress stackexchange, they seem to be better place for such questions.
In your wordpress admin section of your site (usually www.yourdomain.com/wp-admin) on the left hand side nav bar, you will find a section called "appearance", if you expand this and click "editor" you can edit all of the files that your current theme uses. A quick warning, if you are doing this on a live server, the changes you make are live as soon as you save them!!
Hope this helps
I'm pretty sure you do not have to pay to customize CSS. Check your server installation... particularly in the folder $wordpress_install_home/wp-content/themes/default.
You should have access to all the CSS files in there.

Resources