[GH-ISSUE #1114] using these in options on a select #525

Closed
opened 2026-03-03 14:39:00 +03:00 by kerem · 1 comment
Owner

Originally created by @Offbeatmammal on GitHub (Jul 24, 2023).
Original GitHub issue: https://github.com/lipis/flag-icons/issues/1114

has anyone worked out a way (plain html/css, jQuery, or Bootstrap) to use these in a select so I could have (for instance) each line of the dropdown containing the flag followed by the country name?

for now I'm using a modified version of the custom select code from https://www.w3schools.com/howto/howto_custom_select.asp but wondered if there was a cleaner/more elegant way to achieve this

Originally created by @Offbeatmammal on GitHub (Jul 24, 2023). Original GitHub issue: https://github.com/lipis/flag-icons/issues/1114 has anyone worked out a way (plain html/css, jQuery, or Bootstrap) to use these in a select so I could have (for instance) each line of the dropdown containing the flag followed by the country name? for now I'm using a modified version of the custom select code from https://www.w3schools.com/howto/howto_custom_select.asp but wondered if there was a cleaner/more elegant way to achieve this
kerem closed this issue 2026-03-03 14:39:01 +03:00
Author
Owner

@lipis commented on GitHub (Jul 25, 2023):

You can't add images to select your best option for that is to use Emoji flags, otherwise you need to have your own component handling the images

<!-- gh-comment-id:1649603543 --> @lipis commented on GitHub (Jul 25, 2023): You can't add images to `select` your best option for that is to use Emoji flags, otherwise you need to have your own component handling the images
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/flag-icons#525
No description provided.