help.php 1.3 KB

123456789101112131415161718192021222324252627282930313233
  1. <?php /**
  2. * Copyright (c) 2011, Frank Karlitschek karlitschek@kde.org
  3. * This file is licensed under the Affero General Public License version 3 or later.
  4. * See the COPYING-README file.
  5. */?>
  6. <div id="controls">
  7. <a class="button newquestion" href="http://apps.owncloud.com/knowledgebase/editquestion.php?action=new" target="_blank"><?php echo $l->t( 'Ask a question' ); ?></a>
  8. <?php
  9. $url=OC_Helper::linkTo( "settings", "help.php" ).'?page=';
  10. $pageNavi=OC_Util::getPageNavi($_['pagecount'],$_['page'],$url);
  11. if($pageNavi)
  12. {
  13. $pageNavi->printPage();
  14. }
  15. ?>
  16. </diV>
  17. <?php if(is_null($_["kbe"])):?>
  18. <div class="helpblock">
  19. <p><?php echo $l->t('Problems connecting to help database.');?></p>
  20. <p><a href="http://apps.owncloud.com/kb"><?php echo $l->t('Go there manually.');?></a></p>
  21. </div>
  22. <?php else:?>
  23. <?php foreach($_["kbe"] as $kb): ?>
  24. <div class="helpblock">
  25. <?php if($kb["preview1"] <> "") { echo('<img class="preview" src="'.$kb["preview1"].'" />'); } ?>
  26. <?php if($kb['detailpage']<>'') echo('<p><a target="_blank" href="'.$kb['detailpage'].'"><strong>'.$kb["name"].'</strong></a></p>');?>
  27. <p><?php echo $kb['description'];?></p>
  28. <?php if($kb['answer']<>'') echo('<p><strong>'.$l->t('Answer').':</strong><p>'.$kb['answer'].'</p>');?>
  29. </div>
  30. <?php endforeach;
  31. endif?>