Menu Sign In Contact FAQ
Banner
Welcome to our forums

How to put the asterisk * into posts

Normally the * creates bullet points e.g.

creates

  • hello1
  • hello2
  • hello 3

If you want to literally use the asterisk character, enclose it in two % signs e.g.

gives you

*

So now all you akademikally edukkated types kan do proper footnotes

Note that for the bullet lists there must be a space after the *

Administrator
Shoreham EGKA, United Kingdom

also * yields *

LFPT, LFPN

* is easier to remember and should give *, but doesn’t: *

Last Edited by lionel at 09 Jun 15:46
ELLX

You can find this under Posting Tips. EuroGA implements a modded version of Textile.

Before 2013 or so it used a processor called Markdown which had lots of problems.

Administrator
Shoreham EGKA, United Kingdom

My understanding is that textile allows to embed HTML, with some scrubbing / safety limits “obviously”. My understanding is that it would allow any HTML named character reference, that is everything of the form &SOMETHING; as listed in the HTML spec.

The fact that * is not accepted, but is HTML-escaped in the result is unexpected and should be considered a bug. Compare with the implementation on https://textile-lang.com/; type “*” in their “Try Textile (editable)” box, and see that the result displayed in “browser output” is “*”.

A few examples that work correctly on EuroGA:
& &
&lt; <
&le; ≤
&Agrave; À
&ntilde; ñ
&pound; £
&yen; ¥
&copy; ©
&times; ×
&euro; €
&cent; ¢
&ndash; –
&mdash; —
&para; ¶
&alpha; α

A few examples I have found that do not work on EuroGA and I would consider a bug. I see no good reason to filter named character references at all.
&semi; &semi; (should give “;”)
&ast; &ast; (should give “*”)
&dollar; &dollar; (should give “$”)
&comma; &comma; (should give “,”)
&gimel; &gimel; (should give “ℷ”)
&aleph; &aleph; (should give “ℵ”)
&commat; &commat; (should give “@”)
&num; &num; (should give “#”)

Another grating thing, is that the EuroGA accepts decimal character references, but not hexadecimal ones. E.g.: &#42; gives the correct “*”, but the equivalent:
&#x2A; gives &#x2A;
&#X2A; gives &#X2A;

All these examples work correctly on https://textile-lang.com/

I forever run into these inconsistencies, and have to go back and edit my posts to correct.

ELLX

What would be the main context in which these characters would be used?

Most of them can be typed directly on the keyboard.

Administrator
Shoreham EGKA, United Kingdom

* has special meaning in Textile in some contexts (e.g. as first character in a line) and needs to be escaped (like in this line). While I can always use the decimal character reference (&#42;), frankly remembering the number is cumbersome and typing &ast; would be easier. Yes, you have the EuroGA-specific syntax with percent symbols, but that is EuroGA specific. The well-known HTML one is easier to remember, should work everywhere… except EuroGA.

  • if I had not escaped it in the line above, it would have looked like that.

# is in exactly in the same situation. &num; is more universal, and easier to remember than the decimal numbered one, or the EuroGA-specific percent.

As such, it is frustrating that it is exactly those that are filtered out by the EuroGA modified-textile implementation! This mixed-implementation where many named character references work, but some don’t, is confusing.

Similarly, “;” has special meaning in some contexts, such as at the end of “&#42;”; if one doesn’t want it to have that special meaning, it must be escaped, and &semi; is more universal / easier to remember.

ELLX

I am sure there are historical reasons for why this was done. Maybe @david may remember…

I do recall one thing, with one of the text processors (may have been Markdown): it didn’t support newlines! Now who, living in the real world, could have thought of that? It is fine for typing some gibberish but it means you cannot paste any tabular info from elsewhere. So David modified it to support newlines.

Then there is code to convert youtube and vimeo URLs into the players.

There are issues with the order in which some of this happens e.g. pasting a URL into the forum incorrectly generates a clickable link if there are certain chars in the URL (which back then were not used in URLs but today they sometimes are). You can still use those chars if it is a live link e.g. this.

I think the main issue is due to the order in which the various things are processing the input, but there is a lot of code. I never found a Ruby dev. Well I did find one but he didn’t get very far. The donations don’t cover commercial rates; the airports site I paid for out of my pocket.

Administrator
Shoreham EGKA, United Kingdom

Actually, &ast; is not in the HTML RFC, so typing it shouldn’t necessarily give *. It works where it does because some(/most/all) browsers happen to support it.

The EuroGA implementation doesn’t filter any entities out and it uses a standard library for the textile implementation. It does do a couple of custom things, but that’s not why it’s happening.

The reason that it doesn’t work when you type &ast; is because in addition to textile, EuroGA also sanitises the HTML, to avoid any possible problems of XSS type attacks whereby people try to inject HTML into their posts. So the the ampersand (“&”) in &ast; is turned into this html: &amp;ast; by the sanitiser, not textile*.

I personally can’t see that it’s a big deal, if the only time it does it is when the asterisk is at the start of the line. If you use that because you want to add a footnote** then just don’t put a space after the asterisk.

Of course, all this could be changed by any competent programmer.

*out of interest, if you wrap it in <code> tags it will do what you want.

** and if the lack of a space offends you you can add a &nbsp; after the asterisk.

Administrator
EGTR / London, United Kingdom

&ast; is in the HTML5 spec

ELLX
11 Posts
Sign in to add your message

Back to Top