[PHP] Re: exec(echo ... issuse

2002-09-25 Thread Henry

use \ instead of  so that you don't actually end the string

Henry

Mario Ohnewald [EMAIL PROTECTED] wrote in message
001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
 Hello!
 I want to write a line into a file (called $script) wich goes like that:

  echo `date` 192.168.10.123 is down, lets call the admin. I was
 sleeping for 10 Minutes | smbclient -M Computer

 This is what i have tried:
 exec(echo echo `date` === $ip is down, lets call the admin. I
 was sleeping for $var_timer_rechner1 Minutes | smbclient -M $popup_1 
 $script);

 The problem is that after
 exec(echo 
 its command ends due to that .

 I tried \ to let php ignore this  but then it doesn´t write my 
anymore:
  exec(echo \echo \`date` === $ip is down, lets call the admin.
I
 was sleeping for $var_timer_rechner1\ | smbclient -M $popup_1\ 
 $script);

 this is the result:
 echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
the
 admin. I was sleeping for  | smbclient -M Server

 but i want:
 echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
the
 admin. I was sleeping for | smbclient -M Server

 ^^
 ^^
 missing
 missing


 Can anyone tell me where the my mistake is?


 Cheers, Mario




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Re: exec(echo ... issuse

2002-09-25 Thread Henry

Oops, I didn't read on Sorry

Henry

Henry [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 use \ instead of  so that you don't actually end the string

 Henry

 Mario Ohnewald [EMAIL PROTECTED] wrote in message
 001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
  Hello!
  I want to write a line into a file (called $script) wich goes like that:
 
   echo `date` 192.168.10.123 is down, lets call the admin. I was
  sleeping for 10 Minutes | smbclient -M Computer
 
  This is what i have tried:
  exec(echo echo `date` === $ip is down, lets call the admin.
I
  was sleeping for $var_timer_rechner1 Minutes | smbclient -M $popup_1

  $script);
 
  The problem is that after
  exec(echo 
  its command ends due to that .
 
  I tried \ to let php ignore this  but then it doesn´t write my 
 anymore:
   exec(echo \echo \`date` === $ip is down, lets call the
admin.
 I
  was sleeping for $var_timer_rechner1\ | smbclient -M $popup_1\ 
  $script);
 
  this is the result:
  echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
 the
  admin. I was sleeping for  | smbclient -M Server
 
  but i want:
  echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
 the
  admin. I was sleeping for | smbclient -M Server
 
  ^^
  ^^
  missing
  missing
 
 
  Can anyone tell me where the my mistake is?
 
 
  Cheers, Mario
 





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Re: exec(echo ... issuse

2002-09-25 Thread Henry

Have you tried using single quotes arround the main string?

i.e. 'echo echo blah blah'

Henry

Henry [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 use \ instead of  so that you don't actually end the string

 Henry

 Mario Ohnewald [EMAIL PROTECTED] wrote in message
 001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
  Hello!
  I want to write a line into a file (called $script) wich goes like that:
 
   echo `date` 192.168.10.123 is down, lets call the admin. I was
  sleeping for 10 Minutes | smbclient -M Computer
 
  This is what i have tried:
  exec(echo echo `date` === $ip is down, lets call the admin.
I
  was sleeping for $var_timer_rechner1 Minutes | smbclient -M $popup_1

  $script);
 
  The problem is that after
  exec(echo 
  its command ends due to that .
 
  I tried \ to let php ignore this  but then it doesn´t write my 
 anymore:
   exec(echo \echo \`date` === $ip is down, lets call the
admin.
 I
  was sleeping for $var_timer_rechner1\ | smbclient -M $popup_1\ 
  $script);
 
  this is the result:
  echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
 the
  admin. I was sleeping for  | smbclient -M Server
 
  but i want:
  echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is down, lets call
 the
  admin. I was sleeping for | smbclient -M Server
 
  ^^
  ^^
  missing
  missing
 
 
  Can anyone tell me where the my mistake is?
 
 
  Cheers, Mario
 





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Re: exec(echo ... issuse

2002-09-25 Thread Mario Ohnewald

Hi Henry,


  From: Henry [mailto:[EMAIL PROTECTED]]


 Have you tried using single quotes arround the main string?

 i.e. 'echo echo blah blah'

I have tried serveral of version, maybe you could give me your example from
the lines below.
I couldnt work it out ;(



 Henry

 Henry [EMAIL PROTECTED] wrote in message
 [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
  use \ instead of  so that you don't actually end the string
 
  Henry
 
  Mario Ohnewald [EMAIL PROTECTED] wrote in message
  001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
   Hello!
   I want to write a line into a file (called $script) wich
 goes like that:
  
echo `date` 192.168.10.123 is down, lets call
 the admin. I was
   sleeping for 10 Minutes | smbclient -M Computer
  
   This is what i have tried:
   exec(echo echo `date` === $ip is down, lets
 call the admin.
 I
   was sleeping for $var_timer_rechner1 Minutes | smbclient
 -M $popup_1
 
   $script);
  
   The problem is that after
   exec(echo 
   its command ends due to that .
  
   I tried \ to let php ignore this  but then it doesn´t write my 
  anymore:
exec(echo \echo \`date` === $ip is down,
 lets call the
 admin.
  I
   was sleeping for $var_timer_rechner1\ | smbclient -M
 $popup_1\ 
   $script);
  
   this is the result:
   echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
 down, lets call
  the
   admin. I was sleeping for  | smbclient -M Server
  
   but i want:
   echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
 down, lets call
  the
   admin. I was sleeping for | smbclient -M Server
  
   ^^
   ^^
   missing
   missing
  
  
   Can anyone tell me where the my mistake is?
  
  
   Cheers, Mario
  
 
 


mario


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re: exec(echo ... issuse

2002-09-25 Thread Henry

How about

?php
$command=\`date` === $ip is down, lets call the admin. I
was sleeping for $var_timer_rechner1 Minutes\ | smbclient -M $popup_1 
$script;
exec(echo \$command\);
?


Mario Ohnewald [EMAIL PROTECTED] wrote in message
001901c26480$5e280df0$350aa8c0@W2KDP">news:001901c26480$5e280df0$350aa8c0@W2KDP...
 Hi Henry,


   From: Henry [mailto:[EMAIL PROTECTED]]
 
 
  Have you tried using single quotes arround the main string?
 
  i.e. 'echo echo blah blah'

 I have tried serveral of version, maybe you could give me your example
from
 the lines below.
 I couldnt work it out ;(


 
  Henry
 
  Henry [EMAIL PROTECTED] wrote in message
  [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
   use \ instead of  so that you don't actually end the string
  
   Henry
  
   Mario Ohnewald [EMAIL PROTECTED] wrote in message
   001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
Hello!
I want to write a line into a file (called $script) wich
  goes like that:
   
 echo `date` 192.168.10.123 is down, lets call
  the admin. I was
sleeping for 10 Minutes | smbclient -M Computer
   
This is what i have tried:
exec(echo echo `date` === $ip is down, lets
  call the admin.
  I
was sleeping for $var_timer_rechner1 Minutes | smbclient
  -M $popup_1
  
$script);
   
The problem is that after
exec(echo 
its command ends due to that .
   
I tried \ to let php ignore this  but then it doesn´t write my 
   anymore:
 exec(echo \echo \`date` === $ip is down,
  lets call the
  admin.
   I
was sleeping for $var_timer_rechner1\ | smbclient -M
  $popup_1\ 
$script);
   
this is the result:
echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
  down, lets call
   the
admin. I was sleeping for  | smbclient -M Server
   
but i want:
echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
  down, lets call
   the
admin. I was sleeping for | smbclient -M Server
   
^^
^^
missing
missing
   
   
Can anyone tell me where the my mistake is?
   
   
Cheers, Mario
   
  
  
 

 mario




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Re: exec(echo ... issuse

2002-09-25 Thread Mario Ohnewald

Hi Henry!


 From: Henry [mailto:[EMAIL PROTECTED]]

 How about

 ?php
 $command=\`date` === $ip is down, lets call the admin. I
 was sleeping for $var_timer_rechner1 Minutes\ | smbclient -M
 $popup_1 
 $script;
 exec(echo \$command\);
 ?

Nope, hasnt worked either ;(

any other idea?
this is quite important ;)

Cheers, Mario


 Mario Ohnewald [EMAIL PROTECTED] wrote in message
 001901c26480$5e280df0$350aa8c0@W2KDP">news:001901c26480$5e280df0$350aa8c0@W2KDP...
  Hi Henry,
 
 
From: Henry [mailto:[EMAIL PROTECTED]]
  
  
   Have you tried using single quotes arround the main string?
  
   i.e. 'echo echo blah blah'
 
  I have tried serveral of version, maybe you could give me
 your example
 from
  the lines below.
  I couldnt work it out ;(
 
 
  
   Henry
  
   Henry [EMAIL PROTECTED] wrote in message
   [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
use \ instead of  so that you don't actually end the string
   
Henry
   
Mario Ohnewald [EMAIL PROTECTED] wrote in message
001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
 Hello!
 I want to write a line into a file (called $script) wich
   goes like that:

  echo `date` 192.168.10.123 is down, lets call
   the admin. I was
 sleeping for 10 Minutes | smbclient -M Computer

 This is what i have tried:
 exec(echo echo `date` === $ip is down, lets
   call the admin.
   I
 was sleeping for $var_timer_rechner1 Minutes | smbclient
   -M $popup_1
   
 $script);

 The problem is that after
 exec(echo 
 its command ends due to that .

 I tried \ to let php ignore this  but then it
 doesn´t write my 
anymore:
  exec(echo \echo \`date` === $ip is down,
   lets call the
   admin.
I
 was sleeping for $var_timer_rechner1\ | smbclient -M
   $popup_1\ 
 $script);

 this is the result:
 echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
   down, lets call
the
 admin. I was sleeping for  | smbclient -M Server

 but i want:
 echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is
   down, lets call
the
 admin. I was sleeping for | smbclient -M Server

 ^^
 ^^
 missing
 missing


 Can anyone tell me where the my mistake is?


 Cheers, Mario

   
   
  
 
  mario
 



 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re: exec(echo ... issuse

2002-09-25 Thread Marek Kilimajer

this must work:

exec('echo `date` 192.168.10.123 is down, lets call the admin. I was 
sleeping for 10 minutes | smbclient -M '. $compname);

Mario Ohnewald wrote:

Hi Henry!


  

From: Henry [mailto:[EMAIL PROTECTED]]

How about

?php
$command=\`date` === $ip is down, lets call the admin. I
was sleeping for $var_timer_rechner1 Minutes\ | smbclient -M
$popup_1 
$script;
exec(echo \$command\);
?



Nope, hasnt worked either ;(

any other idea?
this is quite important ;)

Cheers, Mario
  

Mario Ohnewald [EMAIL PROTECTED] wrote in message
001901c26480$5e280df0$350aa8c0@W2KDP">news:001901c26480$5e280df0$350aa8c0@W2KDP...


Hi Henry,


  

 From: Henry [mailto:[EMAIL PROTECTED]]


Have you tried using single quotes arround the main string?

i.e. 'echo echo blah blah'


I have tried serveral of version, maybe you could give me
  

your example
from


the lines below.
I couldnt work it out ;(


  

Henry

Henry [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...


use \ instead of  so that you don't actually end the string

Henry

Mario Ohnewald [EMAIL PROTECTED] wrote in message
001801c2647a$070aa100$350aa8c0@W2KDP">news:001801c2647a$070aa100$350aa8c0@W2KDP...
  

Hello!
I want to write a line into a file (called $script) wich


goes like that:


 echo `date` 192.168.10.123 is down, lets call


the admin. I was


sleeping for 10 Minutes | smbclient -M Computer

This is what i have tried:
exec(echo echo `date` === $ip is down, lets


call the admin.
I


was sleeping for $var_timer_rechner1 Minutes | smbclient


-M $popup_1


$script);

The problem is that after
exec(echo 
its command ends due to that .

I tried \ to let php ignore this  but then it


doesn´t write my 


anymore:
  

 exec(echo \echo \`date` === $ip is down,


lets call the
admin.


I
  

was sleeping for $var_timer_rechner1\ | smbclient -M


$popup_1\ 


$script);

this is the result:
echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is


down, lets call


the
  

admin. I was sleeping for  | smbclient -M Server

but i want:
echo Wed Sep 25 12:29:17 CEST 2002 === 192.168.10.1 is


down, lets call


the
  

admin. I was sleeping for | smbclient -M Server

^^
^^
missing
missing


Can anyone tell me where the my mistake is?


Cheers, Mario



  

mario

  


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





  



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php