xblock html problem

15 views
Skip to first unread message

xyaw Li

unread,
Mar 21, 2019, 12:00:31 AM3/21/19
to General Open edX discussion
https://drive.google.com/file/d/1SPTLspHjBxmqGiE39slGQZxA5inRZpe7/view?usp=sharing

Attached file is the code.
==========================
I would like to show different content via if-else ,



<div class="box_block" >
{% if self.display_name == "Visualize Coding" %}
{{ self.boxurl }}
{% endif %}
{% if self.display_name == "External Html" %}
<iframe src="{self.boxurl}" frameborder="0" name="test" scrolling="yes" width="{self.boxwidth}" height="{self.boxheight}" allowfullscreen></iframe>
{% endif %}
</div>


I try many times and still fail . 
Is there any document about the xblock-html develope? 

(Maybe somebody could tell me the problem in my code.)
box.zip
Reply all
Reply to author
Forward
0 new messages