Take the 2-minute tour ×
Joomla Stack Exchange is a question and answer site for Joomla! administrators, users, developers and designers. It's 100% free, no registration required.

I am using protostar as a template for my 3.3.1 website. I have change the index.php in order to redesign the module positions and to add more of them.

I have just updated my website to Joomla 3.3.3 and... I have lost all my edits. (I have a backup so not the big deal).

So now I am wondering what is the best way to override the index.php in order to don't loose my edits each time I update. It seems that it's not possible to have my template index.php override in the template/protostar/html folder like the other overrides.

I found in a forum that I have to make a copy of the folder protostar and rename it to (let's say) protostarperso. Is that the best way to do it?

Thanks a lot!

share|improve this question

1 Answer 1

up vote 5 down vote accepted

Yes, the best way is to copy the desired template by Joomla admin. Go to Extensions > Template Manager > Templates and click on desired template.

Template Manager::Templates

Then click on Copy Template and enter the new name.

enter image description here

Then make it default and work on the index.php file.

Side notes:

The reason why your changes got overridden is because sicne the initial release of the Protostar template with Joomla 3.0.0, some fixes have been made, and now that every update package contains all updates since 3.0.0, the Protostar template will always be installed from scratch.

Just remember that what you did is a prime example of why editing core files is a bad idea. I know some people to have heavily modify core files and not had backups and therefore getting rather annoyed that they cannot get their changes back.

share|improve this answer
1  
Ahh just removed my answer. Apparently duplicating the style is not he same as copying the template ad will not protected against overrides. Added some side notes from my answer to yours just as an extra –  Lodder Aug 24 at 8:32
    
Thanks so much Fari for the print-screen. I didn't know about this backend feaures. Know, thanks to you, I am protected from loosing my edits! –  Arone Aug 24 at 8:43
    
@Lodder, thanks for the side notes, I will be more carefull with overrides now (I do them sometimes, but not all the times) –  Arone Aug 24 at 8:44
    
@Lodder I have just thought that if I copy the protostar template then I will loose all the fixes that are made in Protostar in the new Joomla version. But I guess there is not other way than either edit core file/make a backup/update/edit core files with previous changes (a bit of hassles, but keep the fixes that are made) OR duplicate the template (simple but I loose the fixes). Maybe there is a third way of doing it? –  Arone Aug 24 at 9:30

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.