Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #397218

    HI.

    I am new to coding with wordpress and I’m very confused about using child themes and customizations.

    To start, it is my understanding that if i do not create a child theme and start customizing elements, this will change the parent enfold files – and then, if an update occurs, all my customizations will be lost – is this correct?

    It is also my understanding that any files in my child folder will over-ride those with identical names in the enfold parent folder (copying via FTP – as files in the child folder are loaded first.

    My confusion arises in that if I don’t copy over any files and I start customizing – exactly what files are being updated/overwritten by these customizations? – The parent enfold ones?

    For example, say I want to adjust my header and I start choosing other options (bigger, different color, etc.). After I click ‘save all changes’ – where are these changes being noted? Nothing is changing in either the functions.php file or the style.css file in the child folder? So where do these customizations live?

    So in order to prevent losing any customizations with a future update, is it then necessary to copy over the header.php file? Or is having the child theme active when I’m making my customizations enough to prevent my customizations from being lost with any future updates?

    Another point of confusion lies in the “import parent settings” option – I tested this function and see that it imports all the customization from the parent settings – yet it doesn’t seem to add any additional files to the child folder. So again i’m missing something as to where these customizations are being written to as they apply to the child theme.

    looking forward to some clarification…and thanks in advance.

    cheers-

    cindy

    #397308

    Hey Cindy!

    Anything changed within the Enfold Theme Options will survive theme updates, these changes don’t affect the theme files at all, they create entries secured in the database, so you don’t have to worry about it when updating.

    The “customizations” that get lost (if not using a child theme) are the ones that require direct file editing to the theme core files, for example editing the header.php to change something in the Header that is not available via Theme Options.

    Best regards,
    Josue

    #400349

    dear josue,

    thanks for your reply.

    So based on what you’re saying, if i add a shortcode to a text block in the AVIA layout builder, this too would be saved to the wordpress database and should be safe from future updates?

    additionally, i’m a bit confused by the 3 css file choices:

    – enfold.css
    – style.css (child theme)
    – quick css

    enfold.css
    can you explain what this css covers? and where it is located?

    style.css
    if i’m working in a child theme and i want to adjust the css of an element it seems a quick fix to add some code to the style.css file in the appearance > editor > style.css file. and this would be safe from updates as it lives in the child folder. done.

    That said, if i want to adjust the css styling for an element and that element’s css resides in say the ‘layout.css’ – does the style.css in the child theme folder take priority over this file and all other .css files in the parent folder or do i need to copy the ‘layout.css’ file to my child folder and make adjustments on this ‘layout.css copy’?

    quick css
    i see on the forum various replies suggesting adding brief css changes in the quick css field (styling tab). based on your reply i assume any css changes made via quick css are also recorded in the main WP DB and so remain safe from future updates. is this correct? or are they written to the style.css file in the child folder when you are using a child theme?

    thanks in advance for your reply.

    cheers-

    cindy

    #400366

    Hi Cindy!

    So based on what you’re saying, if i add a shortcode to a text block in the AVIA layout builder, this too would be saved to the wordpress database and should be safe from future updates?

    Correct, that would be part of the Post content (saved under wp_posts table in the database).

    Regarding the CSS questions:
    1. enfold.css, is the dynamic stylesheet (if using a child theme the name will change, ex: enfold-child.css) Enfold generates to store your theme Styling settings and Quick CSS, it is located in /wp-content/uploads/dynamic_avia/.

    2. style.css, here’s where you would put your custom CSS, to change something from one of the Enfold CSS files (base.css, layout.css, etc) you’d just need to copy the part you want to edit and perhaps add some !important to it to make sure it gets prioritised, for example to change the main-title styles (from layout.css):

    .title_container .main-title {
    margin: 0;
    font-size: 24px !important;
    position: relative;
    z-index: 2;
    min-height: 42px !important;
    line-height: 3em !important;
    top: 0;
    font-weight: 900 !important;
    }

    3. Correct, that data is saved in the DB however if you are using a child theme it is recommended to use style.css instead, because sometimes custom CSS code can contain typos that would affect the rest of the dynamic stylesheet (refer to 1).

    Cheers!
    Josue

    #401577

    you are a god – thank you!

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘child theme confusion’ is closed to new replies.