HTML tag inconsistency


Author
Message
sallidina
sallidina
Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)
Group: Forum Members
Posts: 9, Visits: 213
I'm having some trouble getting html tags to work consistently within text and caption elements. There may be something I'm missing about how to make sure Inquisit is recognizing these as html.

Here's a simple example of trying to create a bulleted list. In the first text element, the list does not work correctly and the tags are simply reproduced as text when I run it. Only in the second text element, where I first use <b></b> tags to make a word bold, does the subsequent list correctly show up as bulleted.

It seems like Inquisit is not recognizing the tags in the first example. Am I missing something here?


<text list_doesnt_work>
/ items = ("Here is some example text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,20%)
</text>

<text list_works>
/ items = ("Here is some <b>example</b> text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,70%)
</text>

<trial test>
/ stimulusframes = [1=list_doesnt_work; 1=list_works]
/ validresponse = (" ")
</trial>
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 108K
sallidina - 7/18/2025
I'm having some trouble getting html tags to work consistently within text and caption elements. There may be something I'm missing about how to make sure Inquisit is recognizing these as html.

Here's a simple example of trying to create a bulleted list. In the first text element, the list does not work correctly and the tags are simply reproduced as text when I run it. Only in the second text element, where I first use <b></b> tags to make a word bold, does the subsequent list correctly show up as bulleted.

It seems like Inquisit is not recognizing the tags in the first example. Am I missing something here?


<text list_doesnt_work>
/ items = ("Here is some example text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,20%)
</text>

<text list_works>
/ items = ("Here is some <b>example</b> text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,70%)
</text>

<trial test>
/ stimulusframes = [1=list_doesnt_work; 1=list_works]
/ validresponse = (" ")
</trial>

Whether the tags are treated as HTML or not depends on the first formatting cue encountered in the item; if that's HTML, then it's treated as such.

In <text list_works>, the first cue is HTML (the <b></b> for bolding text).
In <text list_doesnt_work>, the first cue is a regular, old non-HTML linebreak.

Wrap the latter in <html></html> to fix that.

/ items = ("<html>Here is some example text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text</html>")


Or you could also do away with the linebreak and do

/ items = ("Here is some example text:<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")


but that's not as easy on the eyes when editing.
Edited Last Week by Dave
sallidina
sallidina
Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)
Group: Forum Members
Posts: 9, Visits: 213
Dave - 7/18/2025
sallidina - 7/18/2025
I'm having some trouble getting html tags to work consistently within text and caption elements. There may be something I'm missing about how to make sure Inquisit is recognizing these as html.

Here's a simple example of trying to create a bulleted list. In the first text element, the list does not work correctly and the tags are simply reproduced as text when I run it. Only in the second text element, where I first use <b></b> tags to make a word bold, does the subsequent list correctly show up as bulleted.

It seems like Inquisit is not recognizing the tags in the first example. Am I missing something here?


<text list_doesnt_work>
/ items = ("Here is some example text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,20%)
</text>

<text list_works>
/ items = ("Here is some <b>example</b> text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text")
/ position = (50%,70%)
</text>

<trial test>
/ stimulusframes = [1=list_doesnt_work; 1=list_works]
/ validresponse = (" ")
</trial>

Whether the tags are treated as HTML or not depends on the first formatting cue encountered in the item; if that's HTML, then it's treated as such.

In <text list_works>, the first cue is HTML (the <b></b> for bolding text).
In <text list_doesnt_work>, the first cue is a regular, old non-HTML linebreak.

Wrap the latter in <html></html> to fix that.

/ items = ("<html>Here is some example text:
<ul><li>Here's the first bullet point.</li>
<li>Here's the second bullet point.</li>
</ul>Here's the concluding text</html>")

That makes sense, thanks Dave!
sallidina
sallidina
Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)Associate Member (110 reputation)
Group: Forum Members
Posts: 9, Visits: 213
Follow-up question: Adding the <html> tags worked as intended, but it seems the text element no longer respects the /size specifications when I use these tags.

In the following example, the first text element correctly wraps to fit within the screen, but the second text element gets cut off on the left side.


<defaults>
/ windowsize = (1200px,800px)
</defaults>

<text example_text>
/ items = ("Welcome to the study!

In this study, you will have the chance to <b>earn up to $4 in bonus money</b>, on top of your base payment. We will explain how in these instructions.")
/ position = (50%,20%)
/ size = (70%, 20%)
</text>

<text example_text_html>
/ items = ("<html>Welcome to the study!
<br><br>
In this study, you will have the chance to <b>earn up to $4 in bonus money</b>, on top of your base payment. We will explain how in these instructions.</html>")
/ position = (50%,50%)
/ size = (70%, 20%)
</text>

<trial test>
/ stimulusframes = [1=example_text; 2=example_text_html]
/ validresponse = (" ")
</trial>
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 108K
sallidina - 7/22/2025
Follow-up question: Adding the <html> tags worked as intended, but it seems the text element no longer respects the /size specifications when I use these tags.

In the following example, the first text element correctly wraps to fit within the screen, but the second text element gets cut off on the left side.


<defaults>
/ windowsize = (1200px,800px)
</defaults>

<text example_text>
/ items = ("Welcome to the study!

In this study, you will have the chance to <b>earn up to $4 in bonus money</b>, on top of your base payment. We will explain how in these instructions.")
/ position = (50%,20%)
/ size = (70%, 20%)
</text>

<text example_text_html>
/ items = ("<html>Welcome to the study!
<br><br>
In this study, you will have the chance to <b>earn up to $4 in bonus money</b>, on top of your base payment. We will explain how in these instructions.</html>")
/ position = (50%,50%)
/ size = (70%, 20%)
</text>

<trial test>
/ stimulusframes = [1=example_text; 2=example_text_html]
/ validresponse = (" ")
</trial>

Yes, that's a know limitation. Use HTML formatting accordinly, i.e. insert line breaks (<br>) where they need to be and ideally foregoe /size entirely.

<defaults>
/ windowsize = (1200px,800px)
</defaults>

<text example_text>
/ items = ("Welcome to the study!

In this study, you will have the chance to <b>earn up to $4 in bonus money</b>, on top of your base payment. We will explain how in these instructions.")
/ position = (50%,20%)
/ size = (70%, 20%)
</text>

<text example_text_html>
/ items = ("<p align=center>Welcome to the study!
<br><br>
In this study, you will have the chance to <b>earn up to $4 in<br>bonus money</b>, on top of your base payment. We will explain<br>how in these instructions.
</p>")
/ position = (50%,50%)
</text>

<trial test>
/ stimulusframes = [1=example_text; 2=example_text_html]
/ validresponse = (" ")
</trial>




GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search