2,452 Topics

Member Avatar for
Member Avatar for winbatch

I'm new to perl (and actually not even really trying to develop this skill - I inherited some code and am trying to enhance it). Basically, I want to get the text between parts of a text string. How do I get the parsed variable to contain "WHATEVER IT IS"? …

Member Avatar for winbatch
0
143
Member Avatar for gmunky

I'm working on a program that opens an html text file using a JEditorPane. I can read in the html file but i can't get the hyperlinks to work. I want it so that when the user clicks on a hyperlink word, it will open a different html file in …

Member Avatar for Phaelax
0
144
Member Avatar for Little E

Is Perl/CGI the best language to use for sending a customer to a thank you page after they click the submit button? If they're not, then what is?

Member Avatar for Comatose
0
85
Member Avatar for mforeman

I am trying to remove entries if they contain the word "connected" in Perl. My file looks something like below. So In this example, I would like to search for "connected" and if found remove all 6 lines associated with it. If not found, then move on to the next …

Member Avatar for winelover
0
226
Member Avatar for EnderX

I have been requested to recycle an older program, written before I arrived, which is used to send information to a business client's ftp setup. As far as I can tell, the actual transaction is in a segment of code which calls and uses the LWP::UserAgent class. I do not …

0
47
Member Avatar for EnderX

I've been given a piece of buggy code to attempt reviving. At the moment, every time I run it, I'm getting this error:[CODE]Database handle destroyed without explicit disconnect.[/CODE] A quick google search reveals that this indicates I'm not closing a connection. I had trouble figuring out why I was getting …

0
38
Member Avatar for mandible

Hello I've been trying a bunch of things to try and get this to work. What I"m trying to do is take a sring like this: select * from "sch "."test" and change it to something like this select * from "hello"."test" I've tried a few things like [code] $LINE=~/["].+["]/\"hello\"; …

Member Avatar for mandible
0
96
Member Avatar for Mushy-pea

Hello everyone. Does anyone know if there is a way to start a child process from within a script, then capture the child's standard output and exit code? From looking at the docs it seems that [code=perl] $status = system("command"); [/code] lets you capture the exit code but not STDOUT. …

Member Avatar for Mushy-pea
0
122
Member Avatar for katharnakh

hi, I am having problem in updating tables in MS Access. The field which I want to update is of DATE type. here is the code.. #! C:\Perl\bin\perl.exe [code] use Win32::ODBC; my $db = new Win32::ODBC('ServerStatistics'); $q="select distinct(build_date) from wdf_history"; $db->Sql($q); while($db->FetchRow) { $s = $db->Data(); print $s; } $q …

0
51
Member Avatar for MojoS

Hi :-| I am workning on a projekt based on DNA sequences in Perl. I wanna make a program that reverse complements the DNA sequence and writes it into a file [I]fx. revdna.fsa (Which I have done )[/I] but the problem is that I want to keep the first unaltered …

Member Avatar for KevinADC
0
265
Member Avatar for nanodano

I am working with form processing and text manipulation, and I found two useful functions; tr/// and s/// They do pretty much the same thing, but I was wondering if anyone could explain to me what the difference is and if one would ever be more useful than the other …

Member Avatar for KevinADC
0
122
Member Avatar for avik1983

i have a simple text file as input.i have to print that file in paragraph format.whenevr it finds "\n" in the input text it should start printing in next paragraph in output file.also a fixed amount of space should be given before start writing in every paragraph. the input and …

Member Avatar for avik1983
0
215
Member Avatar for avik1983

i have a HTML report file..its in attachment(a part of the whole report is attached..name "input html.doc").also its source is attached in "report source code.txt" i just want to seperate the datas like in first line it should be.. NHTEST-3848498958-NHTEST-10.2-no-baloo a and so on for whole report i have done …

0
48
Member Avatar for katharnakh

Hello, I have a script to read remote file. The script goes as follows, [code=Perl] #!C:\Perl\bin\perl.exe $remote= '\\\remotehost\remotedir\remotefile.jml'; open(fp, $remote) or die ("could not open the file"); print while(<fp>); close(fp);[/code] This script runs fine on my windows machine. But the same script when I run in UNIX, after changing the …

Member Avatar for masijade
0
110
Member Avatar for MojoS

;) Hi guys.... I am a beginner at Perl, and i have some problemes I wanna solve!! I hope u can help me. the exercise is: Make a program that counts the number of positive and negative numbers in a column. Also count the zeroes in the column, if there …

Member Avatar for MojoS
0
103
Member Avatar for nathanpacker

