People should check local laws about medication before travelling abroad, the government says.