PDA

View Full Version : delete and rename template via product command


nasser71
11-08-2006, 07:57 AM
hi
I need to know what code should I use to rename a template via a product and what is the code that I should use to delete a template also via product.

thanks

Paul M
11-08-2006, 08:02 AM
The product system wasn't designed to delete or rename templates, and I can't really understand why you would ever want or need to - what are you trying to do ?

nasser71
11-08-2006, 10:46 AM
thanks for your reply

i have made a code to hide bbcodes like code php quote and html codes
im traying to make a product to rename the orignal templates thin make a new template
and for the uninstall the product the product wil delete the templates and rename the old templates

Antivirus
11-08-2006, 04:18 PM
I don't understand why you need to rename or delete any templates, as doing so could render calls to those tempLates by vbulletin to cause errors... but if you absolutely had to, I suppose you could write a SQL query and include it in your product's install code.

mfyvie
06-01-2007, 02:21 PM
I think what you meant to say is that you'd like to remove the contents of a given template in memory, because your plugin is already executing a different plugin. I had exactly the same requirement and I solved it like this (change template name as appropriate):

$vbulletin->templatecache['modifyavatarbit'] = "";