Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Setting images within CSS

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 11-24-2002, 10:16 AM
  Hyperdelicious's Avatar 
Hyperdelicious Hyperdelicious is offline
 

Senior Member
  
Join Date: Sep 2002
Location: In the Middle of Nowhere
Posts: 138
 

Default Setting images within CSS

===============================================

How do you set images in CSS... for instance I created a gif for bulleted
lists and I would like to use CSS to replace the bullet with the gif...

Code:
LI { list-style-image : url({$ImagesDir}/li_bullet.gif); vertical-align : middle; color : #40445E; font-weight : bold; }

However this does not appear to work with x-cart... I'm thinking it has
something to do with these{ }... any ideas?

--------------------------------------------------------THANKS-------------------


HYPERDELICIOUS
===============================================
===============================================
Reply With Quote
  #2  
Old 11-24-2002, 10:57 AM
 
tmx tmx is offline
 

Member
  
Join Date: Nov 2002
Location: Arizona (USA)
Posts: 28
 

Default ...

Are you putting it into the tpl your using it in or did you put it in the CSS file that x-cart already has? If your using it in the tpl you could also try putting {literl} {/literal} in the beginning and end.
__________________
-tmx-
Reply With Quote
  #3  
Old 11-24-2002, 11:04 AM
  Hyperdelicious's Avatar 
Hyperdelicious Hyperdelicious is offline
 

Senior Member
  
Join Date: Sep 2002
Location: In the Middle of Nowhere
Posts: 138
 

Default Editing skin1.css

===============================================

I placed the following code into skin1.css... therefore I am editing the
Style Sheet x-cart came with...


Code:
LI { list-style-image : url({$ImagesDir}/li_bullet.gif); vertical-align : middle; color : #40445E; font-weight : bold; }


any ideas... how to get this to work?

--------------------------------------------------------THANKS-------------------


HYPERDELICIOUS
===============================================
===============================================
Reply With Quote
  #4  
Old 11-24-2002, 11:14 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

I would imagine that you would have to use the full url to the bullet image.

Quote:
LI {
list-style-image : url(http://www.yoursite.com/xcart/skin1/images/li_bullet.gif);
vertical-align : middle;
color : #40445E;
font-weight : bold;
}

See if that works
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #5  
Old 11-24-2002, 11:16 AM
 
tmx tmx is offline
 

Member
  
Join Date: Nov 2002
Location: Arizona (USA)
Posts: 28
 

Default ...

Try this, Put this into your CSS File...

Code:
ul { list-style-image: url("li_bullet.gif"); }

And then to list set it up like so...

Code:
<ul>[*]Your text[/list]
__________________
-tmx-
Reply With Quote
  #6  
Old 11-24-2002, 11:32 AM
  Hyperdelicious's Avatar 
Hyperdelicious Hyperdelicious is offline
 

Senior Member
  
Join Date: Sep 2002
Location: In the Middle of Nowhere
Posts: 138
 

Default Thanks

===============================================

Thanks Shan, I had tried the absolute URL and it did not work... but
checking your code against mine I realized I forgot a '/ ' ... my
code actually looked like this...

Code:
http://www.mysite.com/xcart/skin1/imagesil_bullet.gif

Human error... anyway do you think it will screw with the SSL key since
the image is being pulled from http:// rather than https://? If so do you
think I should change the URL of the image to https://?

-------------------------------------------------------THANKS--------------------


HYPERDELICIOUS
===============================================
===============================================
Reply With Quote
  #7  
Old 11-24-2002, 12:45 PM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

yeh, just set it from hte https sever and it will be fine for both then
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #8  
Old 11-24-2002, 12:51 PM
  Hyperdelicious's Avatar 
Hyperdelicious Hyperdelicious is offline
 

Senior Member
  
Join Date: Sep 2002
Location: In the Middle of Nowhere
Posts: 138
 

Default Thanks

===============================================

Thanks again Shan... I appreciate your help/advice.

--------------------------------------------------------------THANKS-------------



HYPERDELICIOUS
===============================================
===============================================
[/b]
Reply With Quote
  #9  
Old 11-28-2002, 10:34 PM
 
funkydunk funkydunk is offline
 

X-Man
  
Join Date: Oct 2002
Location: Cambridge, UK
Posts: 2,210
 

Default

If you set the url as relative to the skin1.css file this will work.

ie.

LI {
list-style-image : url(images/li_bullet.gif);
vertical-align : middle;
color : #40445E;
font-weight : bold;
}
__________________
ex x-cart guru
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 06:56 AM.

   

 
X-Cart forums © 2001-2020