summaryrefslogtreecommitdiff
path: root/templates/edit_format.tpl
diff options
context:
space:
mode:
authorNick Palmer <nick@sluggardy.net>2006-08-23 03:59:23 +0000
committerNick Palmer <nick@sluggardy.net>2006-08-23 03:59:23 +0000
commit5b9c047cfa53b81eeff2b9b9c193bb291a11588b (patch)
tree7df0bdb75e205d17104a0b8fc0468555a97f2d00 /templates/edit_format.tpl
parentbd21ef641fef7db60e36f93390a786c1b9056616 (diff)
downloadliberty-5b9c047cfa53b81eeff2b9b9c193bb291a11588b.tar.gz
liberty-5b9c047cfa53b81eeff2b9b9c193bb291a11588b.tar.bz2
liberty-5b9c047cfa53b81eeff2b9b9c193bb291a11588b.zip
Fixed a problem with prototype's show and hide functions hiding the bitweaver
versions of those javascript function which made the format selection radios vanish. Modified the liberty/templates/edit_format.tpl and related files to allow editing of more than one content block in the same form. This can be done by setting gContent in the smarty include tag as well as format_guid_variable to the name of the variable the format should be stored in.
Diffstat (limited to 'templates/edit_format.tpl')
-rw-r--r--templates/edit_format.tpl10
1 files changed, 5 insertions, 5 deletions
diff --git a/templates/edit_format.tpl b/templates/edit_format.tpl
index a9fed7a..f4a62fc 100644
--- a/templates/edit_format.tpl
+++ b/templates/edit_format.tpl
@@ -25,7 +25,7 @@
{forminput}
{counter name=nb print=false assign=nb}
<label>
- {$plugin.edit_field}
+ <input type=radio name="{$format_guid_variable|default:"format_guid"}" value="{$plugin.edit_field}"
{if $gContent->mInfo.format_guid eq $plugin.plugin_guid}
checked="checked"
{elseif !$gContent->mInfo.format_guid and $plugin.plugin_guid eq $gBitSystem->getConfig('default_format')}
@@ -36,11 +36,11 @@
{foreach from=$gLibertySystem->mPlugins item=tag key=guid}
{if $tag.is_active eq 'y' and $tag.edit_field and $tag.plugin_type eq 'format'}
{if $tag.plugin_guid eq $plugin.plugin_guid}
- show
+ showById
{else}
- hide
+ hideById
{/if}
- ('qt{$tag.plugin_guid}');
+ ('qt{$textarea_id}{$tag.plugin_guid}');
{/if}
{/foreach}
{/if}
@@ -69,7 +69,7 @@
{if $nb > 2}
{$capture_format}
{else}
- <input type="hidden" name="format_guid" value="{$formatplugins[0].guid}" />
+ <input type="hidden" name="{$format_guid_variable|default:"format_guid"}" value="{$formatplugins[0].guid}" />
{/if}
{/strip}