[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdenonbeta/kopete/protocols/icq_new/icq_webhandler
From:       Jason Keirstead <jason () keirstead ! org>
Date:       2002-12-31 22:18:50
[Download RAW message or body]

CVS commit by brunes: 

I am an ididot. This is a local file, not a web URL!


  M +13 -12    icq_webhandler   1.3


--- kdenonbeta/kopete/protocols/icq_new/icq_webhandler/icq_webhandler  #1.2:1.3
@@ -18,22 +18,23 @@
 #######################################################################################
 
-use LWP::Simple;
+# Open the file
+my $file = shift;
 
-my $url = shift;
+open(INFILE,"$file");
 
-# Download the file
-$file = get ($url);
-
-# Get the action
-if($file =~ /\[(.*)\]/) {
+until( $actionLine =~ /\[.*\]/ ) {
+        $actionLine = <INFILE>;
+}
+if ( $actionLine =~ /\[(.*)\]/ ) {
         $action = $1;
 }
 
 # Get our variables
-if( $file =~ /UIN=(.*)\r?\n/ ) {
+while( <INFILE> ) {
+        if( /UIN=(.*)\r?\n/ ) {
         $uin = $1;
-}
-if ( $file =~ /NickName=(.*)\r?\n/ ) {
+        } elsif ( /NickName=(.*)\r?\n/ ) {
         $nickName = $1;
+        }
 }
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic