aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes foreColor, backColor not displayed using jquery Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "foreColor, backColor not displayed using jquery" Watch "foreColor, backColor not displayed using jquery" New topic
Author

foreColor, backColor not displayed using jquery

Vishal Hegde
Ranch Hand

Joined: Aug 01, 2009
Posts: 1055

Hi,

Below is the js file which is displaying the below error message

Error:
---------------------------
$(this.css) is not a function
[Break On This Error]

'background-color':backcolor
---------------------------

jquery.highlight.js


highlight.html


Please assist where I am going wrong


http://www.lifesbizzare.blogspot.com || OCJP:81%
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

$(this.css) is not a function

Is that the valid syntax?

(Hint: no.)

(And please take the time to format your code correctly. What you posted is unacceptably messy.)


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Vishal Hegde
Ranch Hand

Joined: Aug 01, 2009
Posts: 1055

Thanks , i resolved it.One more issue, what does the last line (jQuery); mean
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

That whole construct is called an immediate function. The function is declared, executed and discarded all in that same statement. The (jQuery) portion of the statement is the function's argument list. It's assigned to the $ parameter of the function.

It forces the $ to equate to jQuery within the function, even if something outside of the function redefines $ to mean something else.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: foreColor, backColor not displayed using jquery