1,633 Topics

Member Avatar for
Member Avatar for ravikim

Hi , use Sort::External; $output = '1.txt'; open(FILE, $output); my $sortex = Sort::External->new( mem_threshold => 1024**2 * 1024 ); while (<FILE>) { $sortex->feed($_); # tried to change it to ~$_ but did not work !!!!! } use Fcntl; $sortex->finish( outfile => 'desc_1.txt', # comes in ascending order !! flags => …

Member Avatar for 7stud
0
371
Member Avatar for Tony Timms

Hi, I am new here and to Perl. I am currently being driven mad trying to install an event calendar script, I have created the database and successfully created the tables by running the dump.pl file but when trying to run the admin.pl [url]http://www.mysite.co.uk/cgi-bin/links/admin/admin.pl[/url] I get the following error - …

0
51
Member Avatar for suki_boy

[CODE]Hi All,Im a newbie in Perl Coding,and i just cant get this to work it says error compiling[/CODE] This is an Exploit for Hacking Joomla com_cinema Heres the Code [CODE]#!/usr/bin/perl -w #Joomla Component Cinema 1.0 Remote SQL Injection # ######################################## #[~] Author : **RoAd_KiLlEr** #[~] Greetz : Ton![W]indowS,KHG,ALBOZ-CREW,B3r0-G & All …

Member Avatar for ov3rcl0ck
0
187
Member Avatar for ajay_p5

Hi People I need to compare a particular line in a file with a particular string in the other file. I am attaching both the files for your reference. here is my code: [CODE] open (INFILE, "$input") or die "Couldn't open $input for reading: $!\n"; while(<INFILE>) { my $line= $_; …

Member Avatar for d5e5
-1
139
Member Avatar for muppetjones

I'm pretty new at this, and I'm trying to figure out how Perl's classes work with signals. Specifically, it doesn't seem that a class's DESTROY function is called when you Ctrl-C the program. I tried using [INLINECODE]use sigtrap qw(handler DESTROY INT QUIT);[/INLINECODE], but I'm not even sure this is the …

Member Avatar for Sanjeeb25
0
157
Member Avatar for msvinaykumar

Hi, I'm using following packages to read and write the excel, But the problem I'm not able to copy the formula from one sheet to other sheet packages are use Spreadsheet::ParseExcel; use Spreadsheet::WriteExcel; Is there any other packages so that I can copy excel fromula to another excel ( I …

Member Avatar for mitchems
0
138
Member Avatar for viktorijakup

Hi ! Sorry for my english ! My script must rename file name, but don't do it. What is wrong with this script: [CODE]@rem = '--*-Perl-*-- @echo off if "%OS%" == "Windows_NT" goto WinNT perl -x -S "%0" %1 %2 %3 %4 %5 %6 %7 %8 %9 goto endofperl :WinNT …

Member Avatar for k_manimuthu
0
217
Member Avatar for Vandithar

HI, I have a string like this. These are the set of phrases enclosed in double quotes: [code] $str="\"rna binding protein\" OR \"Transcription factor\" "; [/code] I want to replace the string like this: [code] $str="\"rna|(rna) binding protein\" OR \"Transcription|(Transcription) factor\" "; [/code] How can i replace the above string …

Member Avatar for 7stud
0
96
Member Avatar for wonderland

Hi, I wan't to add simple web form to my page. name, e-mail, comment, so I started poking around internet and found out about CGI. I put premade cgi.(pearl) script in cgi-bin folder on server and adjusted form for that script: When I tested out my form , i got …

Member Avatar for wonderland
0
164
Member Avatar for notuserfriendly

I need to read from a file and be able to split it into columns and ignore a line if it starts with ' . '. the text file is made of 3 columns but at some lines there are no words in the first column here is an example …

Member Avatar for 7stud
0
394
Member Avatar for john_prince

Hi, I am trying to match phone numbers, and want only having format xxx-xxxx. Here is what i have written so far : [CODE]sub OfficePhoneNumber { my @numbers = @_; my $number; my @results; foreach $number (@numbers) { if ($number =~ m/(^\d{3}-\d{4}$)/) { push @results, $number; } } return @results; …

Member Avatar for john_prince
0
85
Member Avatar for derekn

I want to search "The tree is in the yard" for the word "the", then replace the word "the" with "<font color=#FFFFFF>the</font>", which I currently do with "s/$searchstring/<font color=#FFFFFF>$searchstring</font>/gi;" BUT I want to preserve the case of the word, so that in this example the first word of the sentence …

Member Avatar for derekn
1
95
Member Avatar for klactose

Hello, I have created a simple webservice and I am now in the testing mode. I am trying to write a simple script that will use curl to create user accounts and another one to delete user accounts. I have tried to use system to send curl commands [CODE=perl] my …

Member Avatar for klactose
0
161
Member Avatar for k2k

basically i need to have 2 variables.. concat them and put them into use. here is what i have done so far: [code] #!/usr/bin/perl $stats = ':/var/tmp/RtcTestHarness/currentTransactionStats.txt'; $console = ':/var/tmp/RtcTestHarness/TestHarnessConsole.log'; $client_1 = '9.34.120.36'; #$com = $client_1.$stats; #print $com; the concat here looks fine... system ("scp $client_1.$currentTranStats ."); [/code] anything wrong? …

Member Avatar for d5e5
0
106
Member Avatar for sen1978

<?php session_start(); //Check User Session include ("includes/check_session.php"); include 'includes/config.php'; $current_module = 'MATERIALREQ'; //$related_modules = array('BIDDINGENTRY','PIRRAISING','POLIST','BIDDINGSELECTION','GRV'); include ('includes/check_acl.php'); //include 'includes/config.php'; include 'includes/sqlquery.php'; include 'includes/message.php'; $valid = ''; $current_user_id = $_SESSION['associate_id']; //if the session value is present, set whether the last transaction is stored or not if (isset($_SESSION['mrmsg']) && ($_SESSION['mrmsg']!='')) { $valid …

-1
73
Member Avatar for ajay_p5

Hi everyone, I am using this code to parse data from latex files : [CODE] #!/Applications/xampp/xamppfiles/bin/perl use strict; use File::Copy; use LaTex::Parser; use Text::CSV_XS; use utf8; use Unicode::String; Unicode::String->stringify_as( 'utf8' ); # utf8 already is the default #see Ch 7.1 of Data Munging with Perl my $output = "ID+add.txt"; open …

0
93
Member Avatar for shoola

I'm using mod_perl it seems I have to restart apache every time I modify one of my modules. is there a way around this so that the modified module will load without restarting apache?

0
87
Member Avatar for pbassett

I have a .cgi file that reads POSTed data from an HTML questionnaire Form and displays HTML that lists all the scholarships the person may qualify for. I want to Include a file with CSS and a Header image. Unfortunately none of this is taking effect, only the list of …

0
94
Member Avatar for oluscoa

Using Visual Basic .Net, explain what each variable type listed below holds, how big it is (i.e. the number of bytes it uses) and give an example of how it might be used. Data Type Explanation space occupied Example Text Integer Floating point Byte Date Boolean

0
53
Member Avatar for jacquelinek

I have a list like this: name1: group1 name2: group4 name3: group1 group2 name4: group4 .......... .......... I wish to invert this list, and make it look like: group1: name1 name3... group2: name3 group4: name2, name4 ........... ........... Can somebody offer at least a psuedo code? Thanks

Member Avatar for k_manimuthu
0
142
Member Avatar for riya0707

I am a perl beginner and need some help with regex Input for this code is : aatgatgataaggtaaggtatgatgatgatgatgatagtagannnnnnnnnatgcatga'/atgca.atgactagca/atgactagcaaggtaaggtaaggtaaggtaaggtatgatgatgannnn./atgatgactagactgacaaggtaaggtaaggtatgatgatgatcgatgacgat... and so on Here i am trying to assign input file as a scalar variable and trying to find a match of "aaggtaaggt" and then skip some 100 characters whether they are …

Member Avatar for thangdd
0
150
Member Avatar for skelly16

Hi All Im very new to perl scripting coming from a shell background, but im determine to stick to it and learn perl. I have env variables which i have defined in my perl script and work fine from command line as these env variables are in my profile. When …

Member Avatar for skelly16
0
221
Member Avatar for mitzoff

I'm new to perl and I'm writing a script to parse multiple Gaussian03 output files and extract certain pieces of data from them. Ideally the script needs to print out the name of each file, look for (the last) SCF Energy, the Zero-point Energy and check if the job has …

Member Avatar for mitzoff
0
204
Member Avatar for shoola

there are so many here: search.cpan.org/search?query=upload&mode=module which one do you use?

0
84
Member Avatar for johnyjj2

Hello :-)! I installed Ubuntu in order to install CMU Sphinx ([url]http://www.speech.cs.cmu.edu/sphinx/tutorial.html[/url]). There is one problem with executing perl script and I think it is good place to ask for help. Script make_feats.pl is here [url]http://www.linuxforums.org/forum/attachments/debian-linux-help/2267d1256986736-kde-startx-debian-make_feats.pl.txt[/url] . When I run "perl scripts_pl/make_feats.pl -ctl etc/an4_train.fileids" I see "Configuration (e.g. etc/sphinx_train.cfg) not …

0
88
Member Avatar for ajay_p5

Hi everyone Well I have been trying to install some modules like Bundle::DBI, DBD ::mysql and latex::Parser on my apple comp running mac OS X operating system. Every time I am trying to install a module I get an error like this : make had returned bad status, install seems …

Member Avatar for ajay_p5
0
154
Member Avatar for notuserfriendly

basically i am trying to search for similar strings in an array which is hardcoded into the script and compare them to and find the line they exist on the text file here is my code so far [CODE=perl] #!/usr/bin/perl %fruit=(banana=>1,apple=>2,orange=>5); $target = %fruit; open(INPUT, "<fruits.txt"); while (<INPUT>) { if …

Member Avatar for d5e5
0
242
Member Avatar for Vandithar

Hi, I have strings like this: [code] $string="OWN - NLM STAT- Publisher DA - 20091005 AU - Gannon AM AU - Turner EC AU - Reid HM AU - Kinsella BT AU- XYZ AD - UCD School of Biomolecular and Biomedical Sciences"; [/code] I want to parse these tags and …

Member Avatar for eggmatters
0
148
Member Avatar for wannagethelp

Hallo everyone im starting to learn perl and i have a problem , i have an exercise asking me to count all the letters each apart in a DNA string , for example my @DNA =( ctagctagcatgacgatacatgacagataggatacagatagacagatacagatacagatacagatagacccatgacagatac) so i have to make a perl script showing the user how many …

Member Avatar for wich
0
135
Member Avatar for arun10427

Hi all, I am a perl newbie. I am using a perl code to read a column full of data from 1 field into an array [CODE]for(my $i=2;$i<table->last_record;$i++) my @data = $table->get_record($i,"Date"); [/CODE] Now for example if my @data[1] consists of list of numbers, I need to find the diff …

Member Avatar for weer
0
154

The End.