GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing stackoverflow.com — Markdown Editing Help Collectives™ on Stack OverflowFind centralized, trusted content and collaborate around the technologies you use most. Learn more about CollectivesMarkdown helpCode and Preformatted Text
Indent four spaces to create an escaped printf("%d\n", 42); /* what was the question again? */ You can also select text and press CTRL+K to toggle indenting as code. The text will be wrapped in tags, and displayed in a monospaced font. The first four spaces will be stripped off, but all other whitespace will be preserved. Markdown and HTML are ignored within a code block: <blink> You would hate this if it weren't wrapped in a code block. </blink> Instead of using indentation, you can also create code blocks by using “code fences”, consisting of three or more backticks or tildes: ``` alert(false); ``` ~~~ alert(true); ~~~ Code Spans
Use backticks to create an inline The `$` character is just a shortcut for `window.jQuery`. (The backtick key is in the upper left corner of most keyboards.) Like code blocks, code spans will be displayed in a monospaced font. Markdown and HTML will not work within them. Note that, unlike code blocks, code spans require you to manually escape any HTML within! If your code itself contains backticks, you may have to use multiple backticks as delimiters: The name ``Tuple`2`` is a valid .NET type name. Linebreaks
End a line with two spaces to add a How do I love thee?
Let me count the ways
Italics and Bold*This is italicized*, and so is _this_. **This is bold**, and so is __this__. Use ***italics and bold together*** if you ___have to___. You can also select text and press CTRL+I or CTRL+B to toggle italics or bold respectively. LinksBasic LinksThere are three ways to write links. Each is easier to read than the last: Here's an inline link to [Google](https://www.google.com/). Here's a reference-style link to [Google][1]. Here's a very readable link to [Yahoo!][yahoo]. [1]: https://www.google.com/ [yahoo]: https://www.yahoo.com/ You can also select text and press CTRL+L to make it a link, or press CTRL+L with no text selected to insert a link at the current position.
The link definitions can appear anywhere in the document -- before or after the
place where you use them. The link definition names Advanced LinksLinks can have a title attribute, which will show up on hover. Title attributes can also be added; they are helpful if the link itself is not descriptive enough to tell users where they're going. Here's a <span class="bg-black-300">[poorly-named link](https://www.google.com/ "Google")</span>. Never write "[click here][^2]". Visit [us][web]. [^2]: https://www.w3.org/QA/Tips/noClickHere (Advice against the phrase "click here") [web]: https://stackoverflow.com/ "Stack Overflow" You can also use standard HTML hyperlink syntax. <a href="https://example.com" title="example">example</a> Bare URLsWe have modified our Markdown parser to support "naked" URLs (in most but not all cases -- beware of unusual characters in your URLs); they will be converted to links automatically: I often visit https://example.com. Force URLs by enclosing them in angle brackets: Have you seen <https://example.com>? URLs can be relative or full. HeadersUnderline text to make the two <h1> <h2> top-level headers : Header 1 ======== Header 2 -------- You can also select text and press CTRL+H to step through the different heading styles. The number of = or - signs doesn't matter; one will work. But using enough to underline the text makes your titles look better in plain text. Use hash marks for several levels of headers: # Header 1 # ## Header 2 ## ### Header 3 ### The closing # characters are optional. Horizontal RulesInsert a horizontal rule <hr/> by putting three or more hyphens, asterisks, or underscores on a line by themselves: ---
You can also press CTRL+R to insert a horizontal rule. Rule #1 --- Rule #2 ******* Rule #3 ___ Using spaces between the characters also works: Rule #4
- - - -
You can also press CTRL+R to insert a horizontal rule. Simple lists
A bulleted - Use a minus sign for a bullet + Or plus sign * Or an asterisk
A numbered 1. Numbered lists are easy 2. Markdown keeps track of the numbers for you 7. So this will be item 3. You can also select text and press CTRL+U or CTRL+O to toggle a bullet or numbered list respectively. A double-spaced list: - This list gets wrapped in <p> tags - So there will be extra space between items Advanced lists: NestingTo put other Markdown blocks in a list, just indent four spaces for each nesting level: 1. Lists in a list item: - Indented four spaces. * indented eight spaces. - Four spaces again. 1. Lists in a list item: - Indented four spaces. * indented eight spaces. - Four spaces again. 2. Multiple paragraphs in a list items: It's best to indent the paragraphs four spaces You can get away with three, but it can get confusing when you nest other things. Stick to four. We indented the first line an extra space to align it with these paragraphs. In real use, we might do that to the entire list so that all items line up. This paragraph is still part of the list item, but it looks messy to humans. So it's a good idea to wrap your nested paragraphs manually, as we did with the first two. 3. Blockquotes in a list item: > Skip a line and > indent the >'s four spaces. 4. Preformatted text in a list item: Skip a line and indent eight spaces. That's four spaces for the list and four to trigger the code block. Simple blockquotes
Add a > The syntax is based on the way email programs > usually do quotations. You don't need to hard-wrap > the paragraphs in your blockquotes, but it looks much nicer if you do. Depends how lazy you feel. You can also select text and press CTRL+Q to toggle a blockquote. Advanced blockquotes: Nesting
To put other Markdown blocks in a blockquote, just add a
To put other Markdown blocks in a blockquote, just add a > The `>` on the blank lines is required > to create a single blockquote. > > If you leave out the extra `>` > you will end up with > two distinct blockquotes. Blockquotes within a blockquote: > A standard blockquote is indented > > A nested blockquote is indented more > > > > You can nest to any depth. Lists in a blockquote: > - A list in a blockquote > - With a > and space in front of it > * A sublist Preformatted text in a blockquote: > Indent five spaces total. The first > one is part of the blockquote designator. ImagesImages are exactly like links, but they have an exclamation point in front of them: .
You can also press CTRL+G to insert an image. The word in square brackets is the alt text, which gets displayed if the browser can't show the image. Be sure to include meaningful alt text for screen-reading software. Just like links, images work with reference syntax and titles: This page is ![valid XHTML][checkmark]. [checkmark]: https://w3.org/Icons/valid-xhtml10 "What are you smiling at?" Note: Markdown does not currently support the shortest reference syntax for images: Here's a broken ![checkmark].
But you can use a slightly more verbose version of implicit reference names: This ![checkmark][] works. The reference name is also used as the alt text. You can also use standard HTML image syntax, which allows you to scale the width and height of the image. <img src="https://example.com/sample.png" width="100" height="100"> URLs can be relative or full. Inline HTMLIf you need to do something that Markdown can't handle, use HTML. Note that we only support a very strict subset of HTML! To reboot your computer, press <kbd>ctrl</kbd>+<kbd>alt</kbd>+<kbd>del</kbd>. Markdown is smart enough not to mangle your span-level HTML: <b>Markdown works *fine* in here.</b> Block-level HTML elements have a few restrictions:
<pre> You can <em>not</em> use Markdown in here. </pre> Need More Detail?Visit the official CommonMark specification. Stack Exchange additionsThe following sections describe some additional features for text formatting that aren't officially part of CommonMark. TagsTo talk about a tag on this site, like-this, use See the many questions tagged [tag:elephants] to learn more.
The tag will automatically be linked to the corresponding tag page. SpoilersTo hide a certain piece of text and have it only be visible when a user clicks it, use the blockquote syntax with an additional exclamation point: At the end of episode five, it turns out that >! he's actually his father. Syntax highlighting for codeCode blocks can be highlighted using highlight.js. In many cases, the syntax highlighting language will be inferred from the question's tags. To manually specify the language of a fenced code block, add the language to the line with the opening fence: ``` lang-js
setTimeout(function () { alert("JavaScript"); }, 1000);
```
You can use either one of the supported language codes,
like To specify a syntax highlighting language to be used not only for the next, but for all following code blocks, use: <!-- language-all: lang-html -->
To specify that you don't want any syntax highlighting for a code block, use: <!-- language: lang-none -->
TablesOur support for tables is based on the GitHub-flavored markdown table extension specification. | A header | Another header | | -------- | -------------- | | First | row | | Second | row | AlignmentYou can set the alignment of a table column by including a | left | center | right | |:---- |:------:| -----:| | One | Two | Three | Syntax details
Comment formattingComments support only bold, italic, code and links; in addition, a few shorthand links are available.
_italic_ and **bold** text, inline `code in backticks`, and [basic links](https://example.com). Supported shorthand links:
Replying in comments
The owner of the post you're commenting on will always be notified of your comment. If you are replying to someone else who has previously commented on the same post,
mention their display name:
It is generally sufficient to mention only the first name of the user whose comment you are replying to, e.g.
If the user you're replying to has no natural first name and last name, simply enter enough characters of the name to make it clear who you are responding to.
Three is the minimum, so if you're replying to Fantastico, enter You can use the same method to notify any editor of the post, or – if this is the case – to the ♦ moderator who closed the question. |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |