lightoverhead has asked for the wisdom of the Perl Monks concerning the following question:
Dear Monks
I am trying to apply it to my project. However I encountered some problems to get it going. I can run jQuery File Upload plugin with using its own php server-side script. it works fine. However, when I tried to write some code using your package, I have some problems. I am sorry if I am asking some naive questions as I may not fully understand how this works. My test script is as below (I just copied the one from cpan) "jq_ful.pl", in /usr/lib/cgi-bin/
#!/usr/bin/perl -w use strict; use jQuery::File::Upload; #simplest implementation my $j_fu = jQuery::File::Upload->new; $j_fu->upload_dir('/var/www/tempfiles'); $j_fu->handle_request; $j_fu->print_response;
I also changed jQuery File Upload plugin "main.js": from : url: 'server/php/' to url: 'http://localhost/cgi-bin/jq_ful.pl'
The error message from webpage is "SyntaxError: JSON.parse: unexpected end of data"
The error message from apache error log are:[Fri Apr 04 02:45:12 2014] [error] [client 127.0.0.1] Use of uninitial +ized value $url in substitution (s///) at /usr/local/share/perl/5.14. +2/jQuery/File/Upload.pm line 173., referer: http://localhost/jQuery-F +ile-Upload-9.5.7/index.html [Fri Apr 04 02:45:12 2014] [error] [client 127.0.0.1] Use of uninitial +ized value in concatenation (.) or string at /usr/local/share/perl/5. +14.2/jQuery/File/Upload.pm line 158., referer: http://localhost/jQuer +y-File-Upload-9.5.7/index.html [Fri Apr 04 02:45:12 2014] [error] [client 127.0.0.1] Use of uninitial +ized value in string ne at /usr/local/share/perl/5.14.2/jQuery/File/U +pload.pm line 921., referer: http://localhost/jQuery-File-Upload-9.5. +7/index.html [Fri Apr 04 02:45:12 2014] [error] [client 127.0.0.1] Use of uninitial +ized value in print at /usr/local/share/perl/5.14.2/jQuery/File/Uploa +d.pm line 673., referer: http://localhost/jQuery-File-Upload-9.5.7/in +dex.html
I am wondering if any of you have experience with this package and may let me know what errors I really have here.
I actually tried to use this plugin in my perl Dancer project and tried to integrate this package and jquery plugin into Dancer codes I wrote.
Thank you very much.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: questions regarding jQuery::File::Upload (REQUEST_URI)
by tye (Sage) on Apr 04, 2014 at 15:15 UTC | |
by lightoverhead (Pilgrim) on Apr 04, 2014 at 17:50 UTC | |
by tye (Sage) on Apr 04, 2014 at 17:57 UTC | |
by lightoverhead (Pilgrim) on Apr 04, 2014 at 18:24 UTC | |
by lightoverhead (Pilgrim) on Apr 04, 2014 at 20:50 UTC |