Version: , by Admin (Coder)
Developer Last Online: Nov 2024
Version: 2.2.x
Rating:
Released: 12-08-2001
Last Update: Never
Installs: 248
No support by the author.
Hi everyone.
Here's my newest hack, called Template Backup System (TBS).
This is a very powerful tool for backing up and restoring your templates, especially good for upgrades.
I know you can do this using vBulletin's buil in style manager, but the beauty in this hack is that it exports only templates, and further more - they are saved to individual files in a folder you choose.
Why you ask? This could help a lot when upgrading to a new version of vBulletin. Just like you can compare files using programs such as Araxis Merge or Beyone Compare, you can now also compare templates, and easily keep track of changes that were done between versions.
After you save all changes to the template files, you use this script again only this time in the opposite directions - restoring the templates back into the system.
[hr=white][/hr]
This hack was in testing process for quite some time now, over a week and a half actually.
It has been tested extensively by the magnificent Hooper, and I truly believe it's 99% bug-free.
Most of the features in the hack are actually his ideas, so thanks a lot Rick!
[hr=white][/hr]
Before I continue, I need to say the expanding / collapsing feature will only work on Internet Explorer. It was only tested on it really, but I think the style.display thing is only supported by it.
Anyway, let's install this baby.
First of all, we need to edit admin/index.php a little bit.
Find this:
[high]template_identifier[/high] is the beginning of each template in this group, and [high]Group Name[/high] is the name of this group.
When saying "Using this requires a minimum amount of RAM." I am not kidding. If you don't have enough memory your browser will simply crash when clicking the Check All box. Trust me.
Make sure the folder you are saving templates into is CHMODed 0777, or PHP will not be able to create files in it. Also, the folder is a relative path to the admin folder, not the forums folder!
[hr=white][/hr]
That's all I have to say.
Feedback and feature requests are welcomed as always!
Have fun!
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
I installed this on 2.2.5 as well, it went flawlessly
However, I do have one MAJOR request, that would really make this hack usefull. If this hack had the ability to create folders, with the appropriate templates following those groups, that would make things a lot easier when sorting them out
For example, for the postbit group:
<--- POSBIT Group -->
<----------postbit.html
<----------postbit_attatchment.html
<----------postbit_attatchmentimage.html
And for each template group a new template would be made with the corresponding templates. I suggest doing that for the TBS, chen. It would definatly make this a much more worthy hack for Hotm
Chen: I noticed that on vBulletin 2.2.6 on 4.2.1, this hack doesn't work properly. When you go to export a lot of screwy errors happen, and it doesn't export all of the templates. There is nothing wrong on my part, that I know of, as I've chmodded the folder in which it is exported to, and all the other steps needed.
If you could fix this, it would be most appreciated.
[QUOTE]Originally posted by Henry-RS Chen: I noticed that on vBulletin 2.2.6 on 4.2.1, this hack doesn't work properly. When you go to export a lot of screwy errors happen, and it doesn't export all of the templates. There is nothing wrong on my part, that I know of, as I've chmodded the folder in which it is exported to, and all the other steps needed.
If you could fix this, it would be most appreciated.
[QUOTE]Originally posted by Henry-RS Chen: I noticed that on vBulletin 2.2.6 on 4.2.1, this hack doesn't work properly. When you go to export a lot of screwy errors happen, and it doesn't export all of the templates. There is nothing wrong on my part, that I know of, as I've chmodded the folder in which it is exported to, and all the other steps needed.
If you could fix this, it would be most appreciated.
At the very top of the page when exporting the template I have this text. The colours for the original and the default templates seem to be the wrong way around.
Templates with this color are templates you have created from scratch.
Templates with this color are original templates you have edited.
Templates with this color are the default templates that come with vBulletin.
In the tick box selection list of the templates the colours are correct (green for original and blue for edited and red for new).
The code at the bottom of my cp.css file is this
Code:
/* global and custom color definitions */
.gc { /* global color */
COLOR: darkgreen;
}
.cc { /* custom color */
COLOR: darkblue;
}
.rc { /* custom color */
COLOR: darkred;
}