Mike6580064
Posts: 0
Joined: Wed Jan 15, 2014 6:00 pm

Add a label to list item, changes list to white. How to fix?

It does. However, it permanently changes the label text to red. The CSS is working, I don't believe the JS is.

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

Add a label to list item, changes list to white. How to fix?

Hi Mike.

Please follow these steps to make list-item text with "#f00" color when user clicked on it:

1 Open your page with list.

2 Activate list item http://prntscr.com/3lel5j/direct.

3 Open bottom "EVENTS" panel.

4 Add "click" JS event handler on your active list item. http://prntscr.com/3leltc/direct

5 JS editor will appear. Populate it with following code:

precode

var listItemText = jQuery(this).find("*");

//Note you have to change "#f00" with color you need.
listItemText.css("color", "#f00");

/code/pre

That's all.

Regards.

Return to “Issues”