html - How do I "<img src='url'..." without having the domain in the url? -
it's silly question can't find right way it.
i making wordpress theme myself , in css, specifying image sources full domain.
example:
#header { background: #ffffff url("http://mydomain.com/wp-content/themes/mytheme/images/header-bg.jpg"); }
i want make sure works if install theme in domain. proper way specify source in case?
you have use relative paths css file, example if have following structure:
/mytheme/images/header-bg.jpg /mytheme/style.css
then @ style.css make rule this:
#header { background: #ffffff url("images/header-bg.jpg"); }
Comments
Post a Comment