Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I need to get MCookie, but I don't know which one

Status
Not open for further replies.

Nutthick

MIS
Jan 14, 2004
126
0
0
GB
I'm trying to get Mega Uploader to work, but I need MCookie installed. I've had a look on CPAN for modules called cookie, but there are loads of them. Does anyone know which one I should be using?

A link to the Mega Uploader site is below

with the list of modules here

Thanks for any help
 
If you want to see if you have a module installed and you cannt remember then you run
[red]perl -MModule_name[/red]
and if you dont get an error message then you do have the module. So the "M" before each module, means something like "use"
so the module you are after is not MCookie, but just Cookie.
Of course there is no Cookie module, But there is a CGI::Cookie which is what the page is asking you for.
so if you have the CGI installed then this
[red]perl -MCGI::Cookie -e 1[/red]
should give you no output and it would mean that you have the module installed.


``The wise man doesn't give the right answers,
he poses the right questions.''
TIMTOWTDI
 
Thanks for the replies. I can now add modules to perl alot easier than I could yesterday.

I'm still having problems though. I installed CGI::Cookies using the following command
Code:
perl -MCPAN -e 'install CGI::Cookie'
and everything installs OK. if I do
Code:
perl -MCGI::Cookie -e 1
then perl returns nothing, so installed perfectly. However, if I do
Code:
perl -MCookie -e 1
I get an error. Is MCookie just a typo on the MegaUploader website? I'm still getting errors when I try to run the scripts, with it giving the Internal Server Error as follows
Code:
Use of uninitialized value in -s at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 179, <fh00001Test.wav> line 184.
Use of uninitialized value in concatenation (.) or string at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 180, <fh00001Test.wav> line 184.
Use of uninitialized value in concatenation (.) or string at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 181, <fh00001Test.wav> line 184.
Use of uninitialized value in concatenation (.) or string at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 195, <fh00001Test.wav> line 184.
Use of uninitialized value in <HANDLE> at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 196.
readline() on unopened filehandle at /var/[URL unfurl="true"]www/cgi-bin/upload.cgi[/URL] line 196.
but I don't know if this is to do with missing modules or something else. The file is uploading, I just don't get the progressbar. Does this look like a module problem, or something in the code?

Thanks again

@mbrooks, Just checking out the progress bar for uploading ;)
 
Got it sorted. My modules were fine, a couple of the scripts were missing -w from the perl location and that was throwing the server.

Thanks for all the help
 
perl -MCookie -e 1" yes it is wrong. There is no such module.

The errors you are getting are not because of the -w switch, they are because in your script, there is a check on a variable that does not have a value.

So you can either initialize the value for that variable or check first if the variable is defined and then do whatever check you are doing.


``The wise man doesn't give the right answers,
he poses the right questions.''
TIMTOWTDI
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top