1,633 Topics
| |
#!/opt/bin/perl $[ = 1; # set array base to 1 $, = ' '; # set output field separator $\ = "\n"; # set output record separator $FS = ';'; line: while (<>) { chomp; # strip record separator @Fld = split(/[;\n]/, $_, 9999); $id = $Fld[1]; if ($. == … | |
I'm showing a directory listing in one page now, but I want to show it in pages. Currently I'm working like this: [QUOTE]gtsee.com/cgi-bin/nph-dirsub.pl?invoice=invoices/merchant_invoice_999999 [/QUOTE] and the script for showing the listings are: my $sql=SELECT id, name, url FROM free_dirs; my ( $id, $name, $url) = @{$db_row}{qw/id name url}; print " … | |
Hi All, could you please help : i have a script to search the for PRIMARY INDEX and if found display the whole definition of create table: ISSUE NOW IS: we have to store the table name in a variable and search the file if any update,show table exists for … | |
Hello All, I am trying to figure out how to write user input into a text file. I created a text box that the user can type his/her name into. I am trying to get the information from that text box to be written to the text file using print … | |
Hi, How do I test Perl scripts in a web browser on a mac? Im using OSX 10.4.11. Ive got some documentation on how to edit the /etc/httpd/httpd.conf file, but its read only for some reason (even though Im on my own laptop). I also run MAMP and thought that … | |
Hello All, I am trying to use an image as a background. I am working with perl through putty .58 and am wondering how to get an image into a specific location in putty that can be used in a perl webpage? Thanks, | |
I have this script which uses the Net::FTP module to copy some files to some remote machine.It works fine with every file but a xml file.My application requires that the timestamp of the xml file doesn't change but the ftp script changes it.Is there any way around it? | |
Hi guys, I'm writing a simple script that uses snmpget statements to check the errors received by ports on a router and have the results going to a file. I've never worked with Perl before but one of my coworkers had a really basic script that I've been trying to … | |
I've recently been elevated in my team to a lead position, and one thing I have identified as a problem is that we don't have any existing curriculum or program for teaching programming to those members on our team without programming experience. There seems to be a barrier to people's … | |
hi, I was exercising package creation and its usage in Perl. I started with a simple program, 1. Created a package called A 2. Created a package called B 3. A program which includes those packages, and uses its services. [code=Perl] # A.pm package A; use warnings; my $l_var = … | |
I am trying to move files and rename them with a date-time stamp I generate. I have a survey and my perl script processes the POST query string. Once I have the query string, I am using XML::Simple to get the stored results, update them, then write them back out. … | |
Hello All, I am here with not really a problem but a bit of guidance in getting along in my path. Here I go with my task, I am trying to align a set of small sequences(may be around 5000 in number and less than 27 char in length) for … | |
I have been coding in c,c++ for many years, now I need to ramp up on perl within 3 weeks, can you please suggest what all books do I need to buy or I can learn advanced perl from some online website ? Thanks. | |
I am trying to process the results of a survey. I load the current results from an XML file, update them, then write them back to the file. I am get a 500 Internal Server Error when I run it from a browser, but it works fine in Windows and … | |
I have a need to pull the header informatilon form about a thousand email messages that have been saved in a file folder as text messages. I want to get this information into a database. I have no skills in coding or scripts. Example: The source IP, To: From: Date; … | |
I having troubles with the different seperators in this one and just picking out the lines I want keyed from the .dat filename. I basically have an autogenerated flat file that is an export of a directory structure. I want to parse through the flat file and pull values from … | |
This snippet while(<>) { for my $word ( split(/\s+/) ) { $idx{$word}{$page_number} = 1; } $page_number++ if ( /\014/ ); } is part of a perl script which indexes words by page (I'm trying to rewrite it in python). I do not understand it, or rather, I can guess a … | |
Hey guys wondering, if you are using Adobe CS3 and do you think, if there are other alternatives to CS3. Would you recommend CS3 or wait for something else. | |
Hello All, I used a for loop to create a set of radio buttons. For example: for($i = 1; $i < 4; $i++) { print '<INPUT TYPE="radio" NAME="first" VALUE=$i >', " $i|"; } My question is how do I display which radio button was chosen if all of them have … | |
I have tried debugging and optimizing this code, yet I cannot find the source of this error to save my life. I am getting a 'floating point exception' when I run the code pasted below. I am running with 'use strict' and 'use warnings'. My program takes a sequence and … | |
I have to write a programme. Whic is like this: You are write a program whcih uses the quadratic equation to solve second-order polynominal. wchich is a x**2 + b x + c =0 and use the quadratic equation, when given value for the coefficient a, b and c, to … | |
Dying here people! I am have basically confirmed that I my script is getting a POST and that it has some length to it, etc.: $ENV{REQUEST_METHOD} $ENV{'CONTENT_LENGTH'} But this line here: [code]read (STDIN, $query, $ENV{'CONTENT_LENGTH'});[/code] Comes back with $query being blank. Surely I am missing something? Wish I knew Perl … | |
1) is it possible that i could create GUI application under Perl (*.pl) files? 2) what are the things that i need to consider and do? 3) i tried copying a perl program from a certain website and when i tried running it on command prompt for Windows, it says … | |
I want to call a perl script from inside another perl script, but everytime I run it, a cmd window pops up, even if I close all the I/O handles. Is there any way to avoid the cmd window to popup in perl? I want to avoid annoying windows to … | |
Can anyone help me resolving below mentioned problem #!/usr/bin/perl @data=N; $sum=0; print"enter the required No. of numbers to be inputed : f"; $N=<STDIN>; print"enter the number"; for($i=0;$i<$N;$i+=1) {$data[$i]=<STDIN>; # chomp $data[$i]; $sum=$sum + $data[$i];} # for($j=0;$j=$data[$i];$j+=1) print"the entered numbers are",@data,"\n"; print"sum of the number:",$sum,"\n"; print"Average value the numbers:",$sum/$N,"\n"; @sorting=sort(@data); $lengt=@data; … | |
How can i write a engineering code using Perl? Foe example, Connecting computer RS-232 PORT to collect data purpose Please advice | |
Hello there! I wrote this code that performs removal of certain sequences, but its execution time exceeds one hour on a supercomputer. Could you help me to simplify it, so it will consume less time? Big thanks! /Robert #!/usr/local/bin/perl -w open (INPUT, "phastCons_200_chr6.txt") and print "phastCons is open\n"; open (OUT, … | |
I contacted customer support and they directed me to: [url]http://support.ehostpros.com/hd/index.php?_m=knowledgebase&_a=viewarticle&kbarticleid=137[/url] Part of what it says to do is set the permissions to 755. How do I do this? | |
Hello, I would first like to thank everyone for their help so far, i really appreciate it. Well, i have been learning perl for my job now for about three weeks. Things have gone pretty well so far. I have written a few scripts here and there. However, i have … | |
Helo everybody..im new to the forum n these days iv been streesed uip with my project. wanted to know if perl would be a good choice to implement an automatic program to extract text from online biomedical jounals(can b pdf or html format),categorise and summarise the text and keep it … |
The End.