diff --git 1.0/index.php 1.0/index.php
index 908cfa2..554f258 100644
--- 1.0/index.php
+++ 1.0/index.php
@@ -216,6 +216,7 @@ function guess_location_from_city( $location_name, $timezone, $country_code ) {
 
 	$cache_key = 'guess_location_from_city:' . md5( $location_name . ':' . $timezone . ':' . $country_code );
 	$guess     = wp_cache_get( $cache_key, $cache_group );
+	$guess     = false;   // @todo tmp disable caching for manual testing
 
 	if ( $guess ) {
 		if ( '__NOT_FOUND__' == $guess ) {
@@ -267,36 +268,44 @@ function guess_location_from_geonames( $location_name, $timezone, $country, $wil
 	// The FIELD() orderings give preference to rows that match the country and/or timezone, without excluding rows that don't match.
 	// And we sort by population desc, assuming that the biggest matching location is the most likely one.
 
+	add_db_table( 'geoip', 'geoname_summary_utf8mb4_test' ); // @todo tmp
+
 	// Exact match
-	$row = $wpdb->get_row( $wpdb->prepare( "
+	$query = "
 		SELECT name, latitude, longitude, country
-		FROM geoname_summary
+		FROM geoname_summary_utf8mb4_test
 		WHERE name = %s
 		ORDER BY
 			FIELD( %s, country  ) DESC,
 			FIELD( %s, timezone ) DESC,
 			population DESC
-		LIMIT 1",
-		$location_name,
-		$country,
-		$timezone
-	) );
+		LIMIT 1";
+
+	$prepared_query = $wpdb->prepare( $query, $location_name, $country, $timezone );
+	$db_handle      = $wpdb->db_connect( $prepared_query );
+
+	$wpdb->set_charset( $db_handle, 'utf8' ); // The content in this table requires a UTF8 connection.
+	$row = $wpdb->get_row( $prepared_query );
+	$wpdb->set_charset( $db_handle, 'latin1' ); // Revert to the default charset to avoid affecting other queries.
 
 	// Wildcard match
 	if ( ! $row && $wildcard && 'ASCII' !== mb_detect_encoding( $location_name ) ) {
-		$row = $wpdb->get_row( $wpdb->prepare( "
+		$query = "
 			SELECT name, latitude, longitude, country
-			FROM geoname_summary
+			FROM geoname_summary_utf8mb4_test
 			WHERE name LIKE %s
 			ORDER BY
 				FIELD( %s, country  ) DESC,
 				FIELD( %s, timezone ) DESC,
 				population DESC
-			LIMIT 1",
-			$wpdb->esc_like( $location_name ) . '%',
-			$country,
-			$timezone
-		) );
+			LIMIT 1";
+
+		$prepared_query = $wpdb->prepare( $query, $wpdb->esc_like( $location_name ) . '%', $country, $timezone );
+		$db_handle      = $wpdb->db_connect( $prepared_query );
+
+		$wpdb->set_charset( $db_handle, 'utf8' ); // The content in this table requires a UTF8 connection.
+		$row = $wpdb->get_row( $prepared_query );
+		$wpdb->set_charset( $db_handle, 'latin1' ); // Revert to the default charset to avoid affecting other queries.
 	}
 
 	// Suffix the "State", good in some countries (western countries) horrible in others
@@ -306,6 +315,11 @@ function guess_location_from_geonames( $location_name, $timezone, $country, $wil
 	//	 $row->name .= ', ' . $row->state;
 	// }
 
+	// Strip off null bytes - @todo should be possible to use avoid these in the raw data?
+	if ( ! empty( $row->name ) ) {
+		$row->name = trim( $row->name );
+	}
+
 	return $row;
 }
 
