Re: DeletePage

[email protected] (Gunnar Hjalmarsson)
Newsgroups perl.beginners.cgi
Message-ID <[email protected]>
Deepan - M.Sc(SE) - 03MW06 wrote:
>               I am having a submit button and upon clicking it i am
> asking the user for confimation [for this i have used javascript].
> When the user selects yes i should be able to call another subroutine.
> But i am going wrong somewhere.

<snip>

>     print <<HTML;
>     <form action=files.cgi method="POST">
>     <input type=hidden name=cmd value=delete>

Maybe you meant that to be

     <input type=hidden name=cmd value=true>

> sub deletePage {
> 

You need a content-type header here.

     print CGI::header();

>     print "File was deleted successfully!<br>";
> 
> }

-- 
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.