WebspherePortalServerにいくつかのポートレットがデプロイされています。cssファイルには、imgタグの動作属性が含まれています。
img {
position:relative;
border:none;
outline:none;
behavior: expression((this.runtimeStyle.behavior="none")&&(this.pngSet?this.pngSet=true:(this.nodeName == "IMG" && this.src.toLowerCase().indexOf('.png')>-1?(this.runtimeStyle.backgroundImage = "none", this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src + "', sizingMethod='image')", this.src = "transparent.gif"):(this.origBg = this.origBg? this.origBg :this.currentStyle.backgroundImage.toString().replace('url("', '').replace('")', ''), this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.origBg + "', sizingMethod='crop')", this.runtimeStyle.backgroundImage = "none")), this.pngSet=true) );
}
この動作タグによって複数のHTTPリクエストが発生することがわかりました。ポートレットJSPの1つに、次のようなスタイルクラスが含まれています。
<link rel="stylesheet" type="text/css" title="Style"
href=''<%=request.getContextPath()+"/theme/stylesheet.css" %>'>
問題は、そのrequest.getContextPath()がある場合にのみ発生します。それを実際のコンテキストルートに置き換えても、問題は発生しません。誰かがその動作属性が問題を引き起こしている理由を教えてもらえますか?