Vmod - Method: All - Turns breadcumbs to "Dashboard > Edit vMod"

Designer
Şundan Romania
Haz 2024 tarihinden beri üye

If I make a vMod in Admin for example:

  • Operation #1
  • Method: All
  • Match Type Multiline

.. and give a complete new code for the whole page that is added in the 'File Pattern' at the 'File To Modify' section

in the FRONT, on the website the breadcumbs turns into "Dashboard > Edit vMod"

is this a bug or am I missing something?

see attached images

LiteCart Fan
Şundan Netherlands
Ara 2022 tarihinden beri üye

can you show the whole code you insert?

Designer
Şundan Romania
Haz 2024 tarihinden beri üye

ok I digged and what Ive found

Iff I add these codes to the INSERT textarea:
{snippet:breadcrumbs}
{snippet:notices}

...after I save the Vmod in admin it automatically turns the above lines into this:

            <ul class="breadcrumb">

<li><a href="/admin/">Dashboard</a></li><li>Edit vMod</li></ul>

Designer
Şundan Romania
Haz 2024 tarihinden beri üye

the only solution I found is this and it seems it works:

<?php
$snippet_notices = base64_decode('e3NuaXBwZXQ6bm90aWNlc30=');
$snippet_breadcrumbs = base64_decode('e3NuaXBwZXQ6YnJlYWRjcnVtYnN9');
?>

<?php echo $snippet_breadcrumbs; ?>
<?php echo $snippet_notices; ?>

tim
Founder
Şundan Sweden
May 2013 tarihinden beri üye
tim

There is a problem using the backend editor to tamper with snippet placeholders as they are being resolved. I'm thinking if something like <?php echo implode('', ['{', 'snippet:breadcrumbs', '}']); ?> or <?php echo '{'.'snippet:breadcrumbs'.'}'; ?> would work too?

Designer
Şundan Romania
Haz 2024 tarihinden beri üye

Yes, just tested it and I can confirm

<?php echo implode('', ['{', 'snippet:breadcrumbs', '}']); ?> 

also works. Thank you

Siz
This website uses no cookies and no third party tracking technology. We think we can do better than others and really think about your privacy.