US sporting giant Nike saw both earnings and sales grow in its second-quarter thanks to a surge in online sales offsetting lower revenues in the group's wholesale business and owned stores.