Changeset 30655


Ignore:
Timestamp:
Dec 2, 2014, 8:52:10 PM (10 years ago)
Author:
ddtddt
Message:

[extensions] - manage_info_photos

Location:
extensions/manage_info_photos
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/manage_info_photos/admin.php

    r30654 r30655  
    5050   
    5151    $PAED = pwg_db_fetch_assoc(pwg_query("SELECT state FROM " . PLUGINS_TABLE . " WHERE id = 'ExtendedDescription';"));
    52     if($PAED['state'] == 'active') add_event_handler('AP_render_content', 'get_user_language_desc');
     52    $PAED = pwg_db_fetch_assoc(pwg_query("SELECT state FROM " . PLUGINS_TABLE . " WHERE id = 'ExtendedDescription';"));
     53    if($PAED['state'] == 'active'){
     54        add_event_handler('AP_render_content', 'get_user_language_desc');
     55                $template->assign('useED',1);
     56    }else{
     57        $template->assign('useED',0);
     58    }
    5359
    5460    $tab_add_info_one_photo = tab_add_info_by_photo($_GET['image_id']);
     
    106112       
    107113    $PAED = pwg_db_fetch_assoc(pwg_query("SELECT state FROM " . PLUGINS_TABLE . " WHERE id = 'ExtendedDescription';"));
    108     if($PAED['state'] == 'active') add_event_handler('AP_render_content', 'get_user_language_desc');
     114    if($PAED['state'] == 'active'){
     115        add_event_handler('AP_render_content', 'get_user_language_desc');
     116                $template->assign('useED',1);
     117    }else{
     118        $template->assign('useED',0);
     119    }
    109120       
    110121        $admin_base_url = ADD_INFO_PHOTO_ADMIN . '-define_information';
  • extensions/manage_info_photos/admin/admin.tpl

    r30654 r30655  
    11{combine_script id='jquery.ui.sortable' require='jquery.ui' load='footer' path='themes/default/js/ui/minified/jquery.ui.sortable.min.js'}
     2{combine_script id='core.scripts' load='async' path='themes/default/js/scripts.js'}
    23{footer_script}
    34jQuery(document).ready(function(){
     
    5354                <p class="input">
    5455                    <label for="inserdesignation">{'Designation'|@translate}</label><br />
    55                     <textarea style="margin-left:50px" rows="5" cols="50" class="description" name="inserdesignation" id="aip_add">{$addinfo_edit2.AIPDESC}</textarea>
     56                    <textarea {if $useED==1}placeholder="{'Use Extended Description tags...'|@translate}"{/if} style="margin-left:50px" rows="5" cols="50" class="description" name="inserdesignation" id="aip_add">{$addinfo_edit2.AIPDESC}</textarea>
     57                    {if $useED==1}
     58                    <a href="{$ROOT_URL}admin/popuphelp.php?page=extended_desc" onclick="popuphelp(this.href); return false;" title="{'Use Extended Description tags...'|translate}" style="vertical-align: middle; border: 0; margin: 0.5em;"><img src="{$ROOT_URL}{$themeconf.admin_icon_dir}/help.png" class="button" alt="{'Use Extended Description tags...'|translate}'"></a>
     59                    {/if}
    5660                </p>
    5761                <p class="input" style="width: 700px;">
     
    126130            <tr>
    127131                <td style="width: 100px;"><span style="font-weight: bold; text-align: right;" >{$infophoto.AIPDESIGNATION}</span></td>
    128                 <td><input type="text" size="150" maxlength="250" name="data[{$infophoto.IDINFOPHO}]" value="{$infophoto.AIPDATA}" /></td>
     132                <td><input type="text" size="150" maxlength="250" {if $useED==1}placeholder="{'Use Extended Description tags...'|@translate}"{/if} name="data[{$infophoto.IDINFOPHO}]" value="{$infophoto.AIPDATA}" /></td>
    129133            </tr> 
    130134            {/foreach}
    131             <tr>   </tr>
     135            <tr style="text-align: right;">
     136                <td colspan="2">
     137                    {if $useED==1}
     138                        <a href="{$ROOT_URL}admin/popuphelp.php?page=extended_desc" onclick="popuphelp(this.href); return false;" title="{'Use Extended Description tags...'|translate}" style="vertical-align: middle; border: 0; margin: 0.5em;"><img src="{$ROOT_URL}{$themeconf.admin_icon_dir}/help.png" class="button" alt="{'Use Extended Description tags...'|translate}'"></a>
     139                    {/if}
     140                </td>
     141            </tr>
    132142            <tr>
    133143                <td colspan="2">
Note: See TracChangeset for help on using the changeset viewer.