It shall be unlawful for any person to own or keep a dog or dogs in the city without first obtaining a license for each dog. This section and §
94.27 shall not apply to dogs whose owners are nonresidents temporarily within the city for a period less than 30 days.