Skip to content
a implement of ping in javascript and angularjs
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.idea
bower_components init first commit Apr 27, 2014
dist
src/angular-ping
test/unit/angular-ping
.DS_Store
.editorconfig
.gitignore init first commit Apr 27, 2014
.jshintrc init first commit Apr 27, 2014
Gruntfile.js
LICENSE
README.md
bower.json add bower package Apr 29, 2014
karma-unit.conf.js init first commit Apr 27, 2014
package.json

README.md

angular-ping

a implement of ping in javascript and angularjs

##Info this is a very funny module , you can use command ping in angularjs

Install

    bower install angular-ping

How to use

you can use it like the code below:

   //first you should inject the dependencies
   myApp.module('app',['angular.ping']).controller('testController',['netTesting',function(netTesting){
        netTesting.ping('www.aliyun.com',function(){
           console.log(arguments);
        });

        netTesting.ping('192.168.0.1',function(){
            console.log(arguments);
        });
   }])

   //got the result
   ["www.aliyun.com","connected"]

   //get the result;
   ["192.168.0.1","disconnected"]

Have fun

Any question mail me.

You can’t perform that action at this time.