Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

simle template parse question?

Quote Reply
simle template parse question?
Can any

Code:
my $error_msg = "don't do that.";

print Links::Build::build('detailed', { %$rec, %$globals, error => $error_msg });

print Links::SiteHTML::display('detailed',{ %$rec, %$globals, error => $error_msg });

Can anyone explain why the first one won't pass/print the error and the second one will?

Thanks,
mp
Quote Reply
Re: [Swaylock] simle template parse question? In reply to
Hi,

I'm not sure Links::Build::build() is quite setup the same was as Links::SiteHTML::display().

For the first one, I would try;

Code:
$rec->{error} = $error_msg;
print Links::Build::build('detailed', { %$rec, %$globals } );

I'm not sure if there is another way to do this... but its worked well for me on several occasions :)

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 | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] simle template parse question? In reply to
Andy,

That did it!

Thanks so much for the help.

Mike