Home | Webstore
Latest News: OOTP 27 Buy Now - FHM 12 Available - OOTP Go! 27 Available

Out of the Park Baseball 27 Buy Now!

  

Go Back   OOTP Developments Forums > Prior Versions of Our Games > Earlier versions of Out of the Park Baseball > Earlier versions of OOTP: Online Leagues

Reply
 
Thread Tools
Old 03-27-2003, 10:08 AM   #1
Cooleyvol
Hall Of Famer
 
Cooleyvol's Avatar
 
Join Date: Dec 2001
Location: Union City, TN
Posts: 6,383
Script to unzip league files to leaguesite probs.....

I have a script that is supposed to let me zip up my league files and place them on my space, then I would call this script and it would unzip those files to my LeagueSite folder much like the OLS has.

I am getting an error and need help with this.

Here is the script that I have placed in my cgi-bin on my space:
----------------------------
#!/usr/bin/perl

use strict;
use CGI::Carp qw(fatalsToBrowser);

my $Verzeichnis = "/public-html/LeagueSite/";
my $zipfile = $Verzeichnis . "_ubl.zip";

if (-e $zipfile) {
$r = system("unzip -o -q -C $zipfile -d $Verzeichnis");
if ($r==0) {
print "Success!\n";
unlink($zipfile);
}
else {
print "Error " . $r . "\n";
}
}
----------------------------

When I call the script, I get the following error:

Software error:
Global symbol "$r" requires explicit package name at unzipfiles.cgi line 10.
Global symbol "$r" requires explicit package name at unzipfiles.cgi line 11.
Global symbol "$r" requires explicit package name at unzipfiles.cgi line 16.
Execution of unzipfiles.cgi aborted due to compilation errors.




Does anyone have any idea of how to fix this script so that it will work?

Someone put this script on this board sometime back and I am just now getting to where I want to use it.

The name I'm using for my zip file is '_ubl.zip' and I want it to go to the LeagueSite directory.


I'm hoping Andreas sees this.
Cooleyvol is offline   Reply With Quote
Old 03-27-2003, 11:30 AM   #2
Andreas Raht
Administrator
 
Andreas Raht's Avatar
 
Join Date: Jun 2002
Location: Hollern/Stade/Germany
Posts: 8,992
OK, I saw it
Andreas Raht is offline   Reply With Quote
Old 03-27-2003, 11:32 AM   #3
Andreas Raht
Administrator
 
Andreas Raht's Avatar
 
Join Date: Jun 2002
Location: Hollern/Stade/Germany
Posts: 8,992
j/k

Unfortunately I'm no Perl freak.... but I guess you have to initialize the $r with the my statement like

my $r=0;

Or something like that. Don't we have any Perl freaks here?

Ah, and the value in $Verzeichnis is probably not correct. It's the correct path in your web space, but you must provide the complete path on the server! So you need the information what the real path of your web space on that server is. Can be someting like /homepages/cust65243/home...
Andreas Raht is offline   Reply With Quote
Old 03-27-2003, 11:34 AM   #4
Cooleyvol
Hall Of Famer
 
Cooleyvol's Avatar
 
Join Date: Dec 2001
Location: Union City, TN
Posts: 6,383
Will the script used on the OLS not work on our own servers with modifications?
Cooleyvol is offline   Reply With Quote
Old 03-27-2003, 11:37 AM   #5
Andreas Raht
Administrator
 
Andreas Raht's Avatar
 
Join Date: Jun 2002
Location: Hollern/Stade/Germany
Posts: 8,992
No.
What you're showing above is the core of my script and that should work. IF the path was correct.
But the script on the OLS is longer and makes more. What you don't need for a single league.
Andreas Raht is offline   Reply With Quote
Old 03-27-2003, 12:33 PM   #6
jpenn44
Minors (Single A)
 
Join Date: Jan 2002
Posts: 81
Mark,

I would suggest getting ahold of Finn. I think you're using his article script?

If you don't have his contact info, e-mail me and I'll get it to you. He helped me "tweak" my article script, and he is a perl freak.
jpenn44 is offline   Reply With Quote
Old 03-27-2003, 03:03 PM   #7
Red Blow
Major Leagues
 
Red Blow's Avatar
 
Join Date: Apr 2002
Location: Phoenix, AZ
Posts: 404
This is why I pay for web hosting. When it comes to the tech side of what is going on I am more lost than anyone. I mean, if I had a problem understanding Pearl, I would try to contact Steinbeck, not this Finn guy.... unless Finn is John's username.

(Good luck Cooley)
__________________
http://www.nobl.net

This is your father's league.
Red Blow is offline   Reply With Quote
Old 03-27-2003, 04:27 PM   #8
MJohnson
Major Leagues
 
MJohnson's Avatar
 
Join Date: Dec 2001
Location: under an overpass
Posts: 459
I'd also like to use this script for my leage, so if anyone has a solution, please post it here.
MJohnson is offline   Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:28 PM.

 

Major League and Minor League Baseball trademarks and copyrights are used with permission of Major League Baseball. Visit MLB.com and MiLB.com.

Officially Licensed Product – MLB Players, Inc.

Out of the Park Baseball is a registered trademark of Out of the Park Developments GmbH & Co. KG

Google Play is a trademark of Google Inc.

Apple, iPhone, iPod touch and iPad are trademarks of Apple Inc., registered in the U.S. and other countries.

COPYRIGHT © 2023 OUT OF THE PARK DEVELOPMENTS. ALL RIGHTS RESERVED.

 

Powered by vBulletin® Version 3.8.10
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
Copyright © 2024 Out of the Park Developments