Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTML Entity for DASH

Tags:

html

entity

Putting two dashes on a page sometimes, like this -- in rare occassions messes the HTML up.

For instance, if you enter -- into your Wordpress blog it'll actually munch it into a single -. This doesn't work well for code that requires --options --to --be --specified --this --way.

The HTML entity for – is &ndash and the longer — is — but what is the HTML entity to enter NORMAL DASH - in a page?

like image 314
bobobobo Avatar asked Feb 10 '10 00:02

bobobobo


2 Answers

This should do it. It's not listed as a dash, you need to find a place that lists it as the minus sign.

Code block shows code:

-

In use: - (-)
Double: -- (--)

EDIT: My source for this answer.

like image 129
McAden Avatar answered Nov 03 '22 07:11

McAden


This tool makes it easy to find (instead of looking through a chart): http://amp-what.com/#q=dash

like image 35
ndp Avatar answered Nov 03 '22 07:11

ndp