Jump to content

Help with ClientSide Scripting


cristianotestai

Recommended Posts

Hi,

 

I need a help with JS. What I need to do is the following:

 

1) In a OnMouseOver ExtEvents of the TUniPanel, i need to change the font color of a UniLabel and to change the picture of a UniImage. I tried some alternatives, but without success.

What would the syntax for this purpose?

 

2) In the OnAfterRender Event(UniEdit), I'm setting the following code to assign a background image, but occurs an Ajax Error .. What am I doing wrong?

 

  function OnAfterrender (sender)
 {
   sender.body.applyStyles('background-image:url("http://localhost:8077/ext-3.3.0/resources/images/search.gif")';
 }

 

This same code if i placed directly in the CSS file it works correctly.

 

Thanks

Link to comment
Share on other sites

  • Administrators

 

2) In the OnAfterRender Event(UniEdit), I'm setting the following code to assign a background image, but occurs an Ajax Error .. What am I doing wrong?

 

  function OnAfterrender (sender)
 {
   sender.body.applyStyles('background-image:url("http://localhost:8077/ext-3.3.0/resources/images/search.gif")';
 }

 

This same code if i placed directly in the CSS file it works correctly.

 

Thanks

 

Background image to Edit?!

Link to comment
Share on other sites

Background image to Edit?!

 

Yes Farshad!

 

If i set the class of the CSS file seen below, is displayed in the UniEdits components the image in the background.

 

.x-form-text, textarea.x-form-field{

background-image:url http://localhost:8077/ext-3.3.0/resources/images/search.gif;

}

 

What i'm trying is to do the same thing, but for some "UniEdits" through the ExtEvent AfterRender.

 

Thanks!

Link to comment
Share on other sites

  • 2 weeks later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...