Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

CSS not working in IE

Featured Replies

Hi all,

 

I've just got PIE3 working for IE, so I can apply CSS3 border-radius. It works fine, just I can't seem to get the borders to appear that surround a few elements in the rightContent:

 

eg. the photo here of canary wharf should have a 3px green border around it, like it does in all other browsers - http://pt-academy.co.uk/about-us/

 

eg and on this page, the 3 logos should be in a 3px orange box, like it is on all other browser - http://pt-academy.co.uk/payment-options/

 

Does anyone know what I could do to fix this, so the borders appear in IE?

 

Cheers.

 

Rich

I suspect your pie.htc is not being found. Try an implicit path to it so start with to see if that fixes it and then, probably, add a ../ to your link in the css. your css is in a sub-sub folder and the pie.htc is relative to the css.

  • Author

Cheers all...I've used !important; in the CSS rule and the borders now appear, so that's cool :)

 

But the PIE3 rounded edges still don't work. What can I do to fix this?

 

Cheers!

  • Author

Why should I avoid using !important and what could I use instead?

 

And no I didn't change my paths as they are ok. The PIE3 path works for everything else, bar these borders.

 

url(../js/PIE.htc)

 

This is the correct path, and the one used with all the borders. Or do you mean something else? What's an implicit path?

Edited by futureproof

okay just did some testing.

 

html

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />

<link href="defaultx.css" type="text/css" rel="stylesheet" />

<title>Untitled 1</title>
</head>

<body>
<div id="me"><img alt="Hire Me" src="http://pt-academy.co.uk/images/canary-wharf.jpg" /></div>


</body>

</html>

 

css

#me {
   border: 3px solid #83a02f;
   -webkit-border-radius: 3px;
   -moz-border-radius: 3px;
   border-radius: 3px;
   behavior: url(pie.htc);
}

 

works a treat. If you add the !important it doesn't work and if I use your full css it doesn't work either so it's probably getting screwed up somewhere, maybe all the !importants or could even be some other JS?

  • Author

Hi Zed, it's not working here. I've just added your CSS, but no joy.

 

Am I missing something?

Edited by futureproof

  • Author

Ok I just tried putting the .HTC file into the same folder as the CSS but it still isn't working. What else can I do, or am I still not doing something as you suggest?

Edited by futureproof

Try giving your #greenborder and .paymentOptions position:relative; its working but is getting hidden behind the parent

 

 

tried this? I just did and it sort of works, there is still another white border coming from somewhere. And the !importants will work with this.

  • Author

tried this? I just did and it sort of works, there is still another white border coming from somewhere. And the !importants will work with this.

 

Yeah, tried that but it didn't work. Hmm...

 

Cheers for you help anyway man.

strange, it does locally for me. This is my css for #greenborder if it helps at all.

 

#greenBorder {
position:relative;
    border: 3px solid #83a02f;
   -webkit-border-radius: 3px;
   -moz-border-radius: 3px;
   border-radius: 3px;
   behavior: url(pie.htc);
}

 

could have sworn it worked with the !important but now it doesn't so that may be the trick.

  • Author

It is, well never mind, it might have something to do with the operating system I'm viewing it from. I've just tried your CSS again and no luck. Cheers for all your help though man.

All you needed to do was add the position relative to get the Z-index to set correctly

remove your !important and it should work

 

example I didn't load all your images just yhe main one to show you it working

  • Author

Hi Jack, I already tried that and it didn't work for me.

 

I can see that it has worked for you, so not sure what I can do or why it is not working for me.

 

I've realised last night as well that the PIE3 rounded edges for the brochure form in the right column, also doesn't work, only on the index page though...which is very odd...

yeah the index works I think because of your link to the pie file. You have ../js/PIE.htc and on the index page it will find it okay. Your other pages are one folder down so should be ../../js/PIE.htc

 

When I tested and mteam did we put the PIE.htc in the root folder along with the HTML file we created.

 

Probably the best way for your structure is to put the complete path to the PIE.htc file in your css (implicit rather than relative) ie. http://pt-academy.co.uk/js/PIE.htc

 

That should work.

  • Author

No, as I've said, the PIE3 works on all the pages, it's just the green and orange borders that aren't having the PIE3 applied to them (see original thread).

 

As for the index page, you are right there, but it would be the opposite of what you said if you know what I mean, as PIE3 currently works on all pages other than the index page. So, that will be easy to sort, I didn't think about that.

 

Now just the original bug to try and fix...

 

I'll try and add in that type of path, I didn't know that's what an implicit path was, I thought that was called an absolute URL?? Or are they the same thing?

 

Cheers for all your help guys, I'll let you know how it goes in a sec...

Edited by futureproof

  • Author

Nope, tried all that, given all the paths every combo inc implicit, and still no joy.

  • Author

Removed, accidentally posted again

Edited by futureproof

  • Author

I tried that and I didn't work Zed. I'm testing all this locally, might that be the reason?

it shouldn't do but just makes it difficult for us to see ;)

 

Here's a test I did http://www.bigzed.net/pst/pst.html

 

I just took your online code, hardcoded some of the js/image links in the HTML to save downloading them, position:relative and removed the !important on the #brochure and #greenBorder and linked to pie.htc in the same directory.

  • Author

Funnily enough, I've just removed the !important from the greenBorder and now works :unknw:

 

So, just got to get over the index page not working at all (which I now know what it is thanks to Zed, I just got to work out how to do this), and the orange borders still don't work.

Edited by futureproof

on my test I didn't fix the orange borders (#application .content). Have done now on the same test page.

  • Author

I've just added the #application .content CSS you have and it didn't work for me still. I can see you have it working, just can't see why your is working and mine isn't...

 

I've uploaded the changes this CSS rule as well, so you can see it isn't working, or is it working for you?

 

http://pt-academy.co.uk/book-now/

Edited by futureproof

  • Author

OMG at last :)

 

Well, it seemed it was the combination of removing !important and having position:relative; at the top of the rule. Thanks to you both for this.

 

Now how do I fix the index page issue? The index page is top level, how do I apply all of the rules to this page?

 

Cheers!

 

...actually scrap that, that bug seems to be fixed as well now...

Edited by futureproof

  • Author

Yeah I know, I wouldn't have through that would of been fixed as well, but it has been. Great stuff I'm well happy.

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.