I am discovering the joys of Gutenberg and blocks with Toolset. 🙂
I have some fields where weird code gets injected somehow. For example, I have a "TB Fields and Text" block in use with the following code:
<h2><a class="whatever" role="button" href="#collapsehomeaddess" data-toggle="collapse" aria-expanded="false" aria-controls="collapsehomeaddess">Home Address <i class="fas fa-caret-down"></i></a></h2>
<div id="collapsehomeaddess" class="collapse">
<div class="card card-body">[types field='home-address-1'][/types]<br>[types field='home-address-2'][/types]<br>[types field='home-city'][/types], [types field='home-state'][/types]<br>[types field='home-zip'][/types] <br><br>
<p>Father/Guardian: [types field='father-guardian'][/types]</p>
<p>Mother/Guardian: [types field='mother-guardian'][/types]</p>
<p>Home Phone: <a href="tel: [types field='home-phone'][/types]"[types field='home-phone'][/types]</a></p>
</div>
</div>
And that works for a while, until suddenly it gets injected with code and becomes this:
<h2><a class="whatever" role="button" href="#collapsehomeaddess" data-toggle="collapse" aria-expanded="false" aria-controls="collapsehomeaddess">Home Address <i class="fas fa-caret-down"></i></a></h2>
<div id="collapsehomeaddess" class="collapse">
<div class="card card-body">[types field='home-address-1'][/types]<br>[types field='home-address-2'][/types]<br>[types field='home-city'][/types], [types field='home-state'][/types]<br>[types field='home-zip'][/types] <br><br>
<p>Father/Guardian: [types field='father-guardian'][/types]</p>
<p>Mother/Guardian: [types field='mother-guardian'][/types]</p>
<p>Home Phone: <a class="tb-fields-and-text-shortcode-render tb-fields-and-text-shortcode-render-types" href="tel:<span id=" data-tb-shortcode-id="644"><!-- TBINNERSTART 644 -->Loading...<!-- TBINNEREND 644 -->">[types field='home-phone'][/types]</a></p>
</div>
</div>
Is this familiar to you?
I wish the code in the toolset block's HTML view could look as nice as it does in my previous post above this.
Hi, check your syntax here:
<p>Home Phone: <a href="tel: [types field='home-phone'][/types]"[types field='home-phone'][/types]</a></p>
I see that the opening "a" tag doesn't include a closing angle bracket. However, even after changing that, if I switch between Visual and HTML mode I am able to reproduce the extra code issue. Let me ask my 2nd tier team if this is a known issue. Please stand by and I'll let you know what I find out.
Hi Christian,
It was late when I sent in the ticket and I just quickly corrected the bugged up one to show the Before. Sorry. 😉
I'm glad you're on it, this is very problematic.
I also get these.. hidden link
Yes, thanks I see similar corruption of the block on the editor and the front-end sides. I have escalated this to our developers, who will fix it in an upcoming release of the Toolset Blocks plugin. Thanks for the report!
Do you have any hints as to when this might be?
I don't know yet, but I will be glad to keep you updated through this post as I receive more information.
Hi, our Blocks developers have indicated this issue should be resolved in the latest release of Blocks.