Archived topic
Footer: numbers automatically format as link
5 replies · Started by Marc Witschi on May 7, 2019
If I open my Website on a mobilephone it automatically formats numbers as a phonenumber even thought it's a bank account number:
https://ibb.co/pzQc5J1
All those in the red boxes should be links. Only the phone number and mail address should be.
Can you help me with this?
Hi there,
try wrapping the content that shouldn't be a link in <span>my non link elements here</span> tags.
I tried like this, didn't work...
<p><span>Kinderheim Friedau ' Bern-Zürichstrasse 28 ' 3425 Koppigen ' Telefon</span> <a href="tel:+4134 413 11 37">034 413 11 37</a><span> ' Fax 034 413 11 38</span></p>
<p><a href="mailto:mail@kinderheimfriedau.ch">mail@kinderheimfriedau.ch</a><span> ' PC: CH68 0900 0000 3400 1670 8 ' UBS: CH02 0026 2226 7F68 0234 2</span></p>
Hmmm - mobile browsers can be a pain lol.
Try wrapping them with a dead anchor like so: <a href="#"> 1234567 </a>
I did as you said an added the color to match the other text in the footer:
<a href="#" style="color:white"> 1234567 </a>
If there isn't any more beautiful solution, this will be alright, thanks David!
That is the simplest method. None of them are very beautiful and the other methods are more complicated and not proven on all browsers.