Did you follow my advice of making sure that there is a newline at the end of your file?
Your code works for me if it has a newline at the end, and it fails like you described if it does not have a newline at the end. One way to also make it work is to add a comment at the end of the file:
#!/usr/local/bin/perl print"Content-type:text/html\n\n"; print<<"ending_print_tag"; <html> <head> <title>My first CGI</title> <background="#oooooo" text='#FF0000"> </head> <body> <h1>My First CGI</h1> <em>HELLO, INTERNET!</em> <hr noshade> Watch our cyber space, another programmer is on the loose ;-) </body> </html> ending_print_tag # This is the end of the file and to make sure that we have a newline +after the end of the # here-doc marker.
In reply to Re^6: Testing scripts
by Corion
in thread Testing scripts
by zealf
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |