Surface critical behaviour of fluids and magnets