I have a folder inside my ASP.NET web application. I put all css files inside 'App_Theme'. What is the right method to specify an image as background of a 'div' if I place image1.jpg inside "Icons/images" directory. The options for url are :-
Which is correct ?
@muhammed; write this for image path if your css in single folder
background-image: URL("../Icons/jquery/image1.jpg");
& if there is another folder inside of the main folder for example stylesheet folder
& there is another folder inside it suppose css folder
then we write
background-image: URL("../../Icons/jquery/image1.jpg");
Go to your css file, right-click on the css class name > Build Style > Background > Browse the image. It'll put the URL in for you.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With