+ Reply to Thread
Results 1 to 5 of 5

Thread: Select List with HTML content

  1. #1
    Administrator richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich's Avatar
    Join Date
    Mar 2008
    Location
    Somewhere only we know...
    Posts
    3,207
    Blog Entries
    14
    Real Name
    Rich
    Rep Power
    14

    Select List with HTML content

    Anyone know of a way of using HTML tags in dropdownlist options?

    ie, something like
    Code:
    <option value="1">A<sub>2</sub></option>
    
    The dropdown is an ASP.NET dropdownlist control and is a dependant dropdown populated by a web service when a value in another dropdown is changed.

    Couldn't find any work around solutions using overflow div or something, so may have to come up with my own. Anyone know of anything like this?

  2. #2
    Windows Guru Nilpo is on a distinguished road Nilpo's Avatar
    Join Date
    Jul 2010
    Location
    Wake Forest, NC
    Posts
    68
    Real Name
    Robert Dunham
    Rep Power
    2

    No dice. Option elements cannot have children so there's no way to put tags inside. You might consider a javascript solution. Maybe a text overlay or something.

  3. #3
    Administrator richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich's Avatar
    Join Date
    Mar 2008
    Location
    Somewhere only we know...
    Posts
    3,207
    Blog Entries
    14
    Real Name
    Rich
    Rep Power
    14

    Quote Originally Posted by Nilpo View Post
    No dice. Option elements cannot have children so there's no way to put tags inside. You might consider a javascript solution. Maybe a text overlay or something.
    Thought as much. Wasn't really vital, so can live without it..

  4. #4
    Windows Guru Nilpo is on a distinguished road Nilpo's Avatar
    Join Date
    Jul 2010
    Location
    Wake Forest, NC
    Posts
    68
    Real Name
    Robert Dunham
    Rep Power
    2

    Quote Originally Posted by richyrich View Post
    Thought as much. Wasn't really vital, so can live without it..
    It's kind of a bummer. I understand the semantics, but it was be nice if they would at lest allow inline items for text markup.

  5. #5
    Administrator richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich is a splendid one to behold richyrich's Avatar
    Join Date
    Mar 2008
    Location
    Somewhere only we know...
    Posts
    3,207
    Blog Entries
    14
    Real Name
    Rich
    Rep Power
    14

    Quote Originally Posted by Nilpo View Post
    It's kind of a bummer. I understand the semantics, but it was be nice if they would at lest allow inline items for text markup.
    I wonder if something like a dropdownextender in .NET would work.

+ Reply to Thread

Similar Threads

  1. SaveAs HTML from VB.Net Winforms
    By Mythily in forum .NET Development
    Replies: 6
    Last Post: April 30th, 2009, 11:59 AM
  2. html is it programming or website layout?
    By dtz in forum HTML & CSS Help
    Replies: 2
    Last Post: April 17th, 2009, 02:53 PM
  3. Sending HTML email...
    By bryceowen in forum PHP Development
    Replies: 3
    Last Post: April 8th, 2009, 08:28 PM
  4. Reduce HTML File Size
    By BLaaaaaaaaaarche in forum HTML & CSS Help
    Replies: 1
    Last Post: February 19th, 2009, 08:06 PM
  5. How to insert variable html into php
    By evdv in forum PHP Development
    Replies: 1
    Last Post: January 14th, 2009, 08:54 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

SEO by vBSEO