Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes

FrontendController Class Reference

Frontend base class (Frontend API). More...

Inheritance diagram for FrontendController:
AppController ApiBaseController

List of all members.

Public Member Functions

 login ($backName=null)
 show login form or redirect if user is already logged
 logout ($autoRedirect=true)
 perform logout operation
 homePage ()
 find first active section and load it as home page section if any section was found load publication as home page section
 sitemapXml ()
 prepare an XML containing sitemap specification view in bedita-app/views/pages/sitemap_xml.tpl
 sitemap ($xml_out=false)
 build array for sitemap
 rss ($sectionName)
 Publish RSS feed with contents inside section $sectionName Use callback controller methods (if defined):

  • $sectionName.

 kml ($sectionName)
 output a kml defined by a section
 georssatom ($sectionName)
 output a georss atom representation of section
 georss ($sectionName)
 output a georss representation of section
 json ($name)
 output a json object of returned array by section or content method
 xml ($name)
 output an xml of returned array by section or content method
 xmlobject ($name)
 output an xml of returned array by loadObj/loadObjByNick method
 loadObjByNick ($obj_nick, $blockAccess=true)
 Like loadObj using nickname.
 loadObj ($obj_id, $blockAccess=true, $options=array())
 Returns bedita Object Throws Exception on errors.
 loadSectionObjectsByNick ($parentNick, $options=array())
 Load objects in section $parentNick.
 loadSectionObjects ($parent_id, $options=array())
 Load objects in section $parent_id.
 content ($name)
 find first section that contain content ($name) then call section method
 section ($secName, $contentName=null)
 find section and contents from section nick or section id and set template vars
 route ()
 Set section canonical path and set parent array in $section array.
 search ()
 search inside history
 subscribe ($what="newsletter")
 public subscribe page, used for newsletter/frontend subscribe/unsubscribe
 hashjob ($service_type=null, $hash=null)
 manage hash request like newsletter/frontend subscribe/unsubscribe
 loadTags ($tplVar=null, $cloud=true, $shuffle=false, $tagShowed=null)
 load all tag
 tag ($name)
 find all objects tagged by $name and set results for view
 category ($name)
 find all objects for category $name and set results for view
 download ($name)
 force download of media object
 captchaImage ()
 show image for captcha
 saveComment ()
 save comment relative to an object, set 'info' flash message throw Exception in case of error and set 'error' flash message
 printme ($id=null, $printLayout=null)
 show an object in print mode with specific layout and view CakePHP layout: print (if dosen't exists in frontend app use backend print layout) use print view if not set a specific $printLayout
 getStatus ()
 return class attribute $status
 manifestAppcache ()
 dynamic manifest if Configure::read("debug") === 0 (production env) the manifest is cached by CakePHP else (development env) the manifest is generated every time
 getPublication ()
 Return the current frontend publication.

Static Public Member Functions

static handleExceptions (Exception $ex)
 handle Exceptions

Public Attributes

const UNLOGGED = "unlogged"
const UNAUTHORIZED = "unauthorized"

Protected Member Functions

 checkLogin ()
 set FrontendController::logged private attribute
 accessDenied ($type)
 manage access denied.
 isLogged ()
 get private logged var
 initAttributes ()
 called before action to initialize $uses & $components array don't work...
 publicationDisabled ($status)
 Render off.tpl (or draft.tpl) layout when publication is disabled (off or draft).
 checkPublicationPermissions ()
 setupLocale ()
 override AppController::setupLocale.
 lang ($lang)
 change language
 checkPubblicationDate (array $obj)
 check if current date is compatible with required pubblication dates (start/end date)
 loadSectionsTree ($parentName, $loadContents=false, $exclude_nicknames=array(), $depth=null, $flatMode=false)
 Get tree starting from specified section or area.
 setCanonicalPath (array &$obj)
 Set canonical path in object data array, check parent authorization

  • $obj["canonicalPath"] will contain new caclulated canonical path
  • update $this->objectCache
  • setup $obj["parentAuthorized"]
  • setup $obj["pathSection"] for sections.

 loadSectionsLevels ($secName, $loadContents=false, array $exclude_nicknames=null)
 Get sections levels.
 loadPublications ($tplVar=null)
 load all publications
 buildRssItem (array &$obj, $canonicalPath=null)
 Build a single RSS item from a BE object array If section "canonicalPath" is set, links are created with it If not: use object canonicalPath if present, otherwise object unique name (nickname).
 loadAndSetObjByNick ($obj_nick, $var_name=null, $blockAccess=true)
 Like loadAndSetObj using nickname.
 loadAndSetObj ($obj_id, $var_name=null, $blockAccess=true)
 Load bedita Object and set view var with $var_name or object type (e.g.
 loadAndSetSectionObjects ($parent_id, $options=array())
 Load objects in section $parent_id and set in view vars an array for each object type (e.g.
 loadAndSetSectionObjectsByNick ($parentNick, $options=array())
 Load objects in section $parentNick and set in view vars an array for each object type.
 loadRelatedObjects ($id, $relation, $options)
 Load paginated collection of objects related to object $id by $relation.
 setPublicationDateFilter (array &$filter)
 Add to $filter the rules relative to publication date In detail:

  • add rule to 'start_date'
  • add rule to 'end_date'.

 getPath ($object_id)
 find parent path of $object_id (excluded publication)
 getParentsObject ($object_id)
 get array of parents that contain the object specified by $object_id
 loadArchiveTree ($secName, $options=array())
 build archive tree
 loadObjectsByCategory ($categoryName, $options=array())
 return objects for a specific category
 loadObjectsByTag ($tag, $options=array())
 return objects for a specific tag
 loadAnnotations ($annotationType, $objectName, $options=array())
 load annotation referenced to some object
 save ($modelName=null)
 save a BEdita object.
 delete ()
 delete a BEdita object.
 showDraft ()
 add "draft" status to class attribute $status

Protected Attributes

 $checkPubDate = array("start" => true, "end" => true)
 $baseLevel = false
 $sectionOptions = array("showAllContents" => true, "itemsByType" => false, "childrenParams" => array())
 $xmlFormat = "attributes"
 $publication = ""
 $captchaOptions = array()
 $annotationOptions = array("comment" => array())
 $objectCache = array()
 $tagOptions = array()
 $searchOptions
 $logged = false
 $loginRedirect = "/"
 $logoutRedirect = "/"
 $showUnauthorized = false
 $defaultBindingLevel = 'frontend'

Detailed Description

Frontend base class (Frontend API).

Definition at line 29 of file frontend_controller.php.


Member Function Documentation

FrontendController::accessDenied ( type  )  [protected]

manage access denied.

If you want another behavior override it in pages_controller

user unlogged: render login view (if user doesn't arrive from login page set info message) user unauthorized to access that item: render unauthorized view (set error message)

for other custom type will try to render a view with $type name (i.e. $type="access_denied" render views/pages/access_denied.[tpl|ctp] template)

Parameters:
string $type, which type of access denied
Exceptions:
BeditaFrontAccessException 

Definition at line 271 of file frontend_controller.php.

Referenced by getPath(), login(), rss(), section(), and xmlobject().

FrontendController::buildRssItem ( array &$  obj,
canonicalPath = null 
) [protected]

Build a single RSS item from a BE object array If section "canonicalPath" is set, links are created with it If not: use object canonicalPath if present, otherwise object unique name (nickname).

Parameters:
array $obj
string $canonicalPath
Returns:
array

Definition at line 1013 of file frontend_controller.php.

Referenced by rss().

FrontendController::captchaImage (  ) 

show image for captcha

Definition at line 2656 of file frontend_controller.php.

FrontendController::category ( name  ) 

find all objects for category $name and set results for view

Parameters:
string $name

Definition at line 2399 of file frontend_controller.php.

References loadObjectsByCategory().

FrontendController::checkLogin (  )  [protected]

set FrontendController::logged private attribute

check if there's an active session and try to login if user not logged

  • if "authorizedGroups" array defined in frontend.ini.php, user has to be in one of those groups
  • if "staging" is defined only backend authorized groups are permitted
    • otherwise any group is accepted
Returns:
mixed

Reimplemented from AppController.

Reimplemented in ApiBaseController.

Definition at line 177 of file frontend_controller.php.

References AppController::eventInfo(), and AppController::userErrorMessage().

FrontendController::checkPubblicationDate ( array $  obj  )  [protected]

check if current date is compatible with required pubblication dates (start/end date)

Parameters:
array $obj
Returns:
boolean, true if content may be published, false otherwise

Definition at line 493 of file frontend_controller.php.

Referenced by loadObj().

FrontendController::content ( name  ) 

find first section that contain content ($name) then call section method

Parameters:
string|id $name, id or content nickname

Definition at line 1756 of file frontend_controller.php.

References section().

FrontendController::delete (  )  [protected]

delete a BEdita object.

User has to be logged

Returns:
boolean

Definition at line 2847 of file frontend_controller.php.

FrontendController::download ( name  ) 

force download of media object

Parameters:
$name id or object nickname
Exceptions:
BeditaBadRequestException,BeditaNotFoundException 

Definition at line 2581 of file frontend_controller.php.

FrontendController::georss ( sectionName  ) 

output a georss representation of section

Parameters:
string $sectionName

Definition at line 1053 of file frontend_controller.php.

References section().

FrontendController::georssatom ( sectionName  ) 

output a georss atom representation of section

Parameters:
string $sectionName

Definition at line 1043 of file frontend_controller.php.

References section().

FrontendController::getParentsObject ( object_id  )  [protected]

get array of parents that contain the object specified by $object_id

Parameters:
integer $object_id
Returns:
array

Definition at line 2256 of file frontend_controller.php.

References loadObj().

FrontendController::getPath ( object_id  )  [protected]

find parent path of $object_id (excluded publication)

Parameters:
int $object_id
Returns:
array (the keys are object's id)

Definition at line 2175 of file frontend_controller.php.

References accessDenied(), getStatus(), loadObj(), and AppController::modelBindings().

Referenced by setCanonicalPath().

FrontendController::getPublication (  ) 

Return the current frontend publication.

Returns:
array

Definition at line 2957 of file frontend_controller.php.

Referenced by ApiBaseController::getObjects().

FrontendController::getStatus (  ) 

return class attribute $status

Returns:
array

Definition at line 2910 of file frontend_controller.php.

Referenced by ApiBaseController::getObjectsSiblings(), getPath(), and ApiBaseController::saveObject().

static FrontendController::handleExceptions ( Exception $  ex  )  [static]

handle Exceptions

Deprecated:
Parameters:
Exception $ex
Returns:
AppError

Definition at line 513 of file frontend_controller.php.

FrontendController::hashjob ( service_type = null,
hash = null 
)

manage hash request like newsletter/frontend subscribe/unsubscribe

Parameters:
string $service_type
string $hash
Returns:
void
Exceptions:
BeditaInternalErrorException 

Definition at line 2154 of file frontend_controller.php.

References AppController::eventError(), and AppController::userErrorMessage().

FrontendController::initAttributes (  )  [final, protected]

called before action to initialize $uses & $components array don't work...

(abstract class ??)

Exceptions:
BeditaPublicationException 
See also:
bedita-app/AppControllerinitAttributes()

Reimplemented from AppController.

Definition at line 296 of file frontend_controller.php.

References loadObj(), and publicationDisabled().

FrontendController::isLogged (  )  [protected]

get private logged var

Returns:
boolean

Definition at line 285 of file frontend_controller.php.

Referenced by login().

FrontendController::json ( name  ) 

output a json object of returned array by section or content method

Parameters:
string $name
Returns:
string|int $name, nickname or id

Definition at line 1117 of file frontend_controller.php.

References route().

FrontendController::kml ( sectionName  ) 

output a kml defined by a section

Parameters:
string $sectionName

Definition at line 1032 of file frontend_controller.php.

References section().

FrontendController::lang ( lang  )  [protected]

change language

Parameters:
string $lang
Exceptions:
BeditaException 

Definition at line 464 of file frontend_controller.php.

References setupLocale().

Referenced by route().

FrontendController::loadAndSetObj ( obj_id,
var_name = null,
blockAccess = true 
) [protected]

Load bedita Object and set view var with $var_name or object type (e.g.

"Document", "Event"..) Returns object loaded Throws Exception on errors

Parameters:
int $obj_id
string $var_name view var name
boolean $blockAccess see FrontendController::loadObj()
Returns:
array

Definition at line 1212 of file frontend_controller.php.

References loadObj().

Referenced by loadAndSetObjByNick(), and route().

FrontendController::loadAndSetObjByNick ( obj_nick,
var_name = null,
blockAccess = true 
) [protected]

Like loadAndSetObj using nickname.

Parameters:
string $obj_nick
string $var_name view var name
boolean $blockAccess see FrontendController::loadObj()
Returns:
array

Definition at line 1198 of file frontend_controller.php.

References loadAndSetObj().

FrontendController::loadAndSetSectionObjects ( parent_id,
options = array() 
) [protected]

Load objects in section $parent_id and set in view vars an array for each object type (e.g.

in view you will have $Document => array(0 => ..., 1 => ...) $Event" => array(0 => ..., 1 => ...) )

Parameters:
int $parent_id
array $options, filter and pagination options

Definition at line 1495 of file frontend_controller.php.

References loadSectionObjects().

FrontendController::loadAndSetSectionObjectsByNick ( parentNick,
options = array() 
) [protected]

Load objects in section $parentNick and set in view vars an array for each object type.

Parameters:
string $parentNick
array $options, filter and pagination options

Definition at line 1508 of file frontend_controller.php.

References loadSectionObjectsByNick().

FrontendController::loadAnnotations ( annotationType,
objectName,
options = array() 
) [protected]

load annotation referenced to some object

Parameters:
string $annotationType, object type of the annotation e.g. "comment"
string $objectName, reference object nickname or id
array $options, specific options (pagination, filter) that override annotationOptions attribute
Returns:
array of annotations

Definition at line 2546 of file frontend_controller.php.

FrontendController::loadArchiveTree ( secName,
options = array() 
) [protected]

build archive tree

Array( "Document" => Array( "2008" => Array( "01" => Array( 0 => document, 1 => document, ... "monthName" => month name "total" => number of document in january ), "02" => Array(...), .... "total" => numeber of document in 2008 ), "2007" => Array(...), "ShortNews" => .... )

Parameters:
string $secName section id or section nickname
Returns:
array

Definition at line 2289 of file frontend_controller.php.

References loadSectionObjects(), and AppController::modelBindings().

FrontendController::loadObj ( obj_id,
blockAccess = true,
options = array() 
)

Returns bedita Object Throws Exception on errors.

Parameters:
int $obj_id
boolean $blockAccess if it's set a "frontend_access_without_block" permission on the object this param is ignored and the object returned (array) will have a key named "authorized" set to true or false depending on whether the user has permission to access at the object else if it's set a "frontend_access_with_block" permission on the object true => if user is unlogged return UNLOGGED constant if user is logged and he hasn't permission to access at the object return UNAUTHORIZED constant false => if user unlogged dosen't block the action and the object returned (array) will have a key named "authorized" set to false if user is logged but not authorized the object returned (array)
array $options a set of options for the method:

  • bindingLevel: the requested model binding level to use
  • explodeRelations: true (default) to explode the objects related. The main object model bindings set have to contain 'RelatedObject' association

note: if FrontendController::showUnauthorized is set to true and the user is logged then all unauthorized object will have set "authorized" to false regardless object permission

Returns:
array object detail

Deprecated:
block. Kept for backward compatibility with 3.1 version use "customProperties" for a more readable array of custom properties

end

Deprecated:
block

Definition at line 1247 of file frontend_controller.php.

References checkPubblicationDate(), AppController::objectRelationArray(), AppController::setObjectBindings(), and AppController::setupAnnotations().

Referenced by ApiBaseController::getObjects(), getParentsObject(), getPath(), initAttributes(), loadAndSetObj(), loadObjByNick(), loadPublications(), loadRelatedObjects(), loadSectionObjects(), loadSectionsLevels(), loadSectionsTree(), rss(), section(), and xmlobject().

FrontendController::loadObjByNick ( obj_nick,
blockAccess = true 
)

Like loadObj using nickname.

Parameters:
string $obj_nick
boolean $blockAccess see FrontendController::loadObj()
Returns:
array

Definition at line 1186 of file frontend_controller.php.

References loadObj().

Referenced by rss(), and xmlobject().

FrontendController::loadObjectsByCategory ( categoryName,
options = array() 
) [protected]

return objects for a specific category

Parameters:
string $category category name (friendly url/unique name)
array $options search options "section" => name or id section "filter" => particular filter "order", "dir", "dim", "page" used like pagination parameters, "baseLevel" => true to use $this->baseLevel = true for model bindings
Returns:
array

Definition at line 2414 of file frontend_controller.php.

Referenced by category().

FrontendController::loadObjectsByTag ( tag,
options = array() 
) [protected]

return objects for a specific tag

Parameters:
string $tag tag name (friendly url/unique name)
array $options search options "section" => name or id section "filter" => particular filter "order", "dir", "dim", "page" used like pagination parameters "baseLevel" => true to use $this->baseLevel = true for model bindings
Returns:
array

Definition at line 2534 of file frontend_controller.php.

Referenced by tag().

FrontendController::loadPublications ( tplVar = null  )  [protected]

load all publications

Parameters:
string $tplVar, var name for template. If not defined result will be set to "publicationsList" var

Definition at line 796 of file frontend_controller.php.

References loadObj().

FrontendController::loadRelatedObjects ( id,
relation,
options 
) [protected]

Load paginated collection of objects related to object $id by $relation.

$option can be used to customize the objects searched. Possible values are:

  • filter: additional filter to add to search
  • order: field used to sort collection (default 'priority')
  • dir: the sorting algorithm. true (default) for ASC, false for DESC
  • page: the page to show
  • dim: the dimension of the page
  • explodeRelations: explode the relations of related objects (default true for compatibility with self::loadSectionObjects()) or not
Parameters:
int $id the main object id
string $relation the relation name
array $options
Returns:
array

Definition at line 1653 of file frontend_controller.php.

References loadObj(), and setPublicationDateFilter().

Referenced by ApiBaseController::addRelatedObjects(), and ApiBaseController::getObjectsRelations().

FrontendController::loadSectionObjects ( parent_id,
options = array() 
)

Load objects in section $parent_id.

Parameters:
int $parent_id
array $options, filter, pagination and other options
Returns:
array

Definition at line 1535 of file frontend_controller.php.

References loadObj(), setCanonicalPath(), and setPublicationDateFilter().

Referenced by loadAndSetSectionObjects(), loadArchiveTree(), loadSectionObjectsByNick(), loadSectionsLevels(), loadSectionsTree(), ApiBaseController::responseChildren(), rss(), section(), and sitemap().

FrontendController::loadSectionObjectsByNick ( parentNick,
options = array() 
)

Load objects in section $parentNick.

Parameters:
string $parentNick
array $options, filter and pagination options
Returns:
array

Definition at line 1523 of file frontend_controller.php.

References loadSectionObjects().

Referenced by loadAndSetSectionObjectsByNick().

FrontendController::loadSectionsLevels ( secName,
loadContents = false,
array $  exclude_nicknames = null 
) [protected]

Get sections levels.

Find all ancestors from secName and build an array of levels Each key in array returned is a level: 0 is the first level 1 is the second level etc...

set selected = true in a section if it's an ancestor (parent) of $secName

Parameters:
string $secName nickname or section id
boolean $loadContents true meaning it loads all contents of each section
array $exclude_nicknames list exclude sections
Returns:
array of level selected

Definition at line 749 of file frontend_controller.php.

References loadObj(), and loadSectionObjects().

FrontendController::loadSectionsTree ( parentName,
loadContents = false,
exclude_nicknames = array(),
depth = null,
flatMode = false 
) [protected]

Get tree starting from specified section or area.

Parameters:
string|int $parentName parent nickname or id
boolean $loadContents if it's true load all contents too. Default false
array $exclude_nicknames list exclude sections
int $depth tree's depth level (default=null => all levels)
Returns:
array

Definition at line 602 of file frontend_controller.php.

References loadObj(), loadSectionObjects(), and setCanonicalPath().

FrontendController::loadTags ( tplVar = null,
cloud = true,
shuffle = false,
tagShowed = null 
)

load all tag

Parameters:
string $tplVar
boolean $cloud, if true set 'class' key (possible value: smallestTag, largestTag, largeTag, mediumTag, smallTag)
boolean $shuffle, if true shuffle the tags else order by label
int $tagShowed, define how much tags have to be returned (null = all tags)

Definition at line 2367 of file frontend_controller.php.

FrontendController::login ( backName = null  ) 

show login form or redirect if user is already logged

Parameters:
string $backName nickname or id of section to go after login

Definition at line 238 of file frontend_controller.php.

References accessDenied(), and isLogged().

FrontendController::logout ( autoRedirect = true  ) 

perform logout operation

Parameters:
boolean $autoRedirect

Definition at line 251 of file frontend_controller.php.

References AppController::eventInfo().

FrontendController::printme ( id = null,
printLayout = null 
)

show an object in print mode with specific layout and view CakePHP layout: print (if dosen't exists in frontend app use backend print layout) use print view if not set a specific $printLayout

Parameters:
int $id
string $printLayout, the view template to use

Definition at line 2786 of file frontend_controller.php.

FrontendController::publicationDisabled ( status  )  [protected]

Render off.tpl (or draft.tpl) layout when publication is disabled (off or draft).

Parameters:
string $status the status to render
Returns:
void

Definition at line 372 of file frontend_controller.php.

Referenced by initAttributes().

FrontendController::route (  ) 

Set section canonical path and set parent array in $section array.

Parameters:
array $section
int $sectionId
Returns:
boolean false if some parent sections is unauthorized for user Route to section, content or another method following these rules: 0. if urls begin with `lang/XYZ` and `XYZ` is a valid frontend language, switches to that language and continues routing. Please note that in order for this to work, your frontend should implement an additional route: `Routerconnect('/lang/:lang/*', array('controller' => 'pages', 'action' => 'route'), array('lang' => '[a-z]{3}', 'persist' => 'lang'));` 1. if there aren't url arguments (i.e. /) => uses homePage reserved word 2. if first url argument is a reserved words defined in configuration var 'defaultReservedWords' and 'cfgReservedWords' => try to call the method itself 3. if first url argument is a method of current controller => try to call the method itself 4. if first url argugment is a valid nickname and there is a method of current Controller with the name defined in BeLib::variableFromNickname => try to call the method itself example: www.example.com/my-nickname => calls PagesController::myNickname() method if it exists 5. if first url argument is a valid nickname => calls the appropriate FrontendController::section() or FrontendController::content() method 6. throw exception and 404 http error
Exceptions:
BeditaBadRequestException,BeditaNotFoundException 

Reimplemented in ApiBaseController.

Definition at line 1990 of file frontend_controller.php.

References lang(), and loadAndSetObj().

Referenced by json(), and xml().

FrontendController::rss ( sectionName  ) 

Publish RSS feed with contents inside section $sectionName Use callback controller methods (if defined):

  • $sectionName.

"RssChannel" to fetch channel data

  • $sectionName."RssItems" to fetch rss items

If callbacks methods are not defined (default) load section and object data and build rss data with defaults

Parameters:
string $sectionName, section's nickname/unique name

Definition at line 938 of file frontend_controller.php.

References accessDenied(), buildRssItem(), loadObj(), loadObjByNick(), loadSectionObjects(), and setCanonicalPath().

FrontendController::save ( modelName = null  )  [protected]

save a BEdita object.

User has to be logged

Parameters:
string $modelName (Document, Event, ....). If undefined get object type from $this->data["object_type_id"]
Returns:
mixed int|boolean, false on error, object_id saved on success

Definition at line 2811 of file frontend_controller.php.

FrontendController::saveComment (  ) 

save comment relative to an object, set 'info' flash message throw Exception in case of error and set 'error' flash message

If it's ajax request and if not empty $this->params["form"]["render"] renders it

elseif it's not ajax request then redirect to referer

Exceptions:
BeditaException 

Definition at line 2677 of file frontend_controller.php.

FrontendController::section ( secName,
contentName = null 
)

find section and contents from section nick or section id and set template vars

Set section and: if $contentName=null set all contents in section if $contentName is defined set single content if $contentName is defined and $this->showAllContents=true set content and other contents too (default)

Execute 'sectionNickname'BeforeFilter and/or 'sectionNickName'BeforeRender if they're set in the controller (i.e. pages_controller.php)

Parameters:
string/int $secName: section nick or section id
string/int $contentName: content nick or content id

Definition at line 1799 of file frontend_controller.php.

References accessDenied(), loadObj(), loadSectionObjects(), and setCanonicalPath().

Referenced by content(), georss(), georssatom(), homePage(), and kml().

FrontendController::setCanonicalPath ( array &$  obj  )  [protected]

Set canonical path in object data array, check parent authorization

  • $obj["canonicalPath"] will contain new caclulated canonical path
  • update $this->objectCache
  • setup $obj["parentAuthorized"]
  • setup $obj["pathSection"] for sections.

Parameters:
array $obj, containing at least "id" and "nickname"

Definition at line 681 of file frontend_controller.php.

References getPath().

Referenced by loadSectionObjects(), loadSectionsTree(), rss(), and section().

FrontendController::setupLocale (  )  [protected]

override AppController::setupLocale.

Used setup specific locale

See also:
bedita-app/AppControllersetupLocale()

Reimplemented from AppController.

Definition at line 401 of file frontend_controller.php.

Referenced by lang().

FrontendController::sitemap ( xml_out = false  ) 

build array for sitemap

Parameters:
boolean $xml_out
Returns:
array

Definition at line 854 of file frontend_controller.php.

References loadSectionObjects().

Referenced by sitemapXml().

FrontendController::subscribe ( what = "newsletter"  ) 

public subscribe page, used for newsletter/frontend subscribe/unsubscribe

Parameters:
string $what

Definition at line 2129 of file frontend_controller.php.

FrontendController::tag ( name  ) 

find all objects tagged by $name and set results for view

Parameters:
string $name

Definition at line 2390 of file frontend_controller.php.

References loadObjectsByTag().

FrontendController::xml ( name  ) 

output an xml of returned array by section or content method

passing a "format" named parameters in the url obtain an xml "attributes" format or an xml "tags" format i.e. http://www.example.com/xml/nickname/format:tags output a tag style xml default is defined by class attribute xmlFormat

Parameters:
string|int $name, nickname or id

Definition at line 1132 of file frontend_controller.php.

References route().

FrontendController::xmlobject ( name  ) 

output an xml of returned array by loadObj/loadObjByNick method

passing a "format" named parameters in the url obtain an xml "attributes" format or an xml "tags" format i.e. http://www.example.com/xmlobject/nickname/format:tags output a tag style xml default is defined by class attribute xmlFormat

Parameters:
string|int $name, nickname or id

Definition at line 1150 of file frontend_controller.php.

References accessDenied(), loadObj(), and loadObjByNick().


Member Data Documentation

FrontendController::$searchOptions [protected]
Initial value:
 array(
        'order' => false,
        'dir' => 1,
        'dim' => 50,
        'page' => 1,
        'filter' => array()
    )

Definition at line 116 of file frontend_controller.php.


The documentation for this class was generated from the following file:
Generated on Fri Dec 11 2015 15:29:47 by Doxygen 1.7.1  BEditaBEdita 3.7 Corylus