The latest error I am receiving is:
<ERROR:
Missing or Invalid Selection!
Use your browser's [BACK] button and try again.>
modified script:
#!/usr/bin/perl
use CGI::Carp qw(carpout fatalsToBrowser);
# CONFIGURE THE SCRIPT:
#
# Change these sample paths to the actual paths on your server:
# Your Unix system date and sendmail commands
$dateCmd = '/bin/date';
$mailCmd = '/usr/lib/sendmail';
# Your E-Mail address - note mandatory backslash before \@
$myMail = "webmaster\@xx.xx.47.13/";
# Unix path to bbmat directory
$bbmatDir = "/usr/home/user_name/filename/bbmat";
# URL to the bbmat directory
$bbmatUrl = "http://xx.xx.47.13/bbmat";
# URL to bbmat.cgi
$scriptUrl = "http://xx.xx.47.13/cgi-bin/bbmat.cgi";
# Link to exit from manager
$exitUrl = "http://xx.xx.47.13/";
# Here you define one or more forums using a keyword and path to
# the directory where each can be found. You will create the directories
# in a later step. The 'how2bbm.txt' document will explain what to place
# there. For simplicity you can use your chosen keywords as the names
# of the directories as in the example. Use short alphanumeric keywords.
%Script = (
'OZ','/usr/home/user_name/filename/OZ',
);
# Select one of the above keywords as the default forum.
$script = 'OZ';
# If BBMATIC frame(s) will be nested inside your own frames set to 'Y'
$nested = 'N';
# OPTIONAL - YOU CAN EDIT THESE VARIABLES IF DESIRED:
# You will probably want to use your imagination and list some
# inappropriate words that you want to exclude from being posted.
@badWords = ("xx*","xx");
# Maximum length in CHARACTERS to DISPLAY on the main page
# for subjects and followup comments.
$maxSubj = 250; $maxComm = 60;
# Set maximum length in CHARACTERS for a subject or comment. If
# exceeded, the text will be truncated. Default is 5120 = 5KB.
$maxLength = 5120;
# If you want a signature file attached to mail messages,
# uncomment the next line and enter the correct Unix path ..
# $MYSIG = "/home/yourpath/to/mysig.txt";
# otherwise uncomment the next 2 lines and replace with your info ..
$myName = "Powdork";
$homeUrl = "http://xx.xx.47.13/";
# If you don't want to backup the bbm.dat file, set $bakFlag to 'N',
# otherwise set bakTime, bakMax and bak Dir in the 'if' loop ..
$bakFlag = 'Y';
if ($bakFlag eq 'Y')
{ $bakTime = 2; # days btwn backups
$bakMax = 7; # days to keep backups
# Unix path to backup directory
$bakDir = "/usr/home/user_name/filename//bak";
The actual program was to large to post but I can if needed. I doubt thats where the problem lies.
I use cute ftp 4.0 and uploaded in ascii mode. I am very new to unix paths so that is what I suspect is the problem.
Thanks
[edited by: jatar_k at 4:40 pm (utc) on Aug. 25, 2003]
[edit reason] removed repetitive code see Charter [/edit]
That looks like a handled error, any idea what the true error is or what is actually missing?
Thanks for the link to the charter.
I just want to learn to fish.:)
A message that has been handled by an internal subsystem of the script.
>How do I get to the unix prompt?
Ask your host if you have ssh access. Alternativly ask them where sendmail is located. Usually /usr/sbin/sendmail or /sbin/sendmail
> When I am at my hosting account control panel I go to 'file manager'. The breadcrumbs say 'home/user_name/' so I included that. I assumed the '/usr' was important so I kept that from the original script. Is the user_name necessary or is that just for the control panel access?
Don't assume things. Assuming things wastes time. Only include what you know. Again if you have ssh access the home directory will be shown if you type 'pwd' after you login. Alternativly ask your host. The home direcory is usually /home/user_name/ .
Here is the part within the script that must be 'handling' the message.
# ensure a valid script is selected
if ($Script{$Form{'script'}})
{ $script = $Form{'script'};
}
$scriptDir = $Script{$script};
$BBMCFG = "$scriptDir/bbm.cfg";
$BBMCNT = "$scriptDir/bbm.cnt";
$BBMDAT = "$scriptDir/bbm.dat";
$BBMOLD = "$scriptDir/bbmold.dat";
$BBMFLK = "$scriptDir/bbm.flk";
$BBMTEMP = "$scriptDir/bbmtemp.html";
open (CFG,"<$BBMCFG") ¦¦ &endIt ("Missing or Invalid Selection!");
@bbmCfg = <CFG>;
close (CFG);
and from the installation instructions
Create a directory (777) for each forum using the directory paths
and names you specified in 'bbmat.cgi' for the %Script variable. You
may want to make these subdirectories of the 'bbmat' directory
such as:
/bbmat/recipe/ and /bbmat/decapitation/
Place each set of 'bbm.dat' (666), 'bbm.cfg' (644), 'bbm.cnt' (666),
'bbm.flk' (666), 'bbmtemp.html' (644) and 'bbmold.dat' (666) into the
corresponding directory. These directories MUST be world-writeable!
end
Which I think is what I've done. Except, How do I make the files world writable?
Missing or Invalid Selection!
what exactly were you trying to do when it was generated?
Any idea if it is missing or if it is invalid?
Which actual script is it coming from?
Is it the one you pasted or is it something else?
First you need to understand exactly where the error is from and then move on to the other questions.
Ip should be fine I would think.
Any idea if it is missing or if it is invalid?
No
Which actual script is it coming from?
I'm not sure what you mean. It's being generated by the part of the script listed in msg 6.
Is it the one you pasted or is it something else?
Yes
My raw logs simply show it as a successful GET of /cgi-bin/bbmat.cgi, as well as when I use /cgi-bin/bbmat.cgi?script=OZ
Shot in the dark #198
Is it ok to use caps for the directory name (OZ)
%Script = (
'OZ','/usr/home/user_name/filename/OZ',
);
Just guessing , but the path to OZ is likely to be something like
/usr/home/powdork/OZ
or
/usr/home/powdork/OZ.cgi
The above assuming 'powdork' is your actual user name with your host, and OZ or OZ.cgi is the filename
If it does not work or to test what the problem really is you could make the error message to specify what file it could not open by adding $! to the error message..
so changing
[perl]
open (CFG,"<$BBMCFG") ¦¦ &endIt ("Missing or Invalid Selection!");
[/perl]
to
[perl]
open (CFG,"<$BBMCFG") ¦¦ &endIt ("Missing or Invalid Selection! $!");
[/perl]
/usr/home/powdork/OZ.cgi- Nah, the directions say it is the path to the directory.
/usr/home/powdork/OZ- I have tried this, but only when I adjusted the other paths similarly. I'll try changing only that path.
("Missing or Invalid Selection! $!"); - Thanks, I'll do that too.
Shot in the dark #199- What's up with the capital 'C'?
open (CFG,"<$BBMCFG") ¦¦ &endIt ("Missing or Invalid Selection!");
@bbmCfg = <CFG>;