blogs
[ class tree: blogs ] [ index: blogs ] [ all elements ]

Source for file print_blog_post.php

Documentation is available at print_blog_post.php

  1. <?php
  2. /**
  3.  * @version $Header$
  4.  
  5.  * @package blogs
  6.  * @subpackage functions
  7.  */
  8. // Copyright (c) 2002-2003, Luis Argerich, Garland Foster, Eduardo Polidor, et. al.
  9. // All Rights Reserved. See below for details and a complete list of authors.
  10. // Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See http://www.gnu.org/copyleft/lesser.html for details.
  11.  
  12. /**
  13.  * required setup
  14.  */
  15. require_once'../kernel/setup_inc.php' );
  16.  
  17. include_onceBLOGS_PKG_PATH.'BitBlogPost.php' );
  18.  
  19. $gBitSystem->verifyPackage'blogs' );
  20.  
  21. if (!isset($_REQUEST["post_id"])) {
  22.     $gBitSystem->fatalErrortra'No post indicated' ));
  23. }
  24.  
  25. include_onceBLOGS_PKG_PATH.'lookup_post_inc.php' );
  26.  
  27. $gBitSmarty->assign('post_info'$gContent->mInfo );
  28.  
  29. //Build absolute URI for this
  30. $parts parse_url($_SERVER['REQUEST_URI']);
  31. /*OLD with blog_id - might later want to reincorporate blog_id but will have to start in the view_blog_post.tpl -wjames5
  32. $uri = httpPrefix(). $parts['path'] . '?blog_id=' . $gContent->mInfo['blog_id'] . '&post_id=' . $gContent->mInfo['post_id'];
  33. $uri2 = httpPrefix(). $parts['path'] . '/' . $gContent->mInfo['blog_id'] . '/' . $gContent->mInfo['post_id'];
  34. */
  35. $uri httpPrefix()$parts['path''?post_id=' $gContent->mInfo['post_id'];
  36. $uri2 httpPrefix()$parts['path''/' $gContent->mInfo['post_id'];
  37. $gBitSmarty->assign('uri'$uri);
  38. $gBitSmarty->assign('uri2'$uri2);
  39.  
  40. if (!isset($_REQUEST['offset']))
  41.     $_REQUEST['offset'0;
  42.  
  43. if (!isset($_REQUEST['sort_mode']))
  44.     $_REQUEST['sort_mode''created_desc';
  45.  
  46. if (!isset($_REQUEST['find']))
  47.     $_REQUEST['find''';
  48.  
  49. $gBitSmarty->assign('offset'$_REQUEST["offset"]);
  50. $gBitSmarty->assign('sort_mode'$_REQUEST["sort_mode"]);
  51. $gBitSmarty->assign('find'$_REQUEST["find"]);
  52. $offset $_REQUEST["offset"];
  53. $sort_mode $_REQUEST["sort_mode"];
  54. $find $_REQUEST["find"];
  55.  
  56. $gBitSmarty->assign'parsed_data'$gContent->parseData() );
  57.  
  58. $gBitSystem->verifyPermission'p_blogs_view' );
  59.  
  60. if ($gBitSystem->isFeatureActive'blog_posts_comments' )) {
  61.     $comments_return_url $_SERVER['SCRIPT_NAME']."?post_id=".$gContent->getField'post_id' );
  62.     $commentsParentId $gContent->mContentId;
  63.     include_once LIBERTY_PKG_PATH.'comments_inc.php' );
  64. }
  65.  
  66.  
  67. $gBitSystem->setBrowserTitle$gContent->mInfo['title');
  68. // Display the template
  69. $gBitSmarty->display("bitpackage:blogs/print_blog_post.tpl");
  70.  
  71. ?>

Documentation generated on Wed, 29 Jul 2015 13:57:16 +0000 by phpDocumentor 1.5.0-lsces