title: Phonegap PushNotification, how to use my node push-server with phonegap?
body: <p>So, i'm on Phonegap, i use :</p>
  
  <ul>
  <li><a href="https://github.com/phonegap-build/PushPlugin/" rel="nofollow">https://github.com/phonegap-build/PushPlugin/</a></li>
  <li><a href="https://github.com/argon/node-apn" rel="nofollow">https://github.com/argon/node-apn</a></li>
  </ul>
  
  <p>So, i install the first plugin and i can get my phone token. After that, i created a node <code>server.js</code> file in my root directory with :</p>
  
  <pre><code>var apn = require('apn');
  
  var token = "MY TOKEN";
  var device = new apn.Device(token);
  
  var notification = new apn.Notification();
  notification.expiry = Math.floor(Date.now() / 1000) + 3600;
  notification.badge = 1;
  notification.alert = "This is a Push Notification=)";
  notification.payload = {'prop': 'special value'};
  notification.device = device;
  
  var options = {
   gateway: 'gateway.sandbox.push.apple.com',
   cert: 'CER.pem',
   key: 'KEY.pem',
   passphrase: 'password'
  }
  var apnsConnection = new apn.Connection(options);
  apnsConnection.pushNotification(notification, device);
  </code></pre>
  
  <p>When i start my server with <code>node server.js</code> in command line, i can see my push notification on my phone, so all it's ok.</p>
  
  <p>But my question, i need to send push notification in different place in my code (phonegap). How can i do that ? </p>
  
  <p>When my <code>server.js</code> is running, how can i send other push notification from my phonegap application ?</p>