OXID eShop CE  4.8.11
 All Classes Files Functions Variables Pages
oxTagCloud Class Reference
+ Inheritance diagram for oxTagCloud:
+ Collaboration diagram for oxTagCloud:

Public Member Functions

 __construct ()
 setProductId ($sProductId)
 getProductId ()
 setLanguageId ($iLangId)
 getLanguageId ()
 setExtendedMode ($blExtended)
 isExtended ()
 setTagList (oxITagList $oTagList)
 getTagList ()
 setCloudArray ($aTagCloudArray)
 getCloudArray ($sProductId=null, $blExtended=null, $iLang=null)
 formCloudArray (oxITagList $oTagList)
 getTagSize ($sTag)
 getMaxAmount ()
 resetTagCache ($iLang=null)
 resetCache ()
 getTags ($sArtId=null, $blExtended=false, $iLang=null)
 prepareTags ($sTags)
 trimTags ($sTags)
 stripMetaChars ($sText)
 getTagMaxLength ()
 getTagLink ($sTag)
 getTagTitle ($sTag)
 canBeTagged ($sTagTitle)
 _fixTagLength ($sTag)
- Public Member Functions inherited from oxSuperCfg
 __call ($sMethod, $aArgs)
 getConfig ()
 setConfig ($oConfig)
 getSession ()
 setSession ($oSession)
 getUser ()
 setUser ($oUser)
 isAdmin ()
 setAdminMode ($blAdmin)

Protected Member Functions

 _getCacheKey ($blExtended, $iLang=null)
 _formCacheKey ($sTagListCacheId=null)
 _getMaxHit ()
 _getTagHitCount ($oTag)
 _getFontSize ($iHit, $iMaxHit)
 _sortTags ($aTags, $iLang=null)

Protected Attributes

 $_sCacheKey = "tagcloud"
 $_iMaxHit = null
 $_aCloudArray = null
 $_blExtended = false
 $_sSeparator = ','
 $_iTagMaxLength = 60
 $_sProductId = null
 $_iLangId = null
 $_aMetaChars = array('+','-','>','<','(',')','~','*','"','\'','\\','[',']','{','}',';',':','.','/','|','!','@','#','$','%','^','&','?','=','`')

Additional Inherited Members

- Static Protected Attributes inherited from oxSuperCfg
static $_oConfig = null
static $_oSession = null
static $_oRights = null
static $_oActUser = null
static $_blIsAdmin = null

Detailed Description

Class dedicateg to tag cloud handling

Definition at line 15 of file oxtagcloud.php.

Constructor & Destructor Documentation

oxTagCloud::__construct ( )

Object constructor. Initializes separator.

Reimplemented from oxSuperCfg.

Definition at line 95 of file oxtagcloud.php.

Member Function Documentation

oxTagCloud::_fixTagLength (   $sTag)

Takes tag string and makes shorter tags longer by adding underscore.

Parameters
string$sTaggiven tag
Deprecated:
since v5.0.3 (2012-01-02), moved to oxArticleTagSet
Returns
string

Definition at line 548 of file oxtagcloud.php.

oxTagCloud::_formCacheKey (   $sTagListCacheId = null)
protected

Returns tag cache key name.

Parameters
string$sTagListCacheIdWhether to display full list
Returns
string formed cache key

Definition at line 583 of file oxtagcloud.php.

oxTagCloud::_getCacheKey (   $blExtended,
  $iLang = null 
)
protected

Returns tag cache key name.

Parameters
bool$blExtendedWhether to display full list
int$iLangpreferred language [optional]
Deprecated:
since v5.0.3 (2012-01-02), use _formCacheKey
Returns
null

Definition at line 571 of file oxtagcloud.php.

oxTagCloud::_getFontSize (   $iHit,
  $iMaxHit 
)
protected

Returns font size value for current occurence depending on max occurence.

Parameters
int$iHithit count
int$iMaxHitmax hits count
Returns
int

