Pretty simple to doubt. Redirect by .htaccess containing a subdomain wildcard and hash.
From:
http://carros.domain.com/visualizar#123
http://casas.domain.com/visualizar#345
http://aps.domain.com/visualizar#567
To:
http://domain.com/carros/ver#123
http://domain.com/casas/ver#345
http://domain.com/aps/ver#567
My biggest problem is to change the "view" to the "see". I tried many ways and failed the mission.
Something approximate that I found here in the stack:
RewriteCond %{HTTP_HOST} ^(.*)\.domain\.com/visualizar
RewriteRule ^(.*)$ http://domain.com/%1/ver/$1 [L,NC,QSA]
EDIT:
Solution that worked based on the responses of these beautiful people:
RewriteCond %{HTTP_HOST} carros\.domain\.com
RewriteCond %{REQUEST_URI} visualizar([^#]+)?([#\d\w\s]+)?
RewriteRule (.*) http://domain.com/ver%1%2 [R=301,L]
I repeated this for all my subdomains.