Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • johannesdach Friend
    #182670

    Hey guys,
    I generally understand that the templates are there to override the core joomla files, but what if I want to override the joomlart template which overrides the core files? I don’t want to edit the css files of the joomlart template because if I update or reinstall them they will be lost. Jreviews has this beautiful feature where you can set up a template folder and use a single “custom_styles.css” file which than overrides the jreviews main template IF there are custom styles while otherwise using the main template. Is there a simmilar option available for ja t3 themes?
    Regards,

    Johannes

    TomC Moderator
    #474605

    What you need to do is set up Template overrides.

    Template overrides are a good method for changing the way Joomla shows component and module output without changing the core Joomla system code. This is important because it means that as/when Joomla is upgraded to new versions, you will not have to repeat the changes you made.

    Read more on Understanding Output Overrides

    Also see: Layout Overrides in Joomla

    Lastly, the Official HOW TO Override the Output from the Joomla Core

    Hope some of this helps.

    TomC Moderator
    #474606

    Here is a video tutorial that may also be of assistance to you . . . .

    johannesdach Friend
    #474609

    I think you didn’t understand. I don’t want to override the core component with my own theme. I want to override the theme ja_mendozite itself. Hav a folder outside the template /templates/ja_mendozite/ that overrides not the core files, but the template ja_mendozite.

    TomC Moderator
    #474610

    <em>@johannesdach 348422 wrote:</em><blockquote>I think you didn’t understand. I don’t want to override the core component with my own theme. I want to override the theme ja_mendozite itself. Hav a folder outside the template /templates/ja_mendozite/ that overrides not the core files, but the template ja_mendozite.</blockquote>
    I don’t think I misunderstood . . . read what I wrote again . . .

    <blockquote>Template overrides are a good method for changing the way Joomla shows component and module output without changing the core Joomla system code. This is important because it means that as/when Joomla is upgraded to new versions, you will not have to repeat the changes you made.</blockquote>

    In other words, by setting up Template overrides, you are making changes to ONLY the template itself and NOT to the Joomla core files. Therefore, if/when you update Joomla – be it with a latest security update or an updated version – the update will ONLY affect the Joomla core files and NOT the elements for which you created modifications/customizations within your respective Template override(s).

    Make Sense?

    johannesdach Friend
    #474611

    No. I don’t want to be able to update joomla. I want to save my changes I did to mendozite to be saved when I reinstall it for some reason.

    Usual overrides work like this:

    /templates/rhuk_milkyway/html/com_content/article/default.php
    overrides
    /components/com_content/views/article/tmpl/default.php

    But I want to override the template itself so that:

    /templates/my_template/themes/green/css/template.css
    only PARTIALLY overrides
    /templates/ja_mendozite/themes/green/css/template.css

    Which means that if /templates/ja_mendozite/themes/green/css/template.css has the following 2 classes

    #ja-topsl3 p.readmore a:active {
    color: #799a51
    }
    #ja-topsl2 .item:hover .itemDate {
    border-color: #799a51
    color: #799a51
    }

    But /templates/my_template/themes/green/css/template.css has the following

    #ja-topsl3 p.readmore a:active {
    color: black;
    }

    The ouptut would be a mix of both, #ja-topsl2 from ja_mendozite and #ja-topsl3 from my_template because /templates/ja_mendozite/themes/green/css/template.css would be the fallback theme so that the result would be:

    #ja-topsl3 p.readmore a:active {
    color: black;
    }
    #ja-topsl2 .item:hover .itemDate {
    border-color: #799a51
    color: #799a51
    }

    Is that possible?

    johannesdach Friend
    #474612

    So basically an override over the override, should we call it an ueberride??? 😉

    TomC Moderator
    #474615

    <em>@johannesdach 348425 wrote:</em><blockquote>So basically an override over the override, should we call it an ueberride??? ;)</blockquote>
    Well then, you can either set up a separate Template override for EACH “override” you would ever want to revert back to, or you can simply create back up files for the particular modifications you make at any given time and keep them in a secure place for future reference/overwrite (if need be).

    johannesdach Friend
    #474619

    Ok, I didn’t understand how the first option would work out. I have done the second option, keeping a file where I wrote down all the changes I have done so far so I can apply them again if the need arises but that is not as practical. This however would be great: If I understand overrides correctly the file which is loaded tat last defines what gets displayed. So if every page would load a custom.css file at the very end, this single file could hold all css changes. It is not practical for writing a template obviously because than the load would be unbearable, but if it only contained minor customizations that would be managable. That would be awesome. Still, could you explain what you were saying with option one? Thanks

    Ninja Lead Moderator
    #474802

    <blockquote>So if every page would load a custom.css file at the very end, this single file could hold all css changes.</blockquote>

    Its a good idea but sorry we wont be able to provide support for this for now.

Viewing 10 posts - 1 through 10 (of 10 total)

This topic contains 10 replies, has 3 voices, and was last updated by  Ninja Lead 11 years, 11 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum