How to enter tab symbol into web form? [duplicate]

Depending on your OS, open up a program like Notepad (Windows), and type a TAB. Highlight it, and copy it to the clipboard. Paste it into the text field.

As long as SuperUser doesn't edit it out (the application could if it wanted to), there is a tab character between the brackets below.

[Before Tab] [After Tab]


I just found the solution after much searching, since the ASCII# for TAB is 9, in Windows you can just press ALT+009 (with the number pad). This should work on Mac too though I'm not sure about Linux. If you have a laptop it might be easier to use the AutoHotkey scripts below.

Here are two little AutoHotkey scripts that work for me from Windows:

#TAB::
  SendInput, {Alt Down}{Numpad0}{Numpad0}{Numpad9}{Alt Up}
Return

#TAB::
  Send, {ASC 009}
Return

Here they are mapped to Windows Key+TAB but you can map it to what ever you like.

[Before TAB] [After TAB]

Oh, it seems like SuperUser.com converts all blank space characters to single spaces. Well, it works in Gmail and other website forms. Hope this helps.


The character reference for a tab would be 	 (see Wikipedia). It depends on the form and the server-side process what happens with this character, though. If character references are not resolved, it would simply display "	". If character references are resolved, it depends on how the submitted content will be displayed on the page (e.g. inside of the pre element it should be displayed by default; inside of other elements it should be converted to spaces by default; you could change that behavior with CSS, though)

Test with character reference: [before tab] [after tab] (check the HTML source)