Use a common ping JS function.
GH #105 - Added ping on frontend.