[ Index ]
 

Code source de eZ Publish 3.9.0

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/design/base/override/templates/full/ -> forum_topic.tpl (source)

   1  {let page_limit=20
   2       reply_limit=$page_limit
   3       reply_offset=$view_parameters.offset
   4       reply_list=fetch('content','list', hash( parent_node_id, $node.node_id,
   5                                                limit, $reply_limit,
   6                                                offset, $reply_offset,
   7                                                sort_by, array( array( published, true() ) ) ) )
   8       reply_count=fetch('content','list_count', hash( parent_node_id, $node.node_id ) )
   9       previous_topic=fetch_alias( subtree, hash( parent_node_id, $node.parent_node_id,
  10                                                  class_filter_type, include,
  11                                                  class_filter_array, array( 'forum_topic' ),
  12                                                  limit, 1,
  13                                                  attribute_filter, array( and, array( 'published', '<', $node.object.published ) ),
  14                                                  sort_by, array( array( 'published', false() ) ) ) )
  15       next_topic=fetch_alias( subtree, hash( parent_node_id, $node.parent_node_id,
  16                                              class_filter_type, include,
  17                                              class_filter_array, array( 'forum_topic' ),
  18                                              limit, 1,
  19                                              attribute_filter, array( and, array( 'published', '>', $node.object.published ) ),
  20                                              sort_by, array( array( 'published', true() ) ) ) ) }
  21  
  22  
  23  <div class="content-view-full">
  24      <div class="class-forum">
  25  
  26          <h1>{$node.name|wash}</h1>
  27  
  28          {section show=is_unset( $versionview_mode )}
  29          <div class="content-navigator">
  30              {section show=$previous_topic}
  31                  <div class="content-navigator-previous">
  32                      <div class="content-navigator-arrow">&laquo;&nbsp;</div><a href={$previous_topic[0].url_alias|ezurl} title="{$previous_topic[0].name|wash}">{'Previous topic'|i18n( 'design/base' )}</a>
  33                  </div>
  34              {section-else}
  35                  <div class="content-navigator-previous-disabled">
  36                      <div class="content-navigator-arrow">&laquo;&nbsp;</div>{'Previous topic'|i18n( 'design/base' )}
  37                  </div>
  38              {/section}
  39  
  40              {section show=$previous_topic}
  41                  <div class="content-navigator-separator">|</div>
  42              {section-else}
  43                  <div class="content-navigator-separator-disabled">|</div>
  44              {/section}
  45  
  46              {let forum=$node.parent}
  47                  <div class="content-navigator-forum-link"><a href={$forum.url_alias|ezurl}>{$forum.name|wash}</a></div>
  48              {/let}
  49  
  50              {section show=$next_topic}
  51                  <div class="content-navigator-separator">|</div>
  52              {section-else}
  53                  <div class="content-navigator-separator-disabled">|</div>
  54              {/section}
  55  
  56              {section show=$next_topic}
  57                  <div class="content-navigator-next">
  58                      <a href={$next_topic[0].url_alias|ezurl} title="{$next_topic[0].name|wash}">{'Next topic'|i18n( 'design/base' )}</a><div class="content-navigator-arrow">&nbsp;&raquo;</div>
  59                  </div>
  60              {section-else}
  61                  <div class="content-navigator-next-disabled">
  62                      {'Next topic'|i18n( 'design/base' )}<div class="content-navigator-arrow">&nbsp;&raquo;</div>
  63                  </div>
  64              {/section}
  65          </div>
  66  
  67          {section show=$node.object.can_create}
  68          <form method="post" action={"content/action/"|ezurl}>
  69              <input class="button forum-new-reply" type="submit" name="NewButton" value="{'New reply'|i18n( 'design/base' )}" />
  70              <input type="hidden" name="ContentNodeID" value="{$node.node_id}" />
  71              <input type="hidden" name="ContentObjectID" value="{$node.contentobject_id}" />
  72              <input class="button forum-keep-me-updated" type="submit" name="ActionAddToNotification" value="{'Keep me updated'|i18n( 'design/base' )}" />
  73              <input type="hidden" name="NodeID" value="{$node.node_id}" />
  74              <input type="hidden" name="ClassIdentifier" value="forum_reply" />
  75          </form>
  76          {section-else}
  77             <p>
  78              {"You need to be logged in to get access to the forums. You can do so"|i18n("design/base")} <a href={"/user/login/"|ezurl}>{"here"|i18n("design/base")}</a>
  79             </p>
  80          {/section}
  81          {/section}
  82  
  83          <div class="content-view-children">
  84              <table class="list forum" cellspacing="0">
  85              <tr>
  86                  <th class="author">
  87                      {"Author"|i18n("design/base")}
  88                  </th>
  89                  <th class="message">
  90                      {"Message"|i18n("design/base")}
  91                   </th>
  92              </tr>
  93              {section show=$view_parameters.offset|lt( 1 )}
  94              <tr>
  95                 <td class="author">
  96                 {let owner=$node.object.owner owner_map=$owner.data_map}
  97                     <p class="author">{$owner.name|wash}
  98                     {section show=is_set( $owner_map.title )}
  99                         <br/>{$owner_map.title.content|wash}
 100                     {/section}</p>
 101                     {section show=$owner_map.image.has_content}
 102                     <div class="authorimage">
 103                        {attribute_view_gui attribute=$owner_map.image image_class=small}
 104                     </div>
 105                     {/section}
 106  
 107                     {section show=is_set( $owner_map.location )}
 108                         <p>{"Location"|i18n( "design/base" )}: {$owner_map.location.content|wash}</p>
 109                     {/section}
 110                     <p>
 111                        {let owner_id=$node.object.owner_id}
 112                            {section var=author loop=$node.object.author_array}
 113                                {section show=eq($owner_id,$author.contentobject_id)|not()}
 114                                    {"Moderated by"|i18n( "design/base" )}: {$author.contentobject.name|wash}
 115                                {/section}
 116                            {/section}
 117                        {/let}
 118                     </p>
 119  
 120                    {section show=$node.object.can_edit}
 121                        <form method="post" action={"content/action/"|ezurl}>
 122                            <input type="hidden" name="ContentObjectID" value="{$node.object.id}" />
 123                            <input class="button forum-account-edit" type="submit" name="EditButton" value="{'Edit'|i18n('design/base')}" />
 124                        </form>
 125                    {/section}
 126                 </td>
 127                 <td class="message">
 128                     <p class="date">{$node.object.published|l10n(datetime)}</p>
 129                     <h2>{$node.name|wash}</h2>
 130                     <p>
 131                         {$node.data_map.message.content|simpletags|wordtoimage|autolink}
 132                     </p>
 133                     {section show=$owner_map.signature.has_content}
 134                         <p class="author-signature">{$owner_map.signature.content|simpletags|autolink}</p>
 135                     {/section}
 136                 </td>
 137                 {/let}
 138             </tr>
 139             {/section}
 140  
 141             {section var=reply loop=$reply_list sequence=array( bgdark, bglight )}
 142             <tr class="{$reply.sequence}">
 143                 <td class="author">
 144                 {let owner=$reply.object.owner owner_map=$owner.data_map}
 145                     <p class="author">{$owner.name|wash}
 146                     {section show=is_set( $owner_map.title )}
 147                         <br/>{$owner_map.title.content|wash}
 148                     {/section}</p>
 149  
 150                     {section show=$owner_map.image.has_content}
 151                     <div class="authorimage">
 152                        {attribute_view_gui attribute=$owner_map.image image_class=small}
 153                     </div>
 154                     {/section}
 155  
 156                     {section show=is_set( $owner_map.location )}
 157                         <p>{"Location"|i18n( "design/base" )}: {$owner_map.location.content|wash}</p>
 158                     {/section}
 159  
 160                     {let owner_id=$reply.object.owner.id}
 161                         {section var=author loop=$reply.object.author_array}
 162                             {section show=ne( $reply.object.owner_id, $author.contentobject_id )}
 163                                 <p>
 164                                     {'Moderated by'|i18n( 'design/base' )}: {$author.contentobject.name|wash}
 165                                 </p>
 166                             {/section}
 167                         {/section}
 168                     {/let}
 169  
 170                     {switch match=$reply.object.can_edit}
 171                     {case match=1}
 172                         <form method="post" action={"content/action/"|ezurl}>
 173                         <input type="hidden" name="ContentObjectID" value="{$reply.object.id}" />
 174                         <input class="button" type="submit" name="EditButton" value="{'Edit'|i18n('design/base')}" />
 175                         </form>
 176                     {/case}
 177                     {case match=0}
 178                     {/case}
 179                     {/switch}
 180  
 181                 </td>
 182                 <td class="message">
 183                     <p class="date">{$reply.object.published|l10n( datetime )}</p>
 184  
 185                     <h2 id="msg{$reply.node_id}">{$reply.name|wash}</h2>
 186                     <p>
 187                         {$reply.object.data_map.message.content|simpletags|wordtoimage|autolink}
 188                     </p>
 189  
 190                     {section show=$owner_map.signature.has_content}
 191                         <p class="author-signature">{$owner_map.signature.content|simpletags|autolink}</p>
 192                     {/section}
 193                 {/let}
 194                 </td>
 195             </tr>
 196             {/section}
 197  
 198             </table>
 199  
 200          </div>
 201  
 202      </div>
 203  </div>
 204  
 205  {include name=navigator
 206           uri='design:navigator/google.tpl'
 207           page_uri=$node.url_alias
 208           item_count=$reply_count
 209           view_parameters=$view_parameters
 210           item_limit=$page_limit}
 211  
 212  


Généré le : Sat Feb 24 10:30:04 2007 par Balluche grâce à PHPXref 0.7