Fórumok

Round corners in IE

thumbnail
Roman Hoyenko, módosítva 12 év-val korábban

Round corners in IE

Liferay Master Bejegyzések: 878 Csatlakozás dátuma: 2007.10.08. Legújabb bejegyzések
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, módosítva 12 év-val korábban

RE: Round corners in IE (Válasz)

Junior Member Bejegyzések: 81 Csatlakozás dátuma: 2010.02.22. Legújabb bejegyzések
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, módosítva 12 év-val korábban

RE: Round corners in IE

Liferay Master Bejegyzések: 878 Csatlakozás dátuma: 2007.10.08. Legújabb bejegyzések
That worked, thanks so much!
Dhivya Das, módosítva 11 év-val korábban

RE: Round corners in IE

New Member Bejegyzések: 9 Csatlakozás dátuma: 2010.12.30. Legújabb bejegyzések
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, módosítva 11 év-val korábban

RE: Round corners in IE

New Member Bejegyzések: 21 Csatlakozás dátuma: 2012.02.22. Legújabb bejegyzések
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