SMS doesn't require data, just a cellular connection. If you can't get that, it could be the phone (check it's not in airplane mode), the SIM could have broken (rebooting the phone sometimes temporarily fixes this if the SIM is only starting to die), or there could be a network outage.
Picture messaging, or stuff like Whatsapp, do require data. If you have a network connection but no data, check your APN settings ("Access Point Names"), in the mobile data settings menu. If those are wrong or not set then you get no mobile data. You should be able to find the correct settings for your network on the web (e.g. your provider's website, or a web search), or else speak to your provider.