ASCII Code for the TAB Character? (Want to be able to input tabs into a web page textbox)

asciicharacter encodingcharactersinputwebsite

As I'm sure that pretty much everyone on here is aware the "Tab" key when used on a webpage simply jumps to the next element on the page; whether is be a checkbox, radio selector, button, another textbox, a link, etc.

What I am hoping to do is enable me to use the tab key whlie I typing something up in an input form and actually have it insert the tab character into the form I'm filling out. I'm pretty anal retentive when it comes to how my text documents are formatted, ESPECIALLY when it comes to writing articles for my site. Hell, I'm even anal about how my "to-do" lists look when I type them up in good old fashioned Notepad. (Yep, I use good old-fashioned Notepad to write up my article ideas, to-do lists, save little snippets of useful code that I find, etc.)

I realize that there are javascript solutions or properties you can set for that particular textbox – depending on what language you happen to be programming the site in – that you can use to manually program the input fields on your webpage to allow this; but I am more interested in allowing the web browser to behave in its normal fashion (as I do use the tab key to switch between page elements – also especially when filling out long applications and forms in order to navigate between them far more quickly than having to use my mouse to click on each field that I want to fill out.

So, what I'm hoping to find is the Windows ASCII key combo (like using ALT+0169 in order to produce the © character) that I can enter in order to insert the tab into the webpage textbox that way. As I use ASCII key combos routinely to make weird-ass symbols in my write-ups all the time I am quite used to doing things this way. Besides, once done typing up something in a textbox I'd still like to have the ability to tab over to the next element. When programming forms myself for whatever project I happen to be working on I always go out of my way to order the elements in such a way that tabbing through them is as intuative as possible. Who knows how many of you are like me, but I am always bothered when I'm filling out a set of address fields and when you cycle though them they jump around randomly based on whatever order the programmer of that page created them in.

EXAMPLE: You're typing in your name in the first field on a page that has a form that hasn't been properly setup I am always annoyed when I, press tab, and then it suddenly jumps to the City name, followed by the address line 2, then to the zipcode, etc. You get the idea. As far as I know everyone likes to input that information in the order in which you'd hand write an address on an envelope. Name first, followed by address lines one and two, then the city, state, zip, and finally (if neccessary) the country assuming that it's required.

Now that I've explained what I'm trying to do ad nauseum, what is the ASCII key code for Tab?

Best Answer

Didn't read most of you post, sorry.

But just fixing on the final little question what is the ASCII key code for Tab?
ASCII value for tab is 9 (decimal or hex), so try Alt + ( Numpad 0 , Numpad 9).

But, I've just tested doing so in this very edit box and it doesn't work, but it does in notepad, MS Word, etc. I wonder why...?

Anyway, if you really need a tab somewhere odd, try copying one from notepad and pasting it where you need it - that's what I tend to do.

Edit

If you're doing this for it to be displayed on a website (which is what I think you're implying), a tab character may be ignored because HTML tends to ignore whitespace (outside of pre blocks, etc).

If it is HTML you could also use the HTML entity version 	 as well, but this will function in the same way.

Related Question