Hey everyone, I'm using the php function [URL="http://us2.php.net/nl2br"][COLOR="Blue"]nl2br[/COLOR][COLOR="SeaGreen"]()[/COLOR][/URL] to display some characters on a page from a textarea. I'm storing the text into the database exactly as it is entered, and then only using the [URL="http://us2.php.net/nl2br"][COLOR="blue"]nl2br[/COLOR][COLOR="seagreen"]()[/COLOR][/URL] when displaying it on a page. Should I do it the other way around? …

Member Avatar for nathanpacker
0
84
Member Avatar for WolfPack

Does any of you know how to get the pathname of the perl script that is being executed? Say it is located in [inlinecode]/home/wolfpack/perl/[/inlinecode] I run it from [inlinecode]/home/wolfpack[/inlinecode] by giving the absolute path name like, [inlinecode]/home/wolfpack/perl/scriptname [arguments][/inlinecode] I want to get the path [inlinecode]/home/wolfpack/perl[/inlinecode] so that I can use …

Member Avatar for WolfPack
0
170
Member Avatar for qualtran

When someone logs out of our site, I want the previous page to not be accessible (or any of the other pages.) So far, when a user clicks the logout button on our site, I do the following: 1) I write to a file 2) erase the session cookie 3) …

Member Avatar for Mushy-pea
0
179
Member Avatar for jeffry

hi, Could any one please tell me How to disable a hyperlink or a textbox or a command button which is in page 2 from page 1? Suppose i have an admin page and a userpage.I have a details page which holds add,delete,view and search links or buttons or textboxes. …

Member Avatar for Dani
0
68
Member Avatar for annatalierry

Hello. Random hyperlinks have been appearing in some of my Excel spreadsheets. I've run virus scans, spyware scans (including AVG AntiSpyware) and they've come out clean. I've also cleaned my registry with Eusing Free Registry Cleaner. Here is my Hijack this log. Please let me know if you see any …

Member Avatar for gerbil
0
340
Member Avatar for MattEvans

Is there a standard way to make constants defined using the [inlinecode]use constant[/inlinecode] pragma available to all of the packages that are use'd from an executed file? Or even better, to make the constants defined in a package available to other packages that use that package? It seems like anything …

Member Avatar for lordspace
0
130
Member Avatar for iubike

I just don't know what to do to end the damn loops!?! [code] #!/usr/bin/perl -w use strict; print "Welcome to Techno-Bank 3000.\n"; print "Enter command => "; my $input = <STDIN>; chomp $input; my ($command, $user, $amount) = split / /, $input; my %accounts = ( $user => $amount ); …

Member Avatar for masijade
0
99
Member Avatar for laddu

I have executed a unix command whose output has a number of columns separated by whitespaces.How to extract a column from it and put it into an array using Perl.

Member Avatar for kuom
0
147
Member Avatar for Mushy-pea

Hello everyone. I'm still working on that forum system I mentioned a bit ago (perlBB). Hopefully it'll be ready for Christmas :p . However, I ran into a strange problem while I was re-writing parts the two functions below. [code=perl]sub enter_post { my(@field, $input, $offset1, $offset2, $n, $name, $field_length, $flag_guest, …

Member Avatar for swampyankee
0
81
Member Avatar for jovimarko

[COLOR=black]I am total novice, but I must solve this problem very quick and need help. Problem:I’ve been given a file 1 2 15 1 3 16 2 3 20 and so on…First two values of the input file represents graph nodes and the third one is distance between them. I …

Member Avatar for Puckdropper
0
81
Member Avatar for alex_wil

Hi friends, I am using Perl Tk for a GUI application. It uses a telnet part wherin I need to login to a unix machine, execute a command and process the result. The code is as follows : my $result = $t->cmd(("grep - $filename.txt~ | wc -l | awk '{print …

Member Avatar for mandible
0
190
Member Avatar for shinobiCracker

Hi Guys! I've attached here the screenshot i've made for my friends program. I need to properly understand these offsets so i could know the right unlock code from the combination of the username and challenge string produced by typing the username. Thanks! Need to know how! please help me! …

0
65
Member Avatar for Abhilashsr001

Hi all, I need to set some values on web page using perl. but the web page is created in jsp. for setting the values i need to click on a gif image which has got HREF to one javascript api. i need to invoke this from perl for setting …

Member Avatar for masijade
0
99
Member Avatar for Mushy-pea

Hello everyone. Is it allowed to have a "use" statement inside an eval that is compiled separately to the enclosing program (i.e. eval EXPR, not eval BLOCK). The reason I want to do this is, I have modules of code that I don't want to be compiled every time my …

Member Avatar for MattEvans
0
136
Member Avatar for Mushy-pea

I was wondering whether anyone else has experienced this. When a script I am working on got above a certain size, the line numbers quoted in the compile and run time error messages started to be inaccurate. The line numbers now seem to always be before where the error actually …

Member Avatar for Dukane
0
67

The End.