<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#ffffff" text="#000000">
    I've done something similar and used exec() to call a shell script:<br>
    <br>
    <a class="moz-txt-link-freetext" href="http://php.net/manual/en/function.exec.php">http://php.net/manual/en/function.exec.php</a><br>
    <br>
    The other option is using the PHP ssh2 module, which support SCP
    transfers:<br>
    <br>
    <a class="moz-txt-link-freetext" href="http://php.net/manual/en/book.ssh2.php">http://php.net/manual/en/book.ssh2.php</a><br>
    <br>
    <pre class="moz-signature" cols="72">Jamie Holly
<a class="moz-txt-link-freetext" href="http://www.intoxination.net">http://www.intoxination.net</a> 
<a class="moz-txt-link-freetext" href="http://www.hollyit.net">http://www.hollyit.net</a></pre>
    <br>
    On 8/26/2010 7:32 PM, Sarah Vardy wrote:
    <blockquote cite="mid:C89D36AD.2517%25s.vardy1@uq.edu.au"
      type="cite">
      <title>How to run a script when a node is added for a custom
        module</title>
      <font face="Calibri, Verdana, Helvetica, Arial"><span
          style="font-size: 11pt;">I am currently developing a module
          for the audio module to enable RTMP streaming and FFMPEG
          encoding. <br>
          <br>
          I am wondering what the best approach is to run the scp
          command (like flash video) when an audio node is added (to add
          the file to an RTMP server)? Can I use hook_form_alter to run
          this command? I am looking through the Drupal API at the
          moment. I also want to run an ffmpeg command as well when the
          node is added to encode the media for storage on the rtmp
          server.<br>
          <br>
          Any help or suggestions would be much appreciated.<br>
          <br>
          Cheers,<br>
          <br>
          scarer</span></font>
    </blockquote>
  </body>
</html>