Re: Simple CGI question

2003-11-07 Thread R. Joseph Newton
Eric Walker wrote:

> Newbie here but hope this helps.
>
> You have a page linked to the frame on the left right?  All you need to
> do is have your CGI script write the new page.  You use the info from
> the frame on the right and pass the values to your cgi script. Then let
> your CGI script write out a new html page using the values you sent it.
> Ok heres is the hard part.. All of you pros correct me if I am wrong.
>
> In the past I have use the "use CGI" module.  When you click submit you
> need to call
> your cgi a certain way to pass the values from the form to it.
>
> http://myfile.cgi?=&=&=&

DON'T do this!  CGI was meant for passing form data.  If you are learning CGI, do it 
in a
straightforward manner, by putting a form in your web page.  [Note you don't have to 
ever
have the user interact with the form or its data, though, but that's a separate topic.]
Just:






Then grab the values sent with your CGI script, using maybe that Vars method.

Don't meddle with the browser's business, unless you are ready to take on the business 
of
creating a User Agent froms cratch.

Joseph


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Simple CGI question

2003-11-06 Thread Eric Walker
Newbie here but hope this helps.

You have a page linked to the frame on the left right?  All you need to
do is have your CGI script write the new page.  You use the info from
the frame on the right and pass the values to your cgi script. Then let
your CGI script write out a new html page using the values you sent it. 
Ok heres is the hard part.. All of you pros correct me if I am wrong.

In the past I have use the "use CGI" module.  When you click submit you
need to call
your cgi a certain way to pass the values from the form to it.

http://myfile.cgi?=&=&=&

you need a variablename and value for every variable value pair you need
to send to the CGI.

Once you get to doing the CGI this is your next step.  Make sure you
have
use CGI; and my $q = new CGI; toward the top of the file.

$myvariable = $q->param("");
This will take the value sent to the CGI and put it into $myvariable. 
After that you just print the value the the html page linked in your
left frame.  I think you will have to do a refresh to get the new
content to show. Hope this helps and hope I am not too terribly off.

PEACE
Beginner










On Thu, 2003-11-06 at 17:11, Jack wrote:

Hello,

I'm trying to redirect the output of my CGI (written
in Perl) to another frame,
but I'm not exactly sure how to do this.  i.e. I have
two frames on my page
one on the right and one on the left.  There is a form
on the right frame.  When
the user clicks on the Submit button on my form, I'd
like to call a CGI script and
redirect its output to the left frame.  Could anyone
please tell me how I can do this?

Any help would be greatly appreciated.

Thanks,

 Jack

__ 
Post your free ad now! http://personals.yahoo.ca

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Simple CGI question

2003-11-06 Thread Bee
You would like to use this :


in your html page of your right frame.

Hope this help

- Original Message - 
From: "Jack" <[EMAIL PROTECTED]>
To: "CGI1" <[EMAIL PROTECTED]>
Sent: Friday, November 07, 2003 8:11 AM
Subject: Simple CGI question


> Hello,
> 
> I'm trying to redirect the output of my CGI (written
> in Perl) to another frame,
> but I'm not exactly sure how to do this.  i.e. I have
> two frames on my page
> one on the right and one on the left.  There is a form
> on the right frame.  When
> the user clicks on the Submit button on my form, I'd
> like to call a CGI script and
> redirect its output to the left frame.  Could anyone
> please tell me how I can do this?
> 
> Any help would be greatly appreciated.
> 
> Thanks,
> 
>  Jack
> 
> __ 
> Post your free ad now! http://personals.yahoo.ca
> 
> -- 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Simple CGI question

2003-11-06 Thread Jack
Hello,

I'm trying to redirect the output of my CGI (written
in Perl) to another frame,
but I'm not exactly sure how to do this.  i.e. I have
two frames on my page
one on the right and one on the left.  There is a form
on the right frame.  When
the user clicks on the Submit button on my form, I'd
like to call a CGI script and
redirect its output to the left frame.  Could anyone
please tell me how I can do this?

Any help would be greatly appreciated.

Thanks,

 Jack

__ 
Post your free ad now! http://personals.yahoo.ca

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Simple CGI Question

2003-11-05 Thread Tore Aursand
On Wed, 05 Nov 2003 01:26:20 -0500, Jack wrote:
> In my perl CGI script, I'm trying to extract the PID
> that corresponds to it.

The '$$' variable holds the pid;

  perldoc perlvar

> How come it's not possible to do something like:
> 
> print "";
> print `time`;
> print "";

No need to do a system call for 'time' here, when you got all you need
built-in in Perl;

  perldoc -f localtime


-- 
Tore Aursand <[EMAIL PROTECTED]>


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Simple CGI Question

2003-11-04 Thread Sudarshan Raghavan
Jack wrote:

Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
$$ contains the PID that corresponds to your script (perldoc perlvar)

How do I do this?  I'm also trying to extract the
timestamp.
The built-in perl function localtime will interest you
perldoc -f localtime
If you are looking to format your timestamp, strftime will interest you
perldoc POSIX
use POSIX qw(strftime);

How come it's not possible to do something like:

print "";
print `time`;
print "";
Don't know a lot about CGI, sorry :-)

Any help would be greatly appreciated,

Jack
 



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Simple CGI Question

2003-11-04 Thread Andrew Gaffney
Jack wrote:
Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
How do I do this?  I'm also trying to extract the
timestamp.
How come it's not possible to do something like:
print "";
print `time`;
print "";
Try this:

print "";
print scalar localtime;
print "";
--
Andrew Gaffney
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Simple CGI Question

2003-11-04 Thread Jack
Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
How do I do this?  I'm also trying to extract the
timestamp.
How come it's not possible to do something like:

print "";
print `time`;
print "";

Any help would be greatly appreciated,

 Jack

__ 
Post your free ad now! http://personals.yahoo.ca

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]