Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Re^10: json return value

by stenasc (Novice)
on Jul 16, 2013 at 12:40 UTC ( #1044581=note: print w/replies, xml ) Need Help??

in reply to Re^9: json return value
in thread json return value

Same thing when accessed through browser

Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Server log is...

16/Jul/2013:13:14:25 +0100 "GET /cgi-bin/test2.cgi HTTP/1.1" 404 - "-" "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)"

Replies are listed 'Best First'.
Re^11: json return value
by Anonymous Monk on Jul 16, 2013 at 14:13 UTC

      This novice is back again. My cgi works when the following line of code is used as it uses the parameters after the logical or operator...

      my $data = $q->param('POSTDATA') || '{"a":100,"b":300}';

      but it doesn't when the following line is used...

      my $data = $q->param('POSTDATA'};

      I'm posting up the following json statement which I checked on jsonlint and gave no errors.


      I get the following webserver error message

      File does not exist: /home/myurl/public_html/500.shtml

      It looks to as if the parameters are not parsed correctly or are not being received properly. Any help greatly appreciated

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1044581]
and the shadows deepen...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (5)
As of 2017-11-21 02:52 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (294 votes). Check out past polls.