2024-02-06, 02:22 AM
(This post was last modified: 2024-02-06, 05:17 PM by meisme. Edited 5 times in total.)
Hi there,
i want to extract a part of an url.
and then want to place the extracted into some tag
but all i get in a test is
how can i ensure that the $1 is placed within the tags?
Edit:
MyBB 1.8.37
I think it is a bug.
if i use
then same result
so i think the handling in which order the replacement is processed is not "from left to right", but "anything non-$1 first and then set $1 behind that all". And that is wrong, a bug.
here some pics so maybe it is better to understand
and now the special one
yeah, you already know
whereas it is interesting that without html/bbcode it shows
so all the letters where processed too. Whereas in the example with e.g. "<strong>", the tag is not seen in the "actual result" picture
Heeeee! Hooooo! (.*) rules! The "?" destroys all. Without it all works fine
i want to extract a part of an url.
https://www.youtube.com/(.*?)
and then want to place the extracted into some tag
[jau]$1[/jau]
but all i get in a test is
Quote:[jau][/jau]watch?v=TJuWszB51Sc
how can i ensure that the $1 is placed within the tags?
Edit:
MyBB 1.8.37
I think it is a bug.
if i use
Quote:<strong>$1</strong>
then same result
Quote:<strong></strong>watch?v=TJuWszB51Sc
so i think the handling in which order the replacement is processed is not "from left to right", but "anything non-$1 first and then set $1 behind that all". And that is wrong, a bug.
here some pics so maybe it is better to understand
and now the special one
Quote:gfgfhgfhgfhgfhgfhgf $1 jhgjhgjhgjhgjhg
yeah, you already know
Quote:gfgfhgfhgfhgfhgfhgf jhgjhgjhgjhgjhgwatch?v=TJuWszB51Sc
whereas it is interesting that without html/bbcode it shows
Quote:Actual Result
The area below shows the actual result when the HTML is rendered.
gfgfhgfhgfhgfhgfhgf jhgjhgjhgjhgjhgwatch?v=TJuWszB51Sc
so all the letters where processed too. Whereas in the example with e.g. "<strong>", the tag is not seen in the "actual result" picture
Heeeee! Hooooo! (.*) rules! The "?" destroys all. Without it all works fine