Definition at line 623 of file oxtagcloud.php.

oxTagCloud::_getMaxHit ( )
protected

Returns max hit

Returns
int

Definition at line 594 of file oxtagcloud.php.

oxTagCloud::_getTagHitCount (   $oTag)
protected

Returns tag hit count. Used for _getMaxHit array mapping

Parameters
oxTag$oTagtag object
Returns
int

Definition at line 610 of file oxtagcloud.php.

oxTagCloud::_sortTags (   $aTags,
  $iLang = null 
)
protected

Sorts passed tag array. Using MySQL for sorting (to keep user defined ordering way).

Parameters
array$aTagstags to sort
int$iLangpreferred language [optional]
Deprecated:
since v5.0.3 (2012-01-02), Sorting is now done by php.
Returns
array

Definition at line 653 of file oxtagcloud.php.

oxTagCloud::canBeTagged (   $sTagTitle)

Checks if tags was already tagged for the same product

Parameters
string$sTagTitlegiven tag
Deprecated:
since v5.0.3 (2012-01-02), moved to oxArticleTagSet
Returns
bool

Definition at line 532 of file oxtagcloud.php.

oxTagCloud::formCloudArray ( oxITagList  $oTagList)

Returns tag cloud array

Parameters
oxITagList$oTagListTag List
Returns
array

Definition at line 258 of file oxtagcloud.php.

oxTagCloud::getCloudArray (   $sProductId = null,
  $blExtended = null,
  $iLang = null 
)

Returns extended tag cloud array

Parameters
string$sProductIdproduct id [optional]
bool$blExtendedextended cloud array mode [optional]
int$iLanglanguage id [optional]
Returns
array

Definition at line 224 of file oxtagcloud.php.

oxTagCloud::getLanguageId ( )

Returns current tag cloud language id

Deprecated:
since v5.0.3 (2012-01-02), Class is language independent now
Returns
int

Definition at line 150 of file oxtagcloud.php.

oxTagCloud::getMaxAmount ( )

Returns maximum amount of tags, that should be shown in list

Returns
int

Definition at line 311 of file oxtagcloud.php.

oxTagCloud::getProductId ( )

Returns current tag cloud product id (if available)

Deprecated:
since v5.0.3 (2012-01-02), class is now made article independent
Returns
string

Definition at line 124 of file oxtagcloud.php.

oxTagCloud::getTagLink (   $sTag)

Returns tag url (seo or dynamic depends on shop mode)

Parameters
string$sTagtag title
Deprecated:
since v5.0.3 (2012-01-02), moved to oxTag::getLink
Returns
string

Definition at line 502 of file oxtagcloud.php.

oxTagCloud::getTagList ( )

Returns oxITagList object

Returns
oxITagList

Definition at line 197 of file oxtagcloud.php.

oxTagCloud::getTagMaxLength ( )

Returns current maximum tag length

Deprecated:
since v5.0.3 (2012-01-02), use oxTag::getMaxLength
Returns
int

Definition at line 487 of file oxtagcloud.php.

oxTagCloud::getTags (   $sArtId = null,
  $blExtended = false,
  $iLang = null 
)

Returns tag array

Parameters
string$sArtIdarticle id
bool$blExtendedif can extend tags
int$iLangpreferred language [optional]
Deprecated:
since v5.0.3 (2012-01-02), moved to oxtaglist
Returns
array

Definition at line 365 of file oxtagcloud.php.

oxTagCloud::getTagSize (   $sTag)

Returns tag size

Parameters
string$sTagtag title
Returns
int

Definition at line 294 of file oxtagcloud.php.

oxTagCloud::getTagTitle (   $sTag)

Returns html safe tag title

Parameters
string$sTagtag title
Deprecated:
since v5.0.3 (2012-01-02), moved to oxArticleTagSet
Returns
string

Definition at line 517 of file oxtagcloud.php.

oxTagCloud::isExtended ( )

Extended mode getter

Returns
bool

