Gossamer Forum
Home : Products : Others : Gossamer Community :

Share globals and templates between Community and Linksql

Quote Reply
Share globals and templates between Community and Linksql
Hi there,

I am just starting to update all of my templates after upgrading to Community V 1.1.1 and Linksql V 3.2.0

How can I share some of the information between both installations (their respective templates are in different places). Alot of the information is going to be common between them.

1) How do I use only one Template Globals file for both Community and Linksql?
2) How do I use only one Include_footer template file for both Community and Linksql? (as an example).

It would just really help me get everything down to messing with the minimum amount of files, and really help to role out new content.

Any tips appreciated.
Piers
Quote Reply
Re: [Piers1] Share globals and templates between Community and Linksql In reply to
Hi,

I don't think you can Frown

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Share globals and templates between Community and Linksql In reply to
How dull.
I guess I could run a cron job every day and just copy the common files over? This doesn't need to be an immediate change, just an attempt to only change one set of files in one area.

Cheers,
Piers
Quote Reply
Re: [Piers1] Share globals and templates between Community and Linksql In reply to
Hi,

What kind of globals are they? If they are stuff like:

$DB->table(xxx)

...then doing something like that just wouldn't work - as they use seperate .def files =)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Share globals and templates between Community and Linksql In reply to
Really simple static stuff (think like the contents of the language file) that will not change regularly.
i.e. I might want to have a footer added to all emails sent out from Community and Links which changes once a month. e.g. June special deals, look at this page....
Quote Reply
Re: [Piers1] Share globals and templates between Community and Linksql In reply to
Hi,

If they are *really* simple - you could probably do it with a cronjob:

cp /path/to/glinks/admin/templates/default/local/globals.txt /path/to/secure_data/templates/default/local/globals.txt

Hope that helps - I'm off to bed ;)

(may be worth running that command via Telnet/SSH, to make sure it works =))

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Share globals and templates between Community and Linksql In reply to
Thanks Andy,

That's what I'm doing for now...and it works ok,

Cheers,

Piers
Quote Reply
Re: [Piers1] Share globals and templates between Community and Linksql In reply to
You could probably use template inheritance to share the globals and include files. That would involve creating (or modifying) the .tplinfo file in the template directory to tell it to inherit files from another directory; something like (for glinks):
Code:
{
inheritance => ['../browser', '/path/to/other/template/set']
}

The other option if you're using a *nix system is to use hard links.

Adrian

Last edited by:

brewt: Jul 31, 2008, 3:42 PM