LostInQuery
LostInQuery

Reputation: 519

Cufon - Ignore Child Class/Elements

So, I am using Cufon & jQuery and have titles along the lines of

<h4>My Title &hearts; Funny Symbols</h4>

I am using WordPress and am able to parse out the ♥ symbols and wrap them in a span so I end up with something along the lines of

<h4>My Title <span class="heart-wrap">&hearts;</span> Funny Symbols</h4>

But, now I need to figure out how to make Cufon ignore the internal span, as the font that is being used, doesn't have a symbol for hearts; so I would like for it to default back to the standard Arial font or whatever I decide to use in the CSS so I can style the symbol.

I've looked around and I've seen some posts and tried their examples, but none of it seems to be working. Most seem to target multi-level navigation and all that. Any ideas how to solve this? Would be much appreciated.

Thanks!

EDIT:

Answer found in link in comment

Cufon.replace('h4', {
  ignore: {
    span: true
  }
});

Upvotes: 2

Views: 1940

Answers (1)

LostInQuery
LostInQuery

Reputation: 519

Cufon.replace('h4', {
  ignore: {
    span: true
  }
});

http://groups.google.com/group/cufon/browse_thread/thread/615af479894f6478?pli=1

Upvotes: 5

Related Questions