CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
string problem

 



simon171078
Novice

Jan 24, 2010, 12:33 PM

Post #1 of 3 (443 views)
string problem Can't Post

i write this code ,problem is in string $link in line:
$exitval=$win->ShellExecute('open','$link','','',1);
when url that $link save not load and if i write:
$exitval=$win->ShellExecute('open','www.yahoo.com','','',1);
url loaded
my code :


Code
 #!/usr/bin/perl -w 
use Net::POP3;
use Win32::GUI();
$win = Win32::GUI::Window->new;


$link=0;
$i=0;$j=0;
@masive=();
open (SALES ,">> email.txt");
$pop = Net::POP3->new('pop.mail.ru');

if ($pop->login('user', 'pass') > 0) {
my $msgnums = $pop->list; # hashref of msgnum => size
foreach my $msgnum (keys %$msgnums) {
$msg = $pop->get($msgnum);
print SALES @$msg ;
$pop->delete($msgnum);

}
}

$pop->quit;
close SALES;

open(SALES2,">>links2.txt");
open(SALES,"email.txt");
while ($line= <SALES>)
{

$massive[$i]=$line;
$i++;
}
close SALES;



for($counter2=0;$counter2<=$i;$counter2++)

{
if ($massive[$counter2] =~m/> http*/)
{$link=" $massive[$counter2] ";
$link= substr($link,2);

$exitval = $win->ShellExecute('open','$link','','',1);
print SALES2 "$link"."\n";
print SALES2 "\n";}

}

close SALES2;


file that $link receive data (how to execute these links with my code)
http://www.inetgiant.com/Relist.aspx?adId=2794876&email=admin171078@gmail.com


http://www.inetgiant.com/Relist.aspx?adId=2794890&email=admin171078@gmail.com


http://www.inetgiant.com/Relist.aspx?adId=2794882&email=admin171078@gmail.com


7stud
Enthusiast

Jan 24, 2010, 2:03 PM

Post #2 of 3 (439 views)
Re: [simon171078] string problem [In reply to] Can't Post

What about the other 6 threads you've abandoned? Look up the difference between single quotes and double quotes in perl.


(This post was edited by 7stud on Jan 24, 2010, 2:08 PM)


FishMonger
Veteran / Moderator

Jan 24, 2010, 7:35 PM

Post #3 of 3 (430 views)
Re: [7stud] string problem [In reply to] Can't Post


In Reply To
What about the other 6 threads you've abandoned? Look up the difference between single quotes and double quotes in perl.


Due to the lack of responses from simon171078, I don't see any reason to answer any more of his questions.

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives