Gossamer Forum
Quote Reply
Error extracting .tar :/
Hi,

Got a weird problem here :/

This code, gives me an error (line 111, saying that name() cannot be called on an undefined value, even though css.tar exists Unimpressed)

Code:
my $file;

# Copying Templates.tar to $CFG->{admin_root_path}/.. directory.
$file = $tar->get_file ('css.tar'); # || return $GT::Tar::error;
$file->name("$CFG->{build_static_path}/css.tar"); # || return $GT::Tar::error;
$file->write or return Plugins::User_Templates->error("Unable to extract file: '$CFG->{build_static_path}/css.tar' ($GT::Tar::error)", 'WARN');

Even weirder, is that almost the same cade (about) works fine!

Code:
# Copying Templates.tar to $CFG->{admin_root_path}/.. directory.
$file = $tar->get_file ('luna.tar');
$file->name("$CFG->{admin_root_path}/templates/luna.tar");
$file->write or return Plugins::User_Templates->error("Unable to extract file: '$CFG->{admin_root_path}/templates/luna.tar' ($GT::Tar::error)", 'WARN');

Anyone got any suggestions? Unsure

TIA

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] Error extracting .tar :/ In reply to
Are you definitely using this on version 3? I don't think build_static_path exists before that?
Quote Reply
Re: [afinlr] Error extracting .tar :/ In reply to
Hi,

Yup, its definatly on 3.0.4 (its for my new version of ImageSQL ... literally the last part, which extracts the custom .css files).

Its really weird Pirate

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!