[Cartoweb-users] Troubles with tables.tpl

Valerio Noti valerionoti at yahoo.it
Thu Mar 13 10:53:46 EDT 2008


Hello,
I usually modify tpl files inserting javascript code. i.e. I modified
tables.tpl in order to open a pop-up windows when user click on the map with
query tool.

The following code works fine in cartoweb 3.2 but not in cw3.4:
[...]
{foreach from=$tables item=group}
foreach from=$group->tables item=table}
{if $table->numRows > 0}
<script language=javascript>
        {literal}
        strNomeTabella = '{/literal}{$table->tableTitle}{literal}';
        alert ('Test');
        {/literal}
</script>
     {foreach from=$table->columnTitles item=column}
      <script language=javascript>
              {literal}
                  var campo = '{/literal}{$column}{literal}';
              {/literal}
      </script>
      {/foreach}
[...]
{/foreach}
{/foreach}

In cw3.4 it seems that javascript code is not active. Nothing is saved in
variables and alert statement doesn't work.



Thank you very much for any help


Valerio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/cartoweb-users/attachments/20080313/a93db8c8/attachment.html


More information about the Cartoweb-users mailing list