Using a taxonomy value as part of a post URL

Add or replace this to your register_taxonomy (in functions.php):

'query_var' => 'city',
'rewrite' => true

Then append this to your functions.php

add_filter('post_link', 'city_permalink', 10, 3);
add_filter('post_type_link', 'city_permalink', 10, 3); 
function city_permalink($permalink, $post_id, $leavename) {
  if (strpos($permalink, '%city%') === FALSE) return $permalink;
  // Get post
  $post = get_post($post_id);
  if (!$post) return $permalink;
  // Get taxonomy terms
  $terms = wp_get_object_terms($post->ID, 'city');   
  if (!is_wp_error($terms) && !empty($terms) && is_object($terms[0])) $taxonomy_slug = $terms[0]->slug;
  else $taxonomy_slug = 'not-rated';
  return str_replace('%city%', $taxonomy_slug, $permalink);
}

Here you can find a more detailed description.