Hi Everyone:
I like to add two containers ( id="playertabledice_${id}" and id="blackdice_${id} ) to my players' panel but can only add one
Here is my attempt to add the 2 containers- it seems there is a problem with my "jstpl_player_board" declaration in .tpl
when I run my game.js, the line " dojo.place( this.format_block('jstpl_player_board', player ), player_board_div ); " results in a
"jstpl_player_board is undefined" syntax error
Can you please tell me what I am doing incorrectly or offer me any help
Thank you for any help!
I like to add two containers ( id="playertabledice_${id}" and id="blackdice_${id} ) to my players' panel but can only add one
Here is my attempt to add the 2 containers- it seems there is a problem with my "jstpl_player_board" declaration in .tpl
Code: Select all
var jstpl_player_board = '\<div class="cp_board">\
<div id="playertabledice_${id}" class="playertabledice"></div>\
<div id="blackdice_${id}" class="playertabledice"></div>\
</div>';
"jstpl_player_board is undefined" syntax error
Code: Select all
for( var player_id in gamedatas.players )
{
var player = gamedatas.players[player_id];
var player_board_div = $('player_board_'+player_id);
dojo.place( this.format_block('jstpl_player_board', player ), player_board_div );
}
Thank you for any help!