July 13, 200917 yr Does anyone know what code to put in CSS to change the colour of the text 'Buy your copy in the U.K' <a class="buy" href="somelink"> <p> <img src="images/uk-flag.png"/>Buy your copy in the U.K. </img> </p> </a> Thanks, Emma
July 13, 200917 yr Does anyone know what code to put in CSS to change the colour of the text 'Buy your copy in the U.K' <a class="buy" href="somelink"> <p> <img src="images/uk-flag.png"/>Buy your copy in the U.K. </img> </p> </a> Thanks, Emma something likr this should do it .buy p { your font settings } Pat
July 13, 200917 yr Emms, you can't put a block level P tags inside an A tag It should look more like: <p><a class="buy" href="somelink"><img src="images/uk-flag.png"alt="" />Buy your copy in the U.K.</a></p>
July 14, 200917 yr Something's gone wrong with BlueDreamer's reply, the code doesn't show. Perhaps it should be:- <p> <a class="buy" href="somelink"><img src="images/uk-flag.png" alt="Buy your copy in the U.K."/></a> Buy your copy in the U.K. </p> for XHTML doctypes but with the image tag closing with only > not /> for HTML doctypes. as the img tag needs an alt tag but it seems that you also want text next to the image.
Create an account or sign in to comment