Foren

Round corners in IE

thumbnail
Roman Hoyenko, geändert vor 12 Jahren.

Round corners in IE

Liferay Master Beiträge: 878 Beitrittsdatum: 08.10.07 Neueste Beiträge
I am trying to add round corners in IE7 with this hack:
http://code.google.com/p/curved-corner/

Basically, you need to include something like this:

.rounded-corners {
behavior: url(border-radius.htc);
border-radius: 20px;
}

the problem is the path to border-radius.htc works differently than you may expect—unlike background-image paths which are relative to the stylesheet, this path is relative to the page from which you call the CSS.

So, my question is - what is the root of the theme, how can I reference the file so it's being loaded? I'd prefer absolute path since I don't know where this is being called from.
I tried putting this htc file everywhere in the theme - in the top directory, into css, etc. I even put it in the root of portal itself, but it didn't help.
thumbnail
Deb Troxel, geändert vor 12 Jahren.

RE: Round corners in IE (Antwort)

Junior Member Beiträge: 81 Beitrittsdatum: 22.02.10 Neueste Beiträge
You can use your theme project name for the root path. For example, if your theme war file is named myTheme-theme-6.0.6.1.war then the absolute path to your files will be /myTheme-theme/...

I think it's good practice to put all your files under _diffs, so if you put border-radius.htc directly under _diffs and deploy, then the path would be /<theme>-theme/border-radius.htc.

From this post http://www.liferay.com/community/forums/-/message_boards/message/5390868 it looks like there is an option to specify your own context path rather than use the theme name, but I haven't done that.
thumbnail
Roman Hoyenko, geändert vor 12 Jahren.

RE: Round corners in IE

Liferay Master Beiträge: 878 Beitrittsdatum: 08.10.07 Neueste Beiträge
That worked, thanks so much!
Dhivya Das, geändert vor 11 Jahren.

RE: Round corners in IE

New Member Beiträge: 9 Beitrittsdatum: 30.12.10 Neueste Beiträge
Hi,

I i tried putting the border-radius.htc file under the _diffs and in my css i have added behavior: url(/test-theme/border-radius.htc);. But it is not reflecting.

Please guide me in this.

Regards,
Dhivya
Theoni Zaharia, geändert vor 11 Jahren.

RE: Round corners in IE

New Member Beiträge: 21 Beitrittsdatum: 22.02.12 Neueste Beiträge
Hi Roman Hoyenko
can you help us solve the problem?

We have added behavior:url(border-radius.htc); to custom.css but the problem isn't solved in IE