Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6651857
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T01:03:41+00:00 2026-05-26T01:03:41+00:00

I`m using LessCSS, java, and colorbox. Colorbox has a css file. One of the

  • 0

I`m using LessCSS, java, and colorbox. Colorbox has a css file. One of the styles is as follow:

.cboxIE6 #cboxMiddleRight {
    _behavior: expression(this.src = this.src ? this.src : this.currentStyle.backgroundImage.split('"')[1], this.style.background = "none", this.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src=" + this.src + ", sizingMethod='scale')");
}

it´s seems i´m need to use an escape character. When lesscss compiles the file, i getting the error

javax.servlet.ServletException: Parse Error: Syntax Error on line 77 (line 77, column 1) near
.cboxIE6 #cboxMiddleRight {
 _behavior: expression(this.src = this.src ? this.src : this.currentStyle.backgroundImage.split('"')[1], this.style.background = "none", this.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src=" + this.src + ", sizingMethod='scale')");
}

then i tried this..

.cboxIE6 #cboxMiddleRight {
    _behavior: ~"expression(this.src = this.src ? this.src : this.currentStyle.backgroundImage.split(\'\"\')[1], this.style.background = \"none\", this.style.filter = \"progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\" + this.src + \", sizingMethod=\'scale\')\")";
}

but. i get an error saying i´m missing a closing “}”

I don´t know how to solve this. Sure it´s a simple thing, but i can´t solve it.

Here is the java less css configuration (web.xml):

<servlet>
    <servlet-name>less</servlet-name>
    <servlet-class>com.asual.lesscss.LessServlet</servlet-class>
    <init-param>
        <param-name>compress</param-name>
        <param-value>true</param-value>
    </init-param>
    <init-param>
        <param-name>cache</param-name>
        <param-value>false</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
    </servlet>


<servlet>
    <servlet-name>resource</servlet-name>
    <servlet-class>com.asual.lesscss.ResourceServlet</servlet-class>
    <load-on-startup>2</load-on-startup>
</servlet>

<servlet-mapping>
    <servlet-name>less</servlet-name>
    <url-pattern>*.css</url-pattern>
</servlet-mapping>

Any idea?

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T01:03:41+00:00Added an answer on May 26, 2026 at 1:03 am

    This compiles fine for me:

    .cboxIE6 #cboxMiddleRight {
      _behavior: ~`this.src = this.src ? this.src : this.currentStyle.backgroundImage.split('"')[1], this.style.background = "none", this.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src=" + this.src + ", sizingMethod='scale')"`;
    }
    

    but it also tries executing the JavaScript at compile time. To avoid that, you could add another more quotes:

    .cboxIE6 #cboxMiddleRight {
      _behavior: ~`"\"this.src = this.src ? this.src : this.currentStyle.backgroundImage.split('\\\"')[1], this.style.background = \\\"none\\\", this.style.filter = \\\"progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\\\" + this.src + \\\", sizingMethod='scale')\""`;
    }
    

    Though it looks ugly, it compiles down to this:

    .cboxIE6 #cboxMiddleRight {
      _behavior: "this.src = this.src ? this.src : this.currentStyle.backgroundImage.split('\"')[1], this.style.background = \"none\", this.style.filter = \"progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\" + this.src + \", sizingMethod='scale')";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

using CodeIgniter normally one has to specify the controllers in the config/routes.php file. This
I am using NetBeans 6.5 and whenever I save a LessCSS file I would
Has anyone got EclipseLink MOXy (I'm using eclipselink 2.1.0) to work with Java 5?
I'm using lesscss, the 'framework/compiler' for css. My IDE, dreamweaver, does not recognize .less
I am using lesscss.org 's styles on my MVC application. It works great, but
Using TortoiseSVN against VisualSVN I delete a source file that I should not have
Using C#, I need a class called User that has a username, password, active
Using jQuery's UI Tabs. This is my code. <div id=tabs> <ul> <li><a href=#tabs-1>Find a
I am attempting to pull some information from my tnsnames file using regex. I
Using Java (1.6) is it better to call the clear() method on a List

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.