Go to your local Immigration office, ask them for the requirements, get readyall docs required, go back to immigration, pay the fee.......and wait for the stamp. Total cost for visa is 2000 baht!!
well, if immigration have already flagged you, it will be totally up to the immigration officer, at point of entry, whether to let you in or not. Most probably, your name is down in the system already....good luck