Tourist visas are for 60 days, not 30. How many days in Thailand they get with crossing the border and coming back depends on their nationality. If they are entitled to visa exemption they get 30 days which can be extended once to 30 more days at an immigration office.