When French pupils go back to school next month, they will no longer be allowed to use their smartphones or tablets while on school grounds.