Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2019-05-13 08:36:21

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,295
Website

notextile

The <notextile /> tag does not work when there is no space before or after it. Is this expected behaviour?

Sample code

p. something here<notextile><txp::note no="1" txt="footnote here." pos="top" /></notextile>

this works

p. something here <notextile><txp::note no="1" txt="footnote here." pos="top" /></notextile>

The reason I would like the first to work is because it prevents the footnote number from moving to a new line.


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#2 2019-05-13 10:06:16

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 3,488
Website

Re: notextile

Hmm, I thought you should be able to do that by putting square brackets around it, e.g.

something here[^2^].

produces something here2.

But neither:

something here[<notextile> … </notextile>]

nor

something here[== … ==]

seem to work :-/


TXP Builders – finely-crafted code, design and txp

Offline

#3 2019-05-13 13:44:19

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,295
Website

Re: notextile

Hmmm. Although it includes the actual square brackets, after parsing, it does work. Is there a way not to have the square brackets shown?


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#4 2019-05-13 14:51:56

etc
Developer
Registered: 2010-11-11
Posts: 3,203
Website

Re: notextile

Hi guys,

Looking at the code, <notextile> or == must be preceded by a space, >, [, ( or { to be detected. In all cases, the preceding character is preserved. It can eventually be converted on further processing, but not in your “footnote” case. If you need to make it invisible, try

something here<!---->== … ==

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.


etc_[ query | search | pagination | date | tree | cache ]

Offline

#5 2019-05-13 15:05:54

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,295
Website

Re: notextile

etc wrote #317977:

Hi guys,

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.

It is more of an aesthetic problem rather than a functional one. I am trying to avoid the rare occurrences where the footnotes are pushed to the next line.


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#6 2019-05-13 23:05:13

phiw13
Plugin Author
From: Japan
Registered: 2004-02-27
Posts: 1,680
Website

Re: notextile

colak wrote #317978:

It is more of an aesthetic problem rather than a functional one. I am trying to avoid the rare occurrences where the footnotes are pushed to the next line.

A non-breaking (&160;) space before the footnote node? (that would work unless the footnote node is set to display:inline-block or some such).

Offline

#7 2019-05-14 05:00:48

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,295
Website

Re: notextile

phiw13 wrote #317982:

A non-breaking (&160;) space before the footnote node? (that would work unless the footnote node is set to display:inline-block or some such).

Hi Philippe,

No, that would not work because the notextile tags would not be recognised. :(


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#8 2019-06-08 09:02:57

Gocom
Plugin Author
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,532
Website

Re: notextile

etc wrote #317977:

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.

The bracket code is only supported for links.

It also works for spans, soft of, but due to buggy non-functional conditional:

if (($m['pre'] && !$m['tail']) || ($m['tail'] && !$m['pre'])) {
      $out = $m['pre'].$out.$m['tail'];
}

Which results other strange stuff it is not supposed be doing. It’s a feature due to a bug, so to speak.

Last edited by Gocom (2019-06-08 09:03:06)

Offline

#9 2019-06-08 11:15:32

Gocom
Plugin Author
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,532
Website

Re: notextile

Now the square bracket wrapping can be used for span tags and the special inline escaping syntaxes such as ==; now an actually intended feature extending the bracket syntax from links to other span tags, and not a result of a bug.

See span-wrappers fixture for syntax examples and what you should expect and what not.

Last edited by Gocom (2019-06-08 11:16:11)

Offline

#10 2019-06-08 16:42:37

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,295
Website

Re: notextile

Gocom wrote #318410:

Now the square bracket wrapping can be used for span tags and the special inline escaping syntaxes such as ==; now an actually intended feature extending the bracket syntax from links to other span tags, and not a result of a bug.

See span-wrappers fixture for syntax examples and what you should expect and what not.

yummy!!!!


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

Board footer

Powered by FluxBB