Changeset 133 for trunk/app/views/faqs

Show
Ignore:
Timestamp:
09/19/07 15:58:30 (15 months ago)
Author:
aarkerio
Message:

Update users and Faqs

Location:
trunk/app/views/faqs
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/app/views/faqs/admin_add.thtml

    r19 r133  
     1<div class="title_section">Add new Q&amp;A</div> 
    12 
    2 <div class="spaced"> 
     3<?php echo $html->formTag('/admin/faqs/add/'.$catfaq_id,'post'); ?> 
     4<?php echo $html->hiddenTag('Faq/catfaq_id', $catfaq_id); ?> 
    35 
    4 <?php echo $html->addCrumb('Control Tools', '/entries/index'); ?>  
    5 <?php echo $html->addCrumb('Entries', '/entries/listing'); ?>  
    6 <?php echo $html->getCrumbs(' / '); ?> 
    7  
    8 <?php echo $javascript->link('myfunctions'); ?> 
    9 <?php echo $javascript->link('fckeditor/fckeditor'); ?>  
    10  
    11 <div class="title_section">Add new FAQ</div> 
    12  
    13  
    14 <div class="spaced"> 
    15  
    16 <?php echo $html->formTag('/faqs/add/'.$catfaq_id,'post'); ?> 
    17 <?php echo $html->hiddenTag('Faq/user_id', $othAuth->user('id')) ?> 
    18 <?php echo $html->hiddenTag('Faq/catfaq_id', $catfaq_id) ?> 
    19    
    206<fieldset> 
    217   <legend>New Question/Answer</legend> 
     
    4127</fieldset> 
    4228</form> 
    43 </div> 
  • trunk/app/views/faqs/admin_listing.thtml

    r61 r133  
    11<?php 
     2//exit(var_dump($data)); 
     3 
    24if ( isset($javascript) ): 
    35  echo $html->charsetTag('UTF-8'); 
    46  echo $javascript->link('prototype'); 
    57  echo $javascript->link('scriptaculous.js?load=effects'); 
     8  echo $javascript->link('fckeditor/fckeditor'); 
    69endif; 
    710?> 
     
    1518echo $html->getCrumbs(' / ');  
    1619?> 
    17  
     20<div class="title_section">Questions &amp; answers</div> 
    1821<p> 
    1922<?php 
     
    2225 echo '</div>'; 
    2326     
    24  echo  $ajax->link($html->image('actions/new.png', array("alt"=>"Add new FQA", "title"=>"Add new FAQ")),                   '/admin/faqs/add',  
     27 echo  $ajax->link($html->image('actions/new.png', array("alt"=>"Add new FAQ", "title"=>"Add new FAQ")),'/admin/faqs/add/'.$catfaq_id,  
    2528     array("update" => "updater","loading"=>"Element.show('loading');Element.hide('updater');", "complete"=>"Element.hide('loading');Effect.Appear('updater')"),  
    2629                null, false); 
     
    2932echo $ajax->divEnd('updater'); 
    3033?></p> 
    31  
    3234<?php 
    33 //exit(print_r($data)); 
    3435foreach ($data as $val) 
    3536{ 
    36    echo '<div style="padding:6px;margin:5px;border:1px dotted gray;">'; 
    37      
    38    echo $gags->sendEdit($val['Faq']['id'], 'faqs'); 
    39     
    40    echo $html->link($val['Faq']['title'], '/admin/faqs/listing/'.$val['Faq']['id'], array("class"=>"largelink")); 
    41     echo '<p style="margin-left:15px;">'. $val['Faq']['description']  . '</p>'; 
    42      
    43     echo $html->formTag('/admin/faqs/delete/'.$val['Faq']['id'], 'post', array("onsubmit"=>"return confirm('Are you sure to delete this item?')")) . $html->submit('Delete') . '</form>'; 
    44     
     37   echo '<div style="padding:6px 3px 28px 4px;margin:10px 0 5px 0;border:1px dotted gray;">'; 
     38        echo '<div class="butonright">'. $gags->sendEdit($val['Faq']['id'], 'faqs')   . '</div>'; 
     39        echo '<b>'.$val['Faq']['question'] . '</b><br />'; 
     40        echo '<p style="margin-left:15px;">'. $val['Faq']['answer']  . '</p>'; 
     41        echo '<div class="butonright">'. $gags->confirmDel($val['Faq']['id'], 'faqs') . '</div>'; 
    4542   echo '</div>'; 
    4643}