Ignore:
Timestamp:
Mar 19, 2010, 2:15:02 PM (14 years ago)
Author:
plg
Message:

feature 724: bug fixed on element_set_unit for FCKB, better use
$("#tags-123, #tags-456") than $(".tags") to apply FCKB widget on
the select box.

Use a dedicated function to return the tag list, formatted for FCKB.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/themes/default/template/element_set_unit.tpl

    r5188 r5189  
    44
    55{known_script id="jquery.fcbkcomplete" src=$ROOT_URL|@cat:"themes/default/js/plugins/jquery.fcbkcomplete.js"}
     6<script type="text/javascript">
     7  var tag_boxes_selector = "";
     8{foreach from=$elements item=element name=element}
     9  {if $smarty.foreach.element.first}
     10  var prefix = "";
     11  {else}
     12  prefix = ", ";
     13  {/if}
     14  tag_boxes_selector = tag_boxes_selector + prefix + "#tags-" + {$element.ID};
     15{/foreach}
    616{literal}
    7 <script type="text/javascript">
    817  $(document).ready(function() {
    9     $(".tags").fcbkcomplete({
     18    $(tag_boxes_selector).fcbkcomplete({
    1019      json_url: "admin.php?fckb_tags=1",
    1120      cache: false,
     
    97106      <td>
    98107
    99 <select class="tags" name="tags-{$element.ID}">
     108<select id="tags-{$element.ID}" name="tags-{$element.ID}">
    100109{foreach from=$element.TAGS item=tag}
    101110  <option value="{$tag.value}" class="selected">{$tag.caption}</option>
Note: See TracChangeset for help on using the changeset viewer.