0

Using sIFR rev. 436, latest release. Replaces h1, h2, h3, h4 tags flawlessy, as many as I have on the page. However, if i try replacing a custom div, say Replace Me it replaces only the first instance, but not the others on the page. I tested this on the 2.0 release as well and got the same results. Is this just a limitation of the software that it won't let me do this?

2 Answers2

1

It should work.

Is "Replace Me" a class or an id?

Paste relevant pieces of code that shows what works and what doesn't work.

oldwizard
  • 5,012
  • 2
  • 31
  • 32
  • Check out the link here, I've got three divs with the id of champion, only one gets replaced. I also have three h1 tags, all three get replaced. LINK: http://work.mrmworldwideprn.com/Client/Applebees/sIFR/applebees/index.html –  Jul 13 '09 at 15:48
1

The id attribute has to have a unique value, having more than one element with the same id is wrong.

To use the same styling for multiple elements use the class attribute.

replace this html

<div id="champion">DELICIOUS APPETIZERS</div>
<div id="champion">Appetizers</div>
<div id="champion">Ulitimate Trios</div>

with

<div class="champion">DELICIOUS APPETIZERS</div>
<div class="champion">Appetizers</div>
<div class="champion">Ulitimate Trios</div>

And replace this in your sifr config

sIFR.replace(champion, {
  selector: '#champion',
  css: '.sIFR-root { color: #c21212; }'
});

with this

sIFR.replace(champion, {
  selector: '.champion',
  css: '.sIFR-root { color: #c21212; }'
});
oldwizard
  • 5,012
  • 2
  • 31
  • 32
  • That worked great thanks! Now on IE7 my H6 tags get replaced with flash and then disappear from the screen. Check this link: http://72.32.182.2/v4/menulanding.aspx Any ideas why this is happening? Check it in FF to see what it should look like. Thanks in advance for your help! –  Jul 20 '09 at 20:53
  • Belay my last...there was a 5px bottom margin on the image that was pushing the text down, making it disappear. Thanks again for all of your help! –  Jul 21 '09 at 18:58