Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-27-2009, 02:12 PM   PM User | #1
cesarcesar
Regular Coder

 
Join Date: Apr 2007
Posts: 144
Thanks: 5
Thanked 0 Times in 0 Posts
cesarcesar is an unknown quantity at this point
patch not working as example

I'm using the code found here. I am trying to insert some new code as per the instructions here. I have not been successful. The code i think I'm supposed to change is,

Code:
IE7.CSS.addFix(/background(-image)?\s*:\s*([^};]*)?url\(([^\)]+)\)([^;}]*)?/,function(a,b,c,d,f){d=cC(d);return bi.test(d)?"filter:"+i(bx,d,"crop")+";zoom:1;background"+(b||"")+":"+(c||"")+"none"+(f||""):a});
And its updated form should be like,

Code:
	IE7.CSS.addFix(/background(-image)?\s*:\s*([^};]*)?url\(([^\)]+)\)([^;}]*)?/,function(match, $1, $2, url, $4) {
		url = getString(url);

		// Hack for bg repeating support
		var repeatExp = new RegExp('repeat-[xy]','i');
		var scalingMethod = 'image'; // or crop
		var overflow = '';
		if (repeatExp.test($4)) {
			var scalingMethod = 'scale';
			overflow = 'overflow:hidden;';
		}

		return PNG.test(url) ? overflow + "filter:" + format(PNG_FILTER, url, scalingMethod) + ";zoom:1;background" + ($1||"") + ":" + ($2||"") + "none" + ($4||"") : match;

	});
Why is it not working? Thanks much.
cesarcesar is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:43 PM.


Advertisement
Log in to turn off these ads.