Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: hcg_templates
Chris,
There is a way to do a chmod in PHP, though this plugin is intended to make it easier to import and export templates. It’s not really intended so that you could use your favorite text editor to work on your templates remotely. I do all my template work on a local XAMPP install, no need to worry about permissions. Once the template is uploaded to the website, then I use the Textpattern backend to maintain things.
You could setup a cron job that changes the permissions of the files under the _templates directory or write your own PHP script that does the chmod, throw it into _templates and run it when you need to.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
#17 2008-12-15 17:36:00
- ChrisArchitect
- Member

- From: Canada
- Registered: 2007-06-20
- Posts: 25
Re: hcg_templates
thanks for the comments
that’s all fine, it’s just that I wish to use the plugin to export and then commit to a SVN repository. I can download the files from the export, to local machine, where I can do the SVN commits, but then when I’ve got local files ready to be pushed back to the server, I can’t upload them overtop of the export directories on the server because of the permissionss.
in thinking about this now, I suppose I should be just doing fresh svn checkouts in different folders on there and then using the plugin to import … :-S that’ll work, except that the original exports will remain on there
I will see where I get….
thanks!
Offline
Re: hcg_templates
@Chris: You must have the same problem with files and images uploaded using Textpattern right?
Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker
Offline
#19 2008-12-15 20:12:54
- ChrisArchitect
- Member

- From: Canada
- Registered: 2007-06-20
- Posts: 25
Re: hcg_templates
@MattD yeah, same issue ….that hasn’t been an issue for me just yet …it’s the pages/forms/styles I need to backup and commit to version control so that multiple developers can hack away at my site
Offline
Re: hcg_templates
I believe the issue is at the host /php config level. I had the same problem with my old host but I don’t have that problem anymore.
Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker
Offline
Re: hcg_templates
MattD wrote:
I believe the issue is at the host /php config level. I had the same problem with my old host but I don’t have that problem anymore.
Yes, that’s really the case. On my current host, DreamHost, all the files I FTP up or a PHP app creates, I am the owner of, my userid. In some hosting providers, whatever files get created by PHP apps are owned by the Apache process, thus you have to the dreaded chmod 777 to get anything accomplished.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
Re: hcg_templates
Version 0.4 of the hcg_templates plugin is compatible with Textpattern 4.3.0.
Version 0.3 of the plugin will continue to work with Textpattern 4.2.0 and below.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
#23 2010-11-19 06:41:10
- jpdupont
- Member
- Registered: 2004-10-01
- Posts: 752
Re: hcg_templates
Hello Bert,
Could you merge into your plugin the plugins export/import, like Manfre did ?
mem_templates
:-))
Offline
Re: hcg_templates
jpdupont wrote:
Could you merge into your plugin the plugins export/import, like Manfre did ?
mem_templates
When I released hcg_templates, I got a lot of criticism for using mcw_templates as the basis. As in, “I don’t see much difference between the two”, since there were very little changes I had to make to accomplish my goal.
So I don’t want to copy another person’s work, you’ll have to contact Manfre to update his plugin for Textpattern 4.3.0.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
#25 2010-11-19 16:12:00
- jpdupont
- Member
- Registered: 2004-10-01
- Posts: 752
Re: hcg_templates
I don’t ask you to copy the work of Manfre (he copy your work to create his plugin …)
I simply suggest you to improve this good plugin.
you’ll have to contact Manfre to update his plugin for Textpattern 4.3.0.
I’m able to do this update myself. Thanks.
Offline
Re: hcg_templates
Just thinking out loud here Bert but there is one niggley little problem with both your plugin and Manfre’s version. When importing a new template set, whilst they both export the existing set they still leave it in place resulting in the user having 2 template sets installed. I’m wondering if it is possible to delete the existing templates after the export function but prior to the import function??
Stuart
In a Time of Universal Deceit
Telling the Truth is Revolutionary.
Offline
Re: hcg_templates
thebombsite wrote:
When importing a new template set, whilst they both export the existing set they still leave it in place resulting in the user having 2 template sets installed. I’m wondering if it is possible to delete the existing templates after the export function but prior to the import function??
Yes, it could be done but my idea of importing a template is so you can try out a new one. Also, keeping your existing site intact, allows you to copy/paste old code snippets to your new look, should you need to.
Most content based systems let you have more than one template set in the backend, Textpattern is a rare breed where one template is all you can have. Due to naming collisions, deleting everyone’s Pages, Forms and Styles would alleviate the problem I’m having with naming my new templates but it goes against what everybody else does in their backend.
A simple solution to having multiple backend templates is to use the Forms type to designate a template set. On the Pages and Style tab this can easily be avoided by naming the Page “Kubrick” and the Style “Kubrick”, but on the Forms tab, it gets a bit hairy due to all the forms a Template set may need.
The Form type isn’t used for anything, other than to provide a preview for certain types, but the preview doesn’t work all that well anyway. So an article Form has the same meaning as a misc Form, ie. <txp:output_form /> could care less what type a Form is, it just displays it by name, as does any other tag. The name of a Form has meaning only to those tags that have hard coded default forms, another tiny issue. With the release of 4.3.0, where you can expand/collapse types, you can easily have many templates installed and it not be a burden.
Textpattern 4.3.0 is a few tiny steps away from being able to import a Template set without any problems. If any core Templating does surface, it will be probably be in Textpattern 5.0, which I have no idea when it will be released.
But I hear you, it would be nice to avoid collisions and user confusion, but wiping out an existing site’s Templates is not something I would like to do.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
Re: hcg_templates
No problem Bert. I went away and thought about it whilst I did something else and it occurred to me that deleting page templates would not be possible until the individual section requirements had been changed on the “Sections” tab. I’m assuming that Txp’s inbuilt safety system would simply block any attempt.
Not to worry. One day…
Stuart
In a Time of Universal Deceit
Telling the Truth is Revolutionary.
Offline
#29 2011-01-05 19:33:58
- ~cXc~
- Plugin Author

- Registered: 2010-12-27
- Posts: 39
Re: hcg_templates
jpdupont wrote:
Could you merge into your plugin the plugins export/import, like Manfre did ?
mem_templates
hcgtv wrote:
When I released hcg_templates, I got a lot of criticism for using mcw_templates as the basis. As in, “I don’t see much difference between the two”, since there were very little changes I had to make to accomplish my goal.
So I don’t want to copy another person’s work, you’ll have to contact Manfre to update his plugin for Textpattern 4.3.0.
Bert, I understand your point here and I’m in a position very similar to the one you faced when you created your plugin.
Please read this thread post and let me know something.
~cXc~
Last edited by ~cXc~ (2011-01-05 19:36:44)
Offline
Re: hcg_templates
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline