diff options
| author | lsces <lester@lsces.co.uk> | 2026-03-27 16:14:07 +0000 |
|---|---|---|
| committer | lsces <lester@lsces.co.uk> | 2026-03-27 16:14:07 +0000 |
| commit | 62eb6b5048e4820dcd990a59f62d52c63174f19d (patch) | |
| tree | a89a11bedd16e2151573dc14ffcd053fcbf74fe0 | |
| parent | 95eeea7cc0bff5332a2803003633fecb4afbcfae (diff) | |
| download | pigeonholes-62eb6b5048e4820dcd990a59f62d52c63174f19d.tar.gz pigeonholes-62eb6b5048e4820dcd990a59f62d52c63174f19d.tar.bz2 pigeonholes-62eb6b5048e4820dcd990a59f62d52c63174f19d.zip | |
Figured what has been causing a problem with using && and || in smarty templates and related to mistake in processing {2} elements that should use curly brackets and not revert to square ones.
| -rw-r--r-- | modules/mod_category_menu.tpl | 2 | ||||
| -rwxr-xr-x | templates/assign_content.tpl | 8 | ||||
| -rwxr-xr-x | templates/edit_pigeonholes.tpl | 2 | ||||
| -rw-r--r-- | templates/menu_pigeonholes.tpl | 2 | ||||
| -rwxr-xr-x | templates/section_inc.tpl | 10 | ||||
| -rwxr-xr-x | templates/service_edit_mini_inc.tpl | 2 | ||||
| -rwxr-xr-x | templates/service_edit_tab_inc.tpl | 2 | ||||
| -rwxr-xr-x | templates/service_nav_path_inc.tpl | 2 | ||||
| -rwxr-xr-x | templates/service_view_members_inc.tpl | 8 | ||||
| -rwxr-xr-x | templates/view_table_inc.tpl | 4 |
10 files changed, 21 insertions, 21 deletions
diff --git a/modules/mod_category_menu.tpl b/modules/mod_category_menu.tpl index ffd7470..c563c4b 100644 --- a/modules/mod_category_menu.tpl +++ b/modules/mod_category_menu.tpl @@ -1,6 +1,6 @@ {* $Header$ *} {strip} -{if $gBitSystem->isFeatureActive( 'pigeonholes_display_members' ) and $modPigeonStructures} +{if $gBitSystem->isFeatureActive( 'pigeonholes_display_members' ) && $modPigeonStructures} {bitmodule title="$moduleTitle" name="whats_related"} {foreach from=$modPigeonStructures item=subtree} {include file="bitpackage:pigeonholes/view_structure_inc.tpl" no_details=true no_edit=true} diff --git a/templates/assign_content.tpl b/templates/assign_content.tpl index c81d88f..5eab1c3 100755 --- a/templates/assign_content.tpl +++ b/templates/assign_content.tpl @@ -15,7 +15,7 @@ {forminput} <select name="max_records"> - <option value="10" {if $smarty.request.max_records eq 10 or !$smarty.request.max_rows}selected="selected"{/if}>10</option> + <option value="10" {if $smarty.request.max_records eq 10 || !$smarty.request.max_rows}selected="selected"{/if}>10</option> {if !$gBitSystem->isFeatureActive('pigeonholes_reverse_assign_table')} <option value="50" {if $smarty.request.max_records eq 50}selected="selected"{/if}>50</option> <option value="100" {if $smarty.request.max_records eq 100}selected="selected"{/if}>100</option> @@ -71,7 +71,7 @@ <input type="hidden" name="content_type" value="{$contentSelect}" /> <input type="hidden" name="root_structure_id" value="{$smarty.request.root_structure_id}" /> - {if $gBitSystem->isFeatureActive( 'custom_member_sorting' ) and $smarty.request.include eq 'members'} + {if $gBitSystem->isFeatureActive( 'custom_member_sorting' ) && $smarty.request.include eq 'members'} {formfeedback warning="Using this insertion method will reset any custom sorting you have done so far."} {/if} @@ -155,7 +155,7 @@ <dl> <dt>{counter name=dogEatsPigeon}</dt> <dd>{$pigeon.display_path} - {if !empty($pigeon.parsed_data) and $gBitSystem->isFeatureActive('pigeonholes_display_description')} + {if !empty($pigeon.parsed_data) && $gBitSystem->isFeatureActive('pigeonholes_display_description')} <br /><small>{$pigeon.parsed_data}</small> {/if} </dd> @@ -167,7 +167,7 @@ {if $assignableContent} <div class="form-group"> - {if $smarty.request.include == 'members' and $listInfo.current_page < $listInfo.total_pages} + {if $smarty.request.include == 'members' && $listInfo.current_page < $listInfo.total_pages} <label><input type="checkbox" name="insert_content_and_next" /> {tr}Go To Next Page After Insert{/tr}</label> {/if} </div> diff --git a/templates/edit_pigeonholes.tpl b/templates/edit_pigeonholes.tpl index 1b7b0b6..9f61d55 100755 --- a/templates/edit_pigeonholes.tpl +++ b/templates/edit_pigeonholes.tpl @@ -90,7 +90,7 @@ {/legend} {/jstab} - {if $gBitSystem->isFeatureActive('pigeonholes_display_description') and $gBitUser->hasPermission('p_liberty_attach_attachments') } + {if $gBitSystem->isFeatureActive('pigeonholes_display_description') && $gBitUser->hasPermission('p_liberty_attach_attachments') } {jstab title="Attachments"} <div class=row> {legend legend="Attachments"} diff --git a/templates/menu_pigeonholes.tpl b/templates/menu_pigeonholes.tpl index 94d8a19..bc9212a 100644 --- a/templates/menu_pigeonholes.tpl +++ b/templates/menu_pigeonholes.tpl @@ -7,7 +7,7 @@ {if $gBitUser->hasPermission( 'p_pigeonholes_view' )} <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}list.php">{booticon iname="icon-list" iexplain="List Categories" ilocation=menu}</a></li> - {if $gContent->mStructureId and $gContent->mType.content_type_guid == $smarty.const.PIGEONHOLES_CONTENT_TYPE_GUID} + {if $gContent->mStructureId && $gContent->mType.content_type_guid == $smarty.const.PIGEONHOLES_CONTENT_TYPE_GUID} <li><a class="item" href="{$smarty.const.PIGEONHOLES_PKG_URL}{if $gBitSystem->isFeatureActive('pretty_urls_extended')}view/structure/{else}view.php?structure_id={/if}{$gContent->mStructureId}">{booticon iname="icon-search" iexplain="View Category" ilocation=menu}</a></li> {if $gBitUser->hasCreatePermission()} <li><a class="head" href="{$smarty.const.PIGEONHOLES_PKG_URL}edit_pigeonholes.php?structure_id={$gContent->getField('structure_id')}&action=edit">{booticon iname="icon-edit" iexplain="Edit Category" ilocation=menu}</a></li> diff --git a/templates/section_inc.tpl b/templates/section_inc.tpl index 7657ee3..fd71e16 100755 --- a/templates/section_inc.tpl +++ b/templates/section_inc.tpl @@ -1,7 +1,7 @@ {strip} {assign var=sid value=$subtree[ix].structure_id} -{if $gBitSystem->getConfig('pigeonholes_list_style') == "dynamic" and !$no_details} +{if $gBitSystem->getConfig('pigeonholes_list_style') == "dynamic" && !$no_details} <h3 class="highlight"><a href="{$smarty.const.PIGEONHOLES_PKG_URL}{ if $gBitSystem->isFeatureActive('pretty_urls') @@ -17,12 +17,12 @@ {$pigeonList.$sid.parsed_data} {/if} - <ul style="display:{if $gContent->mStructureId eq $subtree[ix].structure_id or $smarty.request.expand_all}block{else}none{/if}; padding:2em;" class="data"> + <ul style="display:{if $gContent->mStructureId eq $subtree[ix].structure_id || $smarty.request.expand_all}block{else}none{/if}; padding:2em;" class="data"> {foreach from=$pigeonList.$sid.members item=pigeonMember} {assign var=ctg1 value=$pigeonMember.content_type_guid} {* close off the content type <ul> *} - {if $ctg1 ne $ctg2 and $ctg2} + {if $ctg1 ne $ctg2 && $ctg2} </ul> </li> {/if} @@ -55,7 +55,7 @@ {else} {* ======= very basic display of the pigoenhole structure ======= *} - {if !$no_edit and $gBitUser->hasPermission( 'p_pigeonholes_update' )} + {if !$no_edit && $gBitUser->hasPermission( 'p_pigeonholes_update' )} <div class="floaticon"> {smartlink ititle="Insert new Category" ifile="edit_pigeonholes.php" booticon="icon-file" structure_id=$subtree[ix].structure_id action=create} {smartlink ititle="Edit Category" booticon="icon-edit" ifile="edit_pigeonholes.php" structure_id=$subtree[ix].structure_id action=edit} @@ -63,7 +63,7 @@ </div> {/if} - {if $subtree[ix].content_id == $smarty.request.content_id or $subtree[ix].structure_id == $smarty.request.structure_id} + {if $subtree[ix].content_id == $smarty.request.content_id || $subtree[ix].structure_id == $smarty.request.structure_id} {assign var=current value=1} {else} {assign var=current value=0} diff --git a/templates/service_edit_mini_inc.tpl b/templates/service_edit_mini_inc.tpl index d54a9a8..2893b0c 100755 --- a/templates/service_edit_mini_inc.tpl +++ b/templates/service_edit_mini_inc.tpl @@ -1,5 +1,5 @@ {strip} -{if $editPigeonholesEnabled and $gBitUser->hasPermission( 'p_pigeonholes_insert_member' )} +{if $editPigeonholesEnabled && $gBitUser->hasPermission( 'p_pigeonholes_insert_member' )} <div class="form-group"> {formlabel label="Categorize" for="pigeonholes"} {if $pigeonPathList|@count ne 0} diff --git a/templates/service_edit_tab_inc.tpl b/templates/service_edit_tab_inc.tpl index fa986c4..fc71787 100755 --- a/templates/service_edit_tab_inc.tpl +++ b/templates/service_edit_tab_inc.tpl @@ -1,5 +1,5 @@ {strip} -{if $editPigeonholesEnabled and $gBitUser->hasPermission( 'p_pigeonholes_insert_member' )} +{if $editPigeonholesEnabled && $gBitUser->hasPermission( 'p_pigeonholes_insert_member' )} {jstab title="Categorize"} {legend legend="Categorize"} {include file="bitpackage:pigeonholes/service_edit_mini_inc.tpl"} diff --git a/templates/service_nav_path_inc.tpl b/templates/service_nav_path_inc.tpl index 17d5675..ef64c17 100755 --- a/templates/service_nav_path_inc.tpl +++ b/templates/service_nav_path_inc.tpl @@ -1,5 +1,5 @@ {strip} -{if $gBitSystem->isFeatureActive( 'pigeonholes_display_path' ) and $pigeonData} +{if $gBitSystem->isFeatureActive( 'pigeonholes_display_path' ) && $pigeonData} <div class="structurebar pigeonholesbar"> {foreach from=$pigeonData item=pigeonItem} <span class="path">{$pigeonItem.display_path} diff --git a/templates/service_view_members_inc.tpl b/templates/service_view_members_inc.tpl index 4ace457..4171b01 100755 --- a/templates/service_view_members_inc.tpl +++ b/templates/service_view_members_inc.tpl @@ -1,5 +1,5 @@ {strip} -{if $gBitSystem->isFeatureActive( 'pigeonholes_display_members' ) and $pigeonData} +{if $gBitSystem->isFeatureActive( 'pigeonholes_display_members' ) && $pigeonData} <div class="service pigeonholes"> {if $gBitSystem->getConfig('pigeonholes_limit_member_number') == 0} <h2>{tr}Categories{/tr}</h2> @@ -17,7 +17,7 @@ <h3>{$pigeonItem.display_path}</h3> <p> - {if $pigeonItem.parsed_data and $gBitSystem->isFeatureActive( 'pigeonholes_display_description' )} + {if $pigeonItem.parsed_data && $gBitSystem->isFeatureActive( 'pigeonholes_display_description' )} {$pigeonItem.parsed_data}<br /> {/if} @@ -28,9 +28,9 @@ {foreach from=$pigeonItem.members item=member name=members} {assign var=ctg1 value=$member.content_type_guid} - {if $ctg1 ne $ctg2 and $gBitSystem->isFeatureActive( 'pigeonholes_display_content_type' )}{if $ctg2}<br />{/if}{$gLibertySystem->getContentTypeName($ctg1)}: {/if} + {if $ctg1 ne $ctg2 && $gBitSystem->isFeatureActive( 'pigeonholes_display_content_type' )}{if $ctg2}<br />{/if}{$gLibertySystem->getContentTypeName($ctg1)}: {/if} - {if !$gBitSystem->getConfig('pigeonholes_limit_member_number') or $member_count lt $gBitSystem->getConfig('pigeonholes_limit_member_number')} + {if !$gBitSystem->getConfig('pigeonholes_limit_member_number') || $member_count lt $gBitSystem->getConfig('pigeonholes_limit_member_number')} {if $serviceHash.content_id == $member.content_id}<strong>{/if} {$member.display_link} {if $serviceHash.content_id == $member.content_id}</strong>{/if} diff --git a/templates/view_table_inc.tpl b/templates/view_table_inc.tpl index 0fbfbff..96c845e 100755 --- a/templates/view_table_inc.tpl +++ b/templates/view_table_inc.tpl @@ -4,7 +4,7 @@ <a name="members"></a> <h2>{$gContent->getTitle()}</h2> <p> - {if !empty($pigeonItem.parsed_data) and $gBitSystem->isFeatureActive('pigeonholes_display_description')} + {if !empty($pigeonItem.parsed_data) && $gBitSystem->isFeatureActive('pigeonholes_display_description')} {$pigeonItem.parsed_data} <br /> {/if} @@ -25,7 +25,7 @@ <li> {assign var=size value=$gBitSystem->getConfig('pigeonholes_member_thumb')} <a href="{$member.display_url}"> - {if $gBitSystem->isFeatureActive( 'pigeonholes_member_thumb' ) and $member.thumbnail_url.$size} + {if $gBitSystem->isFeatureActive( 'pigeonholes_member_thumb' ) && $member.thumbnail_url.$size} <img src="{$member.thumbnail_url.$size}" alt="{$member.title|escape}" title="{$member.title|escape}" /><br /> {/if} {$member.title|escape}{if $gBitSystem->isFeatureActive( 'pigeonholes_display_content_type' )} <small>{tr}{$member.content_name}{/tr}</small>{/if} |
