Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Custom template Cannot read property 'substring' of undefined

First of all: I am writing for a Pro user, since my English is better then his (please, no jokes :) ). We are trying to create a custom template for our player. Using the template "in progress" version we started receiving the error: "Custom template Cannot read property 'substring' of undefined". We tried every possibility, the last one was to create an empty module (for empty I mean: no character sheet at all) We wrote in the HTML some examples like the ones in the wiki ( <a href="https://wiki.roll20.net/Roll_Templates#Creating_a_Roll_Template" rel="nofollow">https://wiki.roll20.net/Roll_Templates#Creating_a_Roll_Template</a> ) Same error. We create an empty template, only HTML: &lt;rolltemplate class="sheet-rolltemplate-test"&gt; &nbsp; &nbsp; &lt;div&gt; &nbsp; &nbsp;Test &nbsp; &nbsp; &lt;/div&gt; &lt;/rolltemplate&gt; Same error. I suppose we are missing something really stupid, but we have no clues. Does anybody have an idea on what we are doing wrong? Thank you
1586699826

Edited 1586699951
GiGs
Pro
Sheet Author
API Scripter
What are you typing in chat to test this template? Typing this in text with the above prints out "Test" into chat for me &amp;{template:test}
1586700151

Edited 1586700353
Yes, it is what we did. We tryed including some "inputs" like {{title}} &lt;rolltemplate class="sheet-rolltemplate-test"&gt; &nbsp; &nbsp; &lt;div&gt; &nbsp; &nbsp;{{title}} &nbsp; &nbsp; &lt;/div&gt; &lt;/rolltemplate&gt; and executing as: &amp;{template:test}{{title=TEST}} with the same error.
1586700345
GiGs
Pro
Sheet Author
API Scripter
If they aren't working for you, you have another problem, because the syntax there is fine. I'd contact support at <a href="mailto:team@roll20.net" rel="nofollow">team@roll20.net</a>, and see if they can help.
Ok, thank you.
I have no idea of what happened, closed everything, restarted the PC and... now works! GiGs, thank you again for your quick answers.
1586707848
GiGs
Pro
Sheet Author
API Scripter
You're welcome. Glad it's sorted, anyway :)