RE: Uploading file
Use this as an example, it converts the file to binary mode just in case its not. It also strips out the path of the file coming from the user's local machine. #!/usr/bin/perl use CGI; use strict; my $cgi = new CGI; print $cgi->header; my $query = CGI::new(); use CGI qw(param); my ($bytesread,
RE: Uploading file
Camilo, You are getting the uploaded filename/object, which you should treat as read-only, confused with the final destination on your server that you want to write to. What you want to do is to copy the file, not manipulate it. Ordinarily, the file is saved by the CGI object in the tmp directo
Uploading file
Okay, I'm totally stumped. I'm trying to upload a file using a browser and a file upload field and saving the file to my server. The code is as follows: my $filename = $cgiobj->param('uploaded_file'); my $fh = $cgiobj->upload('uploaded_file'); open (OUTFILE, ">../featImages/$filename
FW: next if statement....
Oops, sorry for the empty reply. Greg, It is a common misconception that regular expressions act like text. If you are looking for this string: NAS-IP-Address = "192.168.0.1" you must escape all the special characters like this: NAS\-IP\-Address = \"192\.168\.0\.1\" Quotes do not work with
RE: next if statement....
-Original Message- From: Greg Schiedler [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 2:16 PM To: [EMAIL PROTECTED] Subject: next if statement OK I'm trying to modify the code below to recognize an additional next if statement. I have included a snip of the file that th
RE: next if statement....
Paul Archer wrote: > 12:15pm, Greg Schiedler wrote: > >> OK I'm trying to modify the code below to recognize an additional >> next if statement. I have included a snip of the file that the code >> uses an input. >> >> Greg >> >> next if /Acct-Session-Id = ""/;This statment works! >
Re: next if statement....
12:15pm, Greg Schiedler wrote: > OK I'm trying to modify the code below to recognize an additional next if statement. > I have > included a snip of the file that the code uses an input. > > Greg > > next if /Acct-Session-Id = ""/;This statment works! > A 'next if /./' is a short
Re: next if statement....
The slashes are similar to a reg-ex expression on $_ in your example. So basically it checks the line to see if that exists and does something. In your case, for the ip to work, all you would have to do is remove your quotes so the line matches, since the file doesnt have quotes around the ip
next if statement....
OK I'm trying to modify the code below to recognize an additional next if statement. I have included a snip of the file that the code uses an input. Greg next if /Acct-Session-Id = ""/;This statment works! # I added this statement. I don't understand the /'s in the statement. And
Re: Submit button to print form and then submit
Ash Singh wrote: Thanks, unfortunately its going to be javascript (yak):
/* This script is written by Eric ([EMAIL PROTECTED]) For full source code, installation instructions, 100's more DHTML scripts, and Terms Of Use, visit dynamicdrive.com */
<
RE: Submit button to print form and then submit
Thanks, unfortunately its going to be javascript (yak): /* This script is written by Eric ([EMAIL PROTECTED]) For full source code, installation instructions, 100's more DHTML scripts, and Terms Of Use, visit dynamicdrive.com */ function printit(){ if (window.print) { window.print() ; }
Re: Submit button to print form and then submit
> > Hi, > > I am designing a form using cgi and when the user clicks the submit button, > the form must print to the users local printer and then submit. > > Thanking you in advance > > You are talking client side, and most likely are going to need something like Java, Flash, ActiveX, etc.
Submit button to print form and then submit
Hi, I am designing a form using cgi and when the user clicks the submit button, the form must print to the users local printer and then submit. Thanking you in advance Ash Singh Programmer email: [EMAIL PROTECTED]