RE: cgi script that takes in data then runs script on different host

2002-05-28 Thread David Gray
First of all, don't cross-post please. One list is quite sufficient, and many people are subscribed to more than one list, so duplicate messages are quite often completely ignored. > I've got a cgi form that takes in data. Then, I want the > data to be passed to a script that's waiting on a DIF

Can someone Help me out with this

2002-05-24 Thread David Gray
you should try this. $old="abcdef"; $new="lmnop"; $ci_cmd1 = s/$old/$new/;#this substitutes the old value with the new one. regards, Ian David Gray wrote: > > Problem: > > ci_cmd1="abcdef", // line1 > > ci_cmd2=

RE: Can someone Help me out with this

2002-05-24 Thread David Gray
> Problem: > ci_cmd1="abcdef", // line1 > ci_cmd2="ghijk", // line2 > ci_cmd3="lmnop", // line3 > ci_cmd4="pqrst", // line4 > > I want to delete line 1 and 2 and the above should look like > as shown below: > > ci_cmd1="lmnop", > ci_cmd2="pqrst", Wher

RE: Mail script not working for Netscape (was" real beginner help needed")

2002-05-23 Thread David Gray
> This is the piece of code that is giving me the problem I > believe. It is the one that is supposed to check to make > sure that a user enters a valid email address. When I > comment it out, it works in both IE and NN. > > if ($FORM{'email'} !~ /[\w\-]+\@[\w\-]+\.[\w\-]+/) { > dienice("P

RE: which character did not meet the requirements of the regex

2002-05-21 Thread David Gray
> if (!($icname =~ /^[$allow]+$/)) { > print "your IP-Block name cannot contain special characters\n"; > print "we do not like <$1> \n" while ( $icname > =~ m/([^$allow])/g); > } You could use the !~ operator to negate this automatically and print it in a one-shot

RE: regular expression

2002-05-17 Thread David Gray
> > for(@text) { > /(d+)$/; # Match only the numbers at the end of the string ^^ this should actually be (\d+) I would actually conditionally print also, like so: print $1 if /(\d+)$/; And depending on the size of the file, instead of reading the whole thing into memory wi

RE: CGI and frames

2002-05-14 Thread David Gray
> I would like to create a html frameset plus the pages for the > frameset. You can't do that in one cgi script unless you call it multiple times like I showed you. > Normally a frameset looks (as you all know) somewhat like that: > >framespacing="0"> > scrolling="NO" noresize

RE: CGI and frames

2002-05-14 Thread David Gray
> Sorry, I chose the wrong words.. > my script works similar to the way you described below. Depending on > which fields are filled out and which button is pressed, a different > subroutine is called, creating the page. Ok... Could you post some code or pseudocode that describes the problem you

RE: CGI and frames

2002-05-14 Thread David Gray
> I'm using one CGI script to generate several search pages That's impossible. One call to a cgi script can generate only one page. Consider the following untested ;) (but simple enough that I probably didn't screw it up) code: --code-- #!/usr/bin/perl -w use strict; use CGI; my $cgi = new

RE: pass values to another scipt

2002-05-14 Thread David Gray
> Hi Sven, > > Sorry, I thought you knew that one. > > But how to proceed if you don't want those ugly/insecure > params in your location bar ? Use a form and an input type="image" HTH, -dave -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

RE: Vs Form post

2002-05-06 Thread David Gray
> I am strugling with my program that list the contents of a > directory. Ones the directory contains files and you have > permission it shows you a doc icon else it will show a > directory-map followed by it's name as an "" > > The problem I have now is that using the command > will have to

RE: Question Using for loops in incrementations

2002-05-06 Thread David Gray
> First Problem. > > The two tables are not the same length however my first if statements > will end the process after it reaches the end of the table. My second > and third if's will find the output of the first difference and then > stop. What I need to know is what type of for loop do I need

RE: exiting correctly

2002-04-24 Thread David Gray
> below is a snipet of the code. the most relavant part. when > i enter some bad data in or mysql has problems, it should go > to error_handler() at the bottom of my script. well it > does, then it returns unless i put an exit at the end of > error_handler. How about: mysub('param1','par

RE: exiting correctly

2002-04-23 Thread David Gray
> i have a regex that checks for a string in a param, if not > found, it should jump to an error subroutine. from there, i > print out "this is an error", etc. after that prints, unless > i have an "exit" to stop the processing, the sub jumps back > and prints out what i don't want it to. h

RE: conecting cgi and mdb? help please:)

2002-04-19 Thread David Gray
> Hi : > Thanks a bunch. For the first module, I would do - >install dbi > For the second module for the Open DB Connectivity , will I > do something similar like this ? - > install dbd::odbc > "need to create an ODBC data source referring to the > database file" - could you

RE: conecting cgi and mdb? help please:)

2002-04-19 Thread David Gray
> I would like to know what all needs to be done to connect to > a Microsoft Access database using perl script. 1) You need two modules: DBI and DBD::ODBC 2) You need to create an ODBC data source referring to the database file. 3) Connect to the database like this: $dbh = DBI->connect("DBI:O

RE: Source for comparative analysis

2002-04-12 Thread David Gray
> a) php AFAIK, overly simplified, PHP is non-M$ ASP. > b) java servlets - with say tomcat My only experience with servlets and JSP is that they are extremely annoying to use in production because any changes made to content require the entire server to be restarted... On the other

RE: asp from perl

2002-04-08 Thread David Gray
> hello everyone,i am trying to execute an asp script from a > perl cgi and i have the following problem > > I am using something like this to get user's input and the > pass it to the asp > > &ReadParse (*input); > > my $pin; > my $passwd; > > my @input; > > $pin = $input {'pin'}; > > $p

RE: Internal server error

2002-04-04 Thread David Gray
> I'm having problems with the old "Internal Server Error" > issue. I know that this is generally due to permissions. I > have used chmod go+rx -R *, but no joy. The html now works > but not the cgi. Thoughts? Try inserting the line use CGI::Carp (fatalsToBrowser); At the beginning of your s

RE: Read in from STDIN

2002-04-04 Thread David Gray
> Could anyone help I am having trouble reading in information > from STDIN > > For coding see attached file > > Using a while loop I want to do the following: > Read info in from STDIN > Read in any number of name/value pairs, > Read in names in pairs of two, and compute their sum. > Choose th

RE: IP Address

2002-04-04 Thread David Gray
> >>>>> "David" == David Gray <[EMAIL PROTECTED]> writes: > > >> How do I get the IP address from a POST form. > >> > >> Let me make myself more clear: I have a form that uses POST, > >> and I would like to get us

RE: IP Address

2002-04-03 Thread David Gray
> How do I get the IP address from a POST form. > > Let me make myself more clear: I have a form that uses POST, > and I would like to get users' IP address for avoiding the > same user to fake my pool's result. You can check $ENV{REMOTE_ADDR}, which will contain the remote IP of the user hitt

RE: Limit floating point numbers?

2002-04-01 Thread David Gray
> I have got most everything working ok. Now I need to go back > over almost 2500 lines of code and fix my floating point > number so they read 1.25 instead of 1.2556. Which should > round out to 1.26 What text editor are you using? Can you just do a search and replace? If that's not what you

RE: Resubmit?

2002-03-28 Thread David Gray
> Is it possible to have a form submit without waiting for a > user to click submit? All my parameters are hidden, that's why I ask. You could meta-refresh with all the form parameters in the query string, or maybe javascript.submit() the form, or use a lonely continue button :) -dave -- T