Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

select list - set background color for each item?

Steve.1234555-OracleSep 8 2016 — edited Oct 13 2016

I was looking for a way to set background color on select list items and came across this article:

Add colors or images to your select list | Inside Oracle APEX by Patrick Wolf

I've tried the solution suggested (adding script functions to Post Element Text) but it's not working for me.  I've also come across postings where it says it's up to the OS to determine how select list items are rendered.

Can someone clarify?  Is the article outdated for APEX 5.x or is it just dependent on the OS?  Or perhaps there's another way?

Steve

P.S. here's the code I added to my select list item:

<script type="text/javascript">

$x("P1_TMP_LIST")[2].style.backgroundColor = "yellow";

$x("P1_TMP_LIST")[3].style.backgroundColor = "red";

</script>

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 10 2016
Added on Sep 8 2016
8 comments
5,808 views