Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Does the `pymoptions=""` attribute actually support backslashes?

Aperta
#26 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@jeffersonrabb ci sta già lavorando.

Dal 21/9/2020.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

status: needs tests type: bug

We have this example in readme.txt:

[pym src="child.html" pymoptions=" xdomain: '\\*\.npr\.org' "]

Which is supposed to output: (with supporting code)

pym.Parent('pym_0', 'child.html', { xdomain: '*\.npr\.org' });

But what it actually puts on the page is this:

pym.Parent('pym_0', 'child.html', { xdomain: '\*.npr.org' })

Inside, the $pymoptions variable is this:

error_log( var_export( $pymoptions, true ) );
' xdomain: \'\\*.npr.org\' '

If we esc_js() that, it's this, still not what we're looking for:

' xdomain: \\\'*.npr.org\\\' '

In conclusion: slashes aren't being output correctly.

Lingua principale
PHP
Stelle
15
Fork
8
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Automattic/pym-shortcode

Tutte le issue di Automattic/pym-shortcode

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.