Definition at line 175 of file oxtagcloud.php.

oxTagCloud::prepareTags (   $sTags)

Takes tags string, checks each tag length and makes shorter tags longer if needed. This is needed for FULLTEXT index Also if tag is longer than tag's max length - cuts it.

Parameters
string$sTagsgiven tag
Deprecated:
since v5.0.3 (2012-01-02), moved to oxtag
Returns
string

Definition at line 404 of file oxtagcloud.php.

oxTagCloud::resetCache ( )

Resets tag cache

Returns
null

Definition at line 340 of file oxtagcloud.php.

oxTagCloud::resetTagCache (   $iLang = null)

Resets tag cache

Parameters
int$iLangpreferred language [optional]
Returns
null

Definition at line 327 of file oxtagcloud.php.

oxTagCloud::setCloudArray (   $aTagCloudArray)

Sets tag cloud array

Parameters
array$aTagCloudArraytag cloud array
Returns
void

Definition at line 209 of file oxtagcloud.php.

oxTagCloud::setExtendedMode (   $blExtended)

Tag cloud mode setter (extended or not)

Parameters
bool$blExtendedif true - extended cloud array will be returned
Returns
null

Definition at line 165 of file oxtagcloud.php.

oxTagCloud::setLanguageId (   $iLangId)

Tag cloud language id setter

Parameters
int$iLangIdlanguage id
Deprecated:
since v5.0.3 (2012-01-02), Class is language independent now
Returns
null

Definition at line 138 of file oxtagcloud.php.

oxTagCloud::setProductId (   $sProductId)

Created oxArticleTagSet object and passes it to oxTagCloud::setTagSet

Parameters
string$sProductIdproduct id
Deprecated:
since v5.0.3 (2012-01-02), pass oxITagCloudSet object to oxTagCloud::setTagSet method instead
Returns
null

Definition at line 108 of file oxtagcloud.php.

oxTagCloud::setTagList ( oxITagList  $oTagList)

Sets oxITagList object

Parameters
oxITagList$oTagListTag cloud set object, which implements oxITagList
Returns
bool

Definition at line 187 of file oxtagcloud.php.

oxTagCloud::stripMetaChars (   $sText)

Strips any mysql FULLTEXT specific meta characters.

Parameters
string$sTextgiven text
Deprecated:
since v5.0.3 (2012-01-02), use oxTag::stripMetaChars
Returns
string

Definition at line 467 of file oxtagcloud.php.

oxTagCloud::trimTags (   $sTags)

Trims spaces from tags, removes unnecessary commas, dashes and underscores.

Parameters
string$sTagsgiven tag
Deprecated:
since v5.0.3 (2012-01-02), moved to oxArticleTagSet
Returns
string

Definition at line 439 of file oxtagcloud.php.

Member Data Documentation

oxTagCloud::$_aCloudArray = null
protected

Definition at line 36 of file oxtagcloud.php.

oxTagCloud::$_aMetaChars = array('+','-','>','<','(',')','~','*','"','\'','\\','[',']','{','}',';',':','.','/','|','!','@','#','$','%','^','&','?','=','`')
protected

Definition at line 90 of file oxtagcloud.php.

oxTagCloud::$_blExtended = false
protected

Definition at line 43 of file oxtagcloud.php.

oxTagCloud::$_iLangId = null
protected

Definition at line 80 of file oxtagcloud.php.

oxTagCloud::$_iMaxHit = null
protected

Definition at line 29 of file oxtagcloud.php.

oxTagCloud::$_iTagMaxLength = 60
protected

Definition at line 62 of file oxtagcloud.php.

oxTagCloud::$_sCacheKey = "tagcloud"
protected

Definition at line 22 of file oxtagcloud.php.

oxTagCloud::$_sProductId = null
protected

Definition at line 71 of file oxtagcloud.php.

oxTagCloud::$_sSeparator = ','
protected

Definition at line 52 of file oxtagcloud.php.


The documentation for this class was generated from the following file: