your if statement uses a recordset that does not exist on the page.
in your if statement, you are using a recordset named count;
if ($row_count['visitcount'] <= 1) { // Adv Conditional Region
no such recordset is defined on the page, you do have a recordset named WADAclienttable, try using that instead:
if ($row_WADAclienttable['visitcount'] <= 1) { // Adv Conditional Region