Underline just the S in the Submit Button?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Scott Townsend

    Underline just the S in the Submit Button?

    I have a form that I allow the user to use the ALT-S key to submit.

    I'd like to have just the S in the Submit button underlined, Is this
    possible?

    Thanks,
    Scott<-


  • Aaron Bertrand - MVP

    #2
    Re: Underline just the S in the Submit Button?

    Why is this an ASP question? ASP doesn't know what a button is.

    <button><u>S</u>ubmit</button>

    Please post future client-side questions to an HTML newsgroup...

    --
    Aaron Bertrand
    SQL Server MVP





    "Scott Townsend" <scott-i@.-N0-SPAMplease.enm. com> wrote in message
    news:OWKu1tcPEH A.644@tk2msftng p13.phx.gbl...[color=blue]
    > I have a form that I allow the user to use the ALT-S key to submit.
    >
    > I'd like to have just the S in the Submit button underlined, Is this
    > possible?
    >
    > Thanks,
    > Scott<-
    >
    >[/color]


    Comment

    • Bob Barrows [MVP]

      #3
      Re: Underline just the S in the Submit Button?

      Scott Townsend wrote:[color=blue]
      > I have a form that I allow the user to use the ALT-S key to submit.
      >
      > I'd like to have just the S in the Submit button underlined, Is this
      > possible?
      >
      > Thanks,
      > Scott<-[/color]

      I do not think this is possible. The text shown on a submit button is set in
      the value attribute which can contain only characters (no style properties
      ....).

      You could create an image and use the IMG tag as your Submit button ...

      This is more of an HTML issue than as ASP issue so you may wish to ask on a
      more HTML-focussed newsgroup.

      HTH,
      Bob Barrows

      --
      Microsoft MVP -- ASP/ASP.NET
      Please reply to the newsgroup. The email account listed in my From
      header is my spam trap, so I don't check it very often. You will get a
      quicker response by posting to the newsgroup.


      Comment

      • Scott Townsend

        #4
        Re: Underline just the S in the Submit Button?

        Thanks for the Tip.

        "Aaron Bertrand - MVP" <aaron@TRASHasp faq.com> wrote in message
        news:evWRd1cPEH A.272@TK2MSFTNG P12.phx.gbl...[color=blue]
        > Why is this an ASP question? ASP doesn't know what a button is.
        >
        > <button><u>S</u>ubmit</button>
        >
        > Please post future client-side questions to an HTML newsgroup...
        >
        > --
        > Aaron Bertrand
        > SQL Server MVP
        > http://www.aspfaq.com/
        >
        >
        >
        >
        > "Scott Townsend" <scott-i@.-N0-SPAMplease.enm. com> wrote in message
        > news:OWKu1tcPEH A.644@tk2msftng p13.phx.gbl...[color=green]
        > > I have a form that I allow the user to use the ALT-S key to submit.
        > >
        > > I'd like to have just the S in the Submit button underlined, Is this
        > > possible?
        > >
        > > Thanks,
        > > Scott<-
        > >
        > >[/color]
        >
        >[/color]


        Comment

        • Dave Anderson

          #5
          Re: Underline just the S in the Submit Button?

          Aaron Bertrand - MVP wrote:[color=blue]
          > Why is this an ASP question? ASP doesn't know what a button is.
          >
          > <button><u>S</u>ubmit</button>[/color]

          <U> is deprecated:



          Fortunately, the same can be accomplished with styles. One example:

          BUTTON DIV:first-letter { text-decoration:unde rline }
          -- and --
          <BUTTON><DIV>Su bmit</DIV></BUTTON>



          --
          Dave Anderson

          Unsolicited commercial email will be read at a cost of $500 per message. Use
          of this email address implies consent to these terms. Please do not contact
          me directly or ask me to contact you directly for assistance. If your
          question is worth asking, it's worth posting.


          Comment

          • Aaron Bertrand - MVP

            #6
            Re: Underline just the S in the Submit Button?

            > <U> is deprecated:

            Oh come on now. Let's leave the HTML discussions to a more appropriate
            forum. Next we'll be talking about how <button> isn't supported in Netscape
            3.0.

            --
            Aaron Bertrand
            SQL Server MVP



            Comment

            • Bob Barrows [MVP]

              #7
              Re: Underline just the S in the Submit Button?

              Aaron Bertrand - MVP wrote:[color=blue][color=green]
              >> <U> is deprecated:[/color]
              >
              > Oh come on now. Let's leave the HTML discussions to a more
              > appropriate forum. Next we'll be talking about how <button> isn't
              > supported in Netscape
              > 3.0.[/color]

              :)
              I wasn't even aware there WAS a <button> element. I assumed the OP was
              asking about an <input> tag whose type was "submit".

              Bob Barrows
              --
              Microsoft MVP -- ASP/ASP.NET
              Please reply to the newsgroup. The email account listed in my From
              header is my spam trap, so I don't check it very often. You will get a
              quicker response by posting to the newsgroup.


              Comment

              • Ray at

                #8
                Re: Underline just the S in the Submit Button?


                "Dave Anderson" <GTSPXOESSGOQ@s pammotel.com> wrote in message
                news:uwb7%23ydP EHA.3016@tk2msf tngp13.phx.gbl. ..[color=blue]
                >
                > Fortunately, the same can be accomplished with styles. One example:
                >
                > BUTTON DIV:first-letter { text-decoration:unde rline }
                > -- and --
                > <BUTTON><DIV>Su bmit</DIV></BUTTON>[/color]

                Isn't that :first-letter pseudo class only supported by Opera or something?

                Ray at work


                Comment

                • Aaron Bertrand - MVP

                  #9
                  Re: Underline just the S in the Submit Button?

                  You can hook any event to a <button>, a form submit, an alert();, a function
                  pickMyNose();, etc.

                  But let's stay on topic! "<u> is deprecated." I oughta... let me know when
                  you come across a browser that stops supporting the <u> tag.

                  --
                  Aaron Bertrand
                  SQL Server MVP


                  [color=blue]
                  > I wasn't even aware there WAS a <button> element. I assumed the OP was
                  > asking about an <input> tag whose type was "submit".[/color]


                  Comment

                  • Dave Anderson

                    #10
                    Re: Underline just the S in the Submit Button?

                    Aaron Bertrand - MVP wrote:[color=blue][color=green]
                    >> <U> is deprecated:[/color]
                    >
                    > Oh come on now. Let's leave the HTML discussions to a more
                    > appropriate forum. Next we'll be talking about how <button> isn't
                    > supported in Netscape
                    > 3.0.[/color]

                    Please.

                    Keeping an eye to the future is far different from bending over backward to
                    work in the past. Nobody uses Netscape 3 anymore, but all of us will use
                    future browsers. And deprecating <U> has been on the table for seven years:




                    --
                    Dave Anderson

                    Unsolicited commercial email will be read at a cost of $500 per message. Use
                    of this email address implies consent to these terms. Please do not contact
                    me directly or ask me to contact you directly for assistance. If your
                    question is worth asking, it's worth posting.


                    Comment

                    • Dave Anderson

                      #11
                      Re: Underline just the S in the Submit Button?

                      Ray at <%=sLocation% > [MVP] wrote:[color=blue]
                      >
                      > Isn't that :first-letter pseudo class only supported by Opera or
                      > something?[/color]

                      No, and that would be irresponsible:


                      IE6, Opera 7, and FireFox 0.8 all dig it. Oddly enough, they all /seem/ to
                      follow the standard for the pseudo-element. I half expected IE to allow it
                      on BUTTON, but IE seems to correctly restrict it to block-level elements.



                      --
                      Dave Anderson

                      Unsolicited commercial email will be read at a cost of $500 per message. Use
                      of this email address implies consent to these terms. Please do not contact
                      me directly or ask me to contact you directly for assistance. If your
                      question is worth asking, it's worth posting.


                      Comment

                      • Aaron Bertrand - MVP

                        #12
                        Re: Underline just the S in the Submit Button?

                        > follow the standard for the pseudo-element. I half expected IE to allow it[color=blue]
                        > on BUTTON, but IE seems to correctly restrict it to block-level elements.[/color]

                        So your solution doesn't work for IE? ;-)


                        Comment

                        • Dave Anderson

                          #13
                          Re: Underline just the S in the Submit Button?

                          Aaron Bertrand - MVP wrote:[color=blue]
                          >
                          > ...let me know when you come across a browser that stops
                          > supporting the <u> tag.[/color]

                          I know of plenty, if one of these is present:

                          <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
                          "http://www.w3.org/TR/html4/strict.dtd">


                          <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
                          "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">



                          --
                          Dave Anderson

                          Unsolicited commercial email will be read at a cost of $500 per message. Use
                          of this email address implies consent to these terms. Please do not contact
                          me directly or ask me to contact you directly for assistance. If your
                          question is worth asking, it's worth posting.


                          Comment

                          • Aaron Bertrand - MVP

                            #14
                            Re: Underline just the S in the Submit Button?

                            Come on Dave, is this an ASP forum or not?

                            <bored of HTML crap>

                            --
                            Aaron Bertrand
                            SQL Server MVP





                            "Dave Anderson" <GTSPXOESSGOQ@s pammotel.com> wrote in message
                            news:#tWfVRePEH A.1048@tk2msftn gp13.phx.gbl...[color=blue]
                            > Aaron Bertrand - MVP wrote:[color=green]
                            > >
                            > > ...let me know when you come across a browser that stops
                            > > supporting the <u> tag.[/color]
                            >
                            > I know of plenty, if one of these is present:
                            >
                            > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
                            > "http://www.w3.org/TR/html4/strict.dtd">
                            >
                            >
                            > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
                            > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
                            >
                            >
                            >
                            > --
                            > Dave Anderson
                            >
                            > Unsolicited commercial email will be read at a cost of $500 per message.[/color]
                            Use[color=blue]
                            > of this email address implies consent to these terms. Please do not[/color]
                            contact[color=blue]
                            > me directly or ask me to contact you directly for assistance. If your
                            > question is worth asking, it's worth posting.
                            >
                            >[/color]


                            Comment

                            • Dave Anderson

                              #15
                              Re: Underline just the S in the Submit Button?

                              Aaron Bertrand - MVP wrote:[color=blue][color=green]
                              >> follow the standard for the pseudo-element. I half expected IE to
                              >> allow it on BUTTON, but IE seems to correctly restrict it to
                              >> block-level elements.[/color]
                              >
                              > So your solution doesn't work for IE? ;-)[/color]

                              On the contrary. I never give solutions that don't work in IE, Mozilla AND
                              Opera -- at least not when there is a cross-browser solution or when I'm
                              qualifying it as such.

                              And my base standard isn't very high -- pretty much anything that will work
                              in IE 5 or Mozilla 1. That encompasses most of HTML4, CSS1, and DOM Level 1,
                              plus good chunks of DOM2/CSS2.

                              I should confess that I consider using deprecated elements no great sin.
                              Even if my browser doesn't see the underlined first letter, I am essentially
                              unaffected.



                              --
                              Dave Anderson

                              Unsolicited commercial email will be read at a cost of $500 per message. Use
                              of this email address implies consent to these terms. Please do not contact
                              me directly or ask me to contact you directly for assistance. If your
                              question is worth asking, it's worth posting.


                              Comment

                              Working...