[ Index ]
 

Code source de LifeType 1.2.4

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/class/net/ -> customrequestgenerator.class.php (sommaire)

(pas de description)

Poids: 499 lignes (17 kb)
Inclus ou requis:0 fois
Référencé: 1 fois
Nécessite: 0 fichiers

Définit 1 class

CustomRequestGenerator:: (23 méthodes):
  CustomRequestGenerator()
  postPermalink()
  _fillPostParameters()
  getArchiveLink()
  postCommentLink()
  postLink()
  postRssLink()
  categoryLink()
  postUserLink()
  blogLink()
  rssLink()
  categoryRssLink()
  replyCommentLink()
  postTrackbackStatsLink()
  albumLink()
  parentAlbumLink()
  templatePage()
  resourceLink()
  _fillResourceParameters()
  getRequest()
  _replaceTags()
  getCurrentUrl()
  getPageSuffix()


Classe: CustomRequestGenerator  - X-Ref

\ingroup Net

Generates requests using a custom format.

CustomRequestGenerator( $blogInfo = null )   X-Ref
Constructor.

param: blogInfo A BlogInfo object

postPermalink( $post )   X-Ref
Returns the permalink for a post

param: post The Article object
return: The link for the permalink

_fillPostParameters( $post )   X-Ref


getArchiveLink( $date )   X-Ref
generates an archive link given a date.

param: date A String in the format yyyymm
return: A valid archive link

postCommentLink( $post )   X-Ref
Returns the comment link for a post

param: post The Article object
return: The correct string

postLink( $post )   X-Ref
Returns the link for the post

param: post The Article object
return: The link for the post

postRssLink( $post )   X-Ref
Returns the link for the post. This is kind of a dirty trick... :( This is only meant to be
used in the template that generates the rss feed for a blog.

param: post The Article object
return: The link for the post

categoryLink( $category )   X-Ref
Returns the link but given a category. Does the same as postCategoryLink but this time we don't need
a post but an ArticleCategory object.

param: An ArticleCategory object containing the information regarding the category.
return: A string with the correct url pointing to the page that will show only the posts that belong

postUserLink( $user, $category = null )   X-Ref
Returns a link to only the articles of the user

param: user The user whose posts we would like to see
param: category Optionally, we can specify an ArticleCategory object
return: A string containing the right url to only the posts of the user.

blogLink( $blogInfo = null )   X-Ref
Returns the url of the host where the blog is running

return: Returns the url where the blog is running.

rssLink( $profile = "", $blogInfo = null )   X-Ref
Returns the url where the rss feed is running

param: blogInfo A BlogInfo object containing information about the blog.
param: profile The RSS profile we'd like to use. It defaults to none.
return: The url pointing to the rss feed of the journal.

categoryRssLink( $category, $profile = "", $blogInfo = null )   X-Ref
Returns the url for the rss feed of a category

param: category The ArticleCategory object with information about the category
param: blogInfo A BlogInfo object containing information about the blog.
return: The url pointing to the rss feed of the journal.

replyCommentLink( $post, $comment )   X-Ref
Returns the url to reply to a given comment.

param: post An Article object with information about the post
param: commen A UserComment object containing information about the post we'd like to reply to.
return: The right url to reply to this comment.

postTrackbackStatsLink( $post )   X-Ref
Returns the link to the page showing the trackback statistics for a given post.

param: post The post with the information.
return: Returns a string with the valid link.

albumLink( $album = null )   X-Ref
Returns the link to an album

param: album The GalleryAlbum object.
param: page current page

parentAlbumLink( $album )   X-Ref
Given an album, generates a link to its parent. Must be implemented by child classes to generate
a valid URL.

param: album The album

templatePage( $template )   X-Ref
Given the name of a template file, generate the right link to it.

param: template
return: A link to the given template file/static page

resourceLink( $resource )   X-Ref
Returns the link to a resource

param: album Generates the correct link to fetch a resource

_fillResourceParameters( $resource )   X-Ref


getRequest()   X-Ref
Returns a string representing the request

return: A String object representing the request

_replaceTags( $format, $tags )   X-Ref

return: string

getCurrentUrl( $category = null, $userInfo = null, $date = -1 )   X-Ref
given the parameters, recalculates the current URL. This method also has support
for paged urls

param: category
param: userInfo
param: date
param: page
return: the current url with its page

getPageSuffix()   X-Ref
Returns the page format for this URL generator

return: A page suffix



Généré le : Mon Nov 26 21:04:15 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics