1

I have an image that I am using as a divider that is basically a colon (:) repeated across the page, however instead of going all the way across I only want it to go about 80% or around 700px. Is there some CSS to set how far the image repeats?

redf150flames
  • 21
  • 2
  • 10
  • Same question [here](http://stackoverflow.com/questions/2949606/repeat-css-background-image-a-set-number-of-times) – Iwo Kucharski Jul 29 '13 at 07:50
  • Just wrap your content in a div, set the div to 80% width and apply the background to that div.. – Ben Jul 29 '13 at 07:51
  • I tried this without success... HTML `

    Pre-Construction Phase

    ` CSS `.h-wrapper-rtl { width: 700px; margin-bottom: 20px; background: url(/images/divider.png) 0 center repeat-x; float: left; }`
    – redf150flames Jul 29 '13 at 07:56

1 Answers1

0

How about putting the image in a div that is 700px wide and set the background image repeat-x to 100%?

mickadoo
  • 3,337
  • 1
  • 25
  • 38
  • I tried this without success... HTML `

    Pre-Construction Phase

    ` CSS `.h-wrapper-rtl { width: 700px; margin-bottom: 20px; background: url(/images/divider.png) 0 center repeat-x; float: left; }`
    – redf150flames Jul 29 '13 at 07:54
  • If you want your text to come right after the border I'd float them both to left. Also your border holder will need a height and I changed it to div. http://jsfiddle.net/mickadoo/XvMeP/ – mickadoo Jul 31 '13 at 09:12