in reply to Re: Re: Re: Re: Re: Re: Re: Re: code problem
in thread code problem

Someplace between print start_html; ... print end_html;

Other than that, whereever you want it to appear in your finished HTML.


Peter L. BergholdBrewer of Belgian Ales
Peter@Berghold.Netwww.berghold.net
Unix Professional
  • Comment on Re: Re: Re: Re: Re: Re: Re: Re: Re: code problem

Replies are listed 'Best First'.
Re: Re: Re: Re: Re: Re: Re: Re: Re: Re: code problem
by sandal (Initiate) on Jul 23, 2003 at 14:02 UTC

    I try code on this host and get error: "The server encountered an internal error or misconfiguration and was unable to complete your request."
    I try code also on another similar host (they use Unix IBM AIX and IBM RS/6000) and get error:
    Software error: Execution of /host/h/e/l/p/o/r/subdomain.com/cgi-bin/testscript.cgi aborted due to compilation errors.

    sandal

      Sandal,

      Try downloading the tar/gz I have just created for you on my website here.

      Instructions: read and follow carefully

      1. Download the tar/gz above.
      2. Extract the Perl script that it contains.
      3. Upload it to your site
      4. chmod 755 the script
      5. Run it.

      If this script (which I just verified works) does not run on your site the following problems may exist:

      • The full path to the Perl interpreter may be wrong in the shebang line. Find out what the path really is (/usr/local/bin/perl? /usr/local/software/perl/bin?) and change the shebang line according and try again.
      • The CGI and/or CGI::Carp modules don't exist on your system. If that's the case try removing the CGI::Carp directive and try again. If that don't work then that's just bad Ju-Ju. See if the hosting site has a HOWTO on working CGI on their site or find a hosting site with a clue.
      • The version of Perl they are running on the hosting site is hopelessly antiquated. Find a new site.


      Peter L. BergholdBrewer of Belgian Ales
      Peter@Berghold.Netwww.berghold.net
      Unix Professional

      Code tags - dvergin 2003-07-23

        Try downloading the tar/gz I have just created for you on my website

        Your assistance is certainly generous and well-intentioned, but I think it would be best if we didn't encourage posting links to scripts on our personal sites. It would have been better to simply include the source of your script, all 184 lines of it, between a couple readmore tags.

        The simplest view is that, when avoidable, it is best not to make a node dependent on an external site for completeness. There are, however, far more compelling (security) reasons. Unfortunately, they are quite subtle and easily overlooked.

        It is very important that the code provided in our answers be readily available for peer review. You might say that it was; anyone could download the code and look at it. That's not necessarily true. You can't tell who might be checking up on the site from an internet cafe, mall kiosk, or school library. Some may even decline to download the package simply because they don't want to reveal their IP to you (which might expose their place of employment, for instance.)

        It is also important that, when we do review code, we can all be sure we are talking about the same thing. A link on an external site may easily be made to look like one thing to one person and another to someone else. Hence, in this case, all I can say is that the code that I downloaded from your site looked clean after a quick inspection. I have no idea about anything that anyone else downloaded.

        -sauoq
        "My two cents aren't worth a dime.";
        

        Peter,


        I run syscheck script successfully.

        I have mailed details on your email. What you can tell?

        Thanks,

        sandal