Overview

Namespaces

  • None
  • Xmf
    • Database
    • Module
      • Helper
    • Template
  • Xoops
    • Auth
    • Core
      • Cache
      • Database
        • Logging
        • Schema
      • Exception
      • Handler
        • Scheme
      • Kernel
        • Dtype
        • Handlers
        • Model
      • Lists
      • Locale
        • Punic
      • Service
        • Contract
      • Session
      • Text
        • Sanitizer
          • Extensions
      • Theme
        • Plugins
    • Form
    • Html
    • Locale
    • Module
      • Helper
      • Plugin

Classes

  • ArtObject
  • ArtObjectHandler
  • Avatars
  • AvatarsAvatar
  • AvatarsAvatar_userForm
  • AvatarsAvatarForm
  • AvatarsAvatarHandler
  • AvatarsLocale
  • AvatarsLocaleEn_US
  • AvatarsPreload
  • AvatarsProvider
  • AvatarsUserlink
  • AvatarsUserlinkHandler
  • AwesomeButton
  • BannerRender
  • Banners
  • BannersBanner
  • BannersBannerclient
  • BannersBannerclientForm
  • BannersBannerclientHandler
  • BannersBannerForm
  • BannersBannerHandler
  • BannersPreload
  • BloggerApi
  • CodexMenusPlugin
  • CodexSearchPlugin
  • CodexSystemPlugin
  • CodexUserconfigsPlugin
  • Comments
  • CommentsComment
  • CommentsCommentForm
  • CommentsCommentHandler
  • CommentsCommentRenderer
  • CommentsPreload
  • CommentsSystemPlugin
  • CommentsUserconfigsPlugin
  • Cookie
  • CountryFlagProvider
  • Criteria
  • CriteriaCompo
  • CriteriaElement
  • DebugbarLogger
  • DebugbarPreload
  • DebugbarUserconfigsPlugin
  • DefaultThemeLocale
  • DefaultThemeLocaleEn_US
  • FormDhtmlTextArea
  • FormTextArea
  • GravatarsPreload
  • GravatarsProvider
  • htmLawed
  • HtmlToPdfProvider
  • imageLib
  • Images
  • ImagesCategory
  • ImagesCategory_imagemanagerForm
  • ImagesCategoryForm
  • ImagesCategoryHandler
  • ImagesCategoryselectForm
  • ImagesImage
  • ImagesImage_Body
  • ImagesImage_imagemanagerForm
  • ImagesImagebody
  • ImagesImagebodyHandler
  • ImagesImageForm
  • ImagesImageHandler
  • ImagesPreload
  • JUpload
  • LegacyLogger
  • LoggerPreload
  • LoggerUserconfigsPlugin
  • Maintenance
  • MaintenanceMaintenanceForm
  • Menus
  • MenusBuilder
  • MenusConstantDecorator
  • MenusDecorator
  • MenusDecoratorAbstract
  • MenusDefaultDecorator
  • MenusDynamicDecorator
  • MenusMenu
  • MenusMenuHandler
  • MenusMenus
  • MenusMenus_menuForm
  • MenusMenus_menusForm
  • MenusMenusHandler
  • MenusPreload
  • MenusSmartyDecorator
  • MetaWeblogApi
  • MonologLogger
  • MonologPreload
  • MonologUserconfigsPlugin
  • MovableTypeApi
  • MyTextSanitizer
  • MyTextSanitizerExtended
  • Notifications
  • NotificationsNotification
  • NotificationsNotificationHandler
  • NotificationsPreload
  • NotificationsSystemPlugin
  • Page
  • PageCommentsPlugin
  • PageGroupPermHandler
  • PageLocale
  • PageLocaleEn_US
  • PageNotificationsPlugin
  • PagePage_content
  • PagePage_contentForm
  • PagePage_contentHandler
  • PagePage_rating
  • PagePage_ratingHandler
  • PagePage_related
  • PagePage_related_link
  • PagePage_related_linkHandler
  • PagePage_relatedForm
  • PagePage_relatedHandler
  • PagePreload
  • PageSearchPlugin
  • PageSystemPlugin
  • PdfPreload
  • PmMessage
  • PmMessageHandler
  • PmPreload
  • ProfileCategory
  • ProfileCategoryForm
  • ProfileCategoryHandler
  • ProfileCorePreload
  • ProfileField
  • ProfileFieldForm
  • ProfileFieldHandler
  • ProfileMenusPlugin
  • ProfileProfile
  • ProfileProfileHandler
  • ProfileRegstep
  • ProfileRegstepForm
  • ProfileRegstepHandler
  • ProfileVisibility
  • ProfileVisibilityHandler
  • Protector
  • protector_bruteforce_overrun_message
  • protector_crawler_overrun_message
  • protector_f5attack_overrun_message
  • protector_postcommon_post_deny_by_httpbl
  • protector_postcommon_post_deny_by_rbl
  • protector_postcommon_post_htmlpurify4everyone
  • protector_postcommon_post_htmlpurify4guest
  • protector_postcommon_post_need_multibyte
  • protector_postcommon_post_register_moratorium
  • protector_postcommon_register_insert_js_check
  • protector_precommon_badip_errorlog
  • protector_precommon_badip_message
  • protector_precommon_badip_redirection
  • protector_precommon_bwlimit_errorlog
  • protector_precommon_bwlimit_message
  • protector_prepurge_exit_message
  • protector_spamcheck_overrun_message
  • ProtectorCenterForm
  • ProtectorCorePreload
  • ProtectorFilterAbstract
  • ProtectorFilterHandler
  • ProtectorMySQLDatabase
  • Publisher
  • PublisherBlockForm
  • PublisherCategory
  • PublisherCategoryForm
  • PublisherCategoryHandler
  • PublisherCommentsPlugin
  • PublisherFile
  • PublisherFileForm
  • PublisherFileHandler
  • PublisherFormDateTime
  • PublisherGroupPermHandler
  • PublisherItem
  • PublisherItemForm
  • PublisherItemHandler
  • PublisherMenusPlugin
  • PublisherMetagen
  • PublisherMimetype
  • PublisherMimetypeHandler
  • PublisherNotificationsPlugin
  • PublisherPermissionHandler
  • PublisherPreload
  • PublisherRating
  • PublisherRatingHandler
  • PublisherSearchPlugin
  • PublisherSystemPlugin
  • PublisherUtils
  • QrcodePreload
  • QrcodeProvider
  • ReCaptchaResponse
  • RpcArrayHandler
  • RpcBase64Handler
  • RpcBooleanHandler
  • RpcDateTimeHandler
  • RpcDoubleHandler
  • RpcIntHandler
  • RpcMemberHandler
  • RpcMethodNameHandler
  • RpcNameHandler
  • RpcStringHandler
  • RpcStructHandler
  • RpcValueHandler
  • RssAuthorHandler
  • RssCategoryHandler
  • RssChannelHandler
  • RssCommentsHandler
  • RssCopyrightHandler
  • RssDescriptionHandler
  • RssDocsHandler
  • RssGeneratorHandler
  • RssGuidHandler
  • RssHeightHandler
  • RssImageHandler
  • RssItemHandler
  • RssLanguageHandler
  • RssLastBuildDateHandler
  • RssLinkHandler
  • RssManagingEditorHandler
  • RssNameHandler
  • RssPubDateHandler
  • RssSourceHandler
  • RssTextInputHandler
  • RssTitleHandler
  • RssTtlHandler
  • RssUrlHandler
  • RssWebMasterHandler
  • RssWidthHandler
  • SaxParser
  • Search
  • SearchPreload
  • SearchSearchForm
  • Smarty_Resource_Admin
  • Smarty_Resource_Block
  • Smarty_Resource_Db
  • Smarty_Resource_Module
  • Smilies
  • SmiliesPreload
  • SmiliesProvider
  • SmiliesSmiley
  • SmiliesSmileyHandler
  • SmiliesSmiliesForm
  • Snoopy
  • SqlUtility
  • System
  • SystemBlockForm
  • SystemBreadcrumb
  • SystemExtension
  • SystemGroupForm
  • SystemLocale
  • SystemLocaleEn_US
  • SystemMenuHandler
  • SystemModule
  • SystemPreferencesForm
  • SystemPreload
  • SystemUserForm
  • tar
  • ThemeSetAuthorHandler
  • ThemeSetDateCreatedHandler
  • ThemeSetDescriptionHandler
  • ThemeSetEmailHandler
  • ThemeSetFileTypeHandler
  • ThemeSetGeneratorHandler
  • ThemeSetImageHandler
  • ThemeSetLinkHandler
  • ThemeSetModuleHandler
  • ThemeSetNameHandler
  • ThemeSetTagHandler
  • ThemeSetTemplateHandler
  • Thumbs
  • ThumbsPreload
  • ThumbsProvider
  • TinyMCE
  • Userconfigs
  • UserconfigsConfigHandler
  • UserconfigsConfigsForm
  • UserconfigsItem
  • UserconfigsItemHandler
  • UserconfigsMenusPlugin
  • UserconfigsModulesForm
  • UserconfigsOption
  • UserconfigsOptionHandler
  • UserconfigsPreload
  • UserconfigsSystemPlugin
  • UserrankPreload
  • UserRankProvider
  • UserrankRank
  • UserrankRankHandler
  • UserrankRanksForm
  • Xcaptcha
  • XcaptchaCaptchaForm
  • XcaptchaImage
  • XcaptchaImageForm
  • XcaptchaRecaptcha
  • XcaptchaRecaptchaForm
  • XcaptchaText
  • XcaptchaTextForm
  • Xlanguage
  • XlanguageLanguage
  • XlanguageLanguageForm
  • XlanguagePreload
  • XlanguageTinymceForm
  • XlanguageXlanguageHandler
  • Xmf\Database\TableLoad
  • Xmf\Database\Tables
  • Xmf\Debug
  • Xmf\FilterInput
  • Xmf\Highlighter
  • Xmf\Language
  • Xmf\Loader
  • Xmf\Metagen
  • Xmf\Module\Admin
  • Xmf\Module\Cache
  • Xmf\Module\Helper
  • Xmf\Module\Helper\AbstractHelper
  • Xmf\Module\Helper\GenericHelper
  • Xmf\Module\Permission
  • Xmf\Module\Session
  • Xmf\Request
  • Xmf\Template\AbstractTemplate
  • Xmf\Template\Breadcrumb
  • Xmf\Template\Buttonbox
  • Xmf\Template\Feed
  • Xmf\Template\PrintContent
  • Xmf\Utilities
  • Xmf\Yaml
  • XmfPreload
  • XmlTagHandler
  • Xoops
  • Xoops\Auth\Ads
  • Xoops\Auth\AuthAbstract
  • Xoops\Auth\Factory
  • Xoops\Auth\Ldap
  • Xoops\Auth\Provisioning
  • Xoops\Auth\Xoops
  • Xoops\Cache
  • Xoops\Core\Assets
  • Xoops\Core\Cache\Access
  • Xoops\Core\Cache\CacheManager
  • Xoops\Core\Cache\DriverList
  • Xoops\Core\Cache\Legacy
  • Xoops\Core\ComposerUtility
  • Xoops\Core\Database\Connection
  • Xoops\Core\Database\Factory
  • Xoops\Core\Database\Logging\XoopsDebugStack
  • Xoops\Core\Database\QueryBuilder
  • Xoops\Core\Database\Schema\ExportVisitor
  • Xoops\Core\Database\Schema\ImportSchema
  • Xoops\Core\Database\Schema\PrefixStripper
  • Xoops\Core\Database\Schema\RemovePrefixes
  • Xoops\Core\Events
  • Xoops\Core\FilterInput
  • Xoops\Core\FixedGroups
  • Xoops\Core\Handler\Factory
  • Xoops\Core\Handler\FactorySpec
  • Xoops\Core\Handler\Scheme\FQN
  • Xoops\Core\Handler\Scheme\Kernel
  • Xoops\Core\Handler\Scheme\LegacyModule
  • Xoops\Core\HttpRequest
  • Xoops\Core\Kernel\Criteria
  • Xoops\Core\Kernel\CriteriaCompo
  • Xoops\Core\Kernel\CriteriaElement
  • Xoops\Core\Kernel\Dtype
  • Xoops\Core\Kernel\Dtype\DtypeAbstract
  • Xoops\Core\Kernel\Dtype\DtypeArray
  • Xoops\Core\Kernel\Dtype\DtypeDateTime
  • Xoops\Core\Kernel\Dtype\DtypeDecimal
  • Xoops\Core\Kernel\Dtype\DtypeEmail
  • Xoops\Core\Kernel\Dtype\DtypeEnumeration
  • Xoops\Core\Kernel\Dtype\DtypeFloat
  • Xoops\Core\Kernel\Dtype\DtypeInt
  • Xoops\Core\Kernel\Dtype\DtypeJson
  • Xoops\Core\Kernel\Dtype\DtypeMoney
  • Xoops\Core\Kernel\Dtype\DtypeOther
  • Xoops\Core\Kernel\Dtype\DtypeSimpleTime
  • Xoops\Core\Kernel\Dtype\DtypeSource
  • Xoops\Core\Kernel\Dtype\DtypeTextArea
  • Xoops\Core\Kernel\Dtype\DtypeTextBox
  • Xoops\Core\Kernel\Dtype\DtypeTimeZone
  • Xoops\Core\Kernel\Dtype\DtypeUrl
  • Xoops\Core\Kernel\Handlers\XoopsBlock
  • Xoops\Core\Kernel\Handlers\XoopsBlockHandler
  • Xoops\Core\Kernel\Handlers\XoopsBlockModuleLink
  • Xoops\Core\Kernel\Handlers\XoopsBlockModuleLinkHandler
  • Xoops\Core\Kernel\Handlers\XoopsConfigHandler
  • Xoops\Core\Kernel\Handlers\XoopsConfigItem
  • Xoops\Core\Kernel\Handlers\XoopsConfigItemHandler
  • Xoops\Core\Kernel\Handlers\XoopsConfigOption
  • Xoops\Core\Kernel\Handlers\XoopsConfigOptionHandler
  • Xoops\Core\Kernel\Handlers\XoopsGroup
  • Xoops\Core\Kernel\Handlers\XoopsGroupHandler
  • Xoops\Core\Kernel\Handlers\XoopsGroupPerm
  • Xoops\Core\Kernel\Handlers\XoopsGroupPermHandler
  • Xoops\Core\Kernel\Handlers\XoopsMemberHandler
  • Xoops\Core\Kernel\Handlers\XoopsMembership
  • Xoops\Core\Kernel\Handlers\XoopsMembershipHandler
  • Xoops\Core\Kernel\Handlers\XoopsModule
  • Xoops\Core\Kernel\Handlers\XoopsModuleHandler
  • Xoops\Core\Kernel\Handlers\XoopsOnline
  • Xoops\Core\Kernel\Handlers\XoopsOnlineHandler
  • Xoops\Core\Kernel\Handlers\XoopsPrivateMessage
  • Xoops\Core\Kernel\Handlers\XoopsPrivateMessageHandler
  • Xoops\Core\Kernel\Handlers\XoopsTplFile
  • Xoops\Core\Kernel\Handlers\XoopsTplFileHandler
  • Xoops\Core\Kernel\Handlers\XoopsTplSet
  • Xoops\Core\Kernel\Handlers\XoopsTplSetHandler
  • Xoops\Core\Kernel\Handlers\XoopsUser
  • Xoops\Core\Kernel\Handlers\XoopsUserHandler
  • Xoops\Core\Kernel\Model\Joint
  • Xoops\Core\Kernel\Model\Read
  • Xoops\Core\Kernel\Model\Stats
  • Xoops\Core\Kernel\Model\Sync
  • Xoops\Core\Kernel\Model\Write
  • Xoops\Core\Kernel\XoopsModelAbstract
  • Xoops\Core\Kernel\XoopsModelFactory
  • Xoops\Core\Kernel\XoopsObject
  • Xoops\Core\Kernel\XoopsObjectHandler
  • Xoops\Core\Kernel\XoopsPersistableObjectHandler
  • Xoops\Core\Lists\Country
  • Xoops\Core\Lists\Directory
  • Xoops\Core\Lists\Editor
  • Xoops\Core\Lists\File
  • Xoops\Core\Lists\HtmlFile
  • Xoops\Core\Lists\ImageFile
  • Xoops\Core\Lists\ListAbstract
  • Xoops\Core\Lists\Locale
  • Xoops\Core\Lists\Module
  • Xoops\Core\Lists\Month
  • Xoops\Core\Lists\SubjectIcon
  • Xoops\Core\Lists\SubSet
  • Xoops\Core\Lists\Theme
  • Xoops\Core\Lists\Time
  • Xoops\Core\Lists\TimeZone
  • Xoops\Core\Locale\LegacyCodes
  • Xoops\Core\Locale\Punic\Calendar
  • Xoops\Core\Locale\Time
  • Xoops\Core\Logger
  • Xoops\Core\MediaUploader
  • Xoops\Core\MimeTypes
  • Xoops\Core\PreloadItem
  • Xoops\Core\Psr0ClassLoader
  • Xoops\Core\Psr4ClassLoader
  • Xoops\Core\Random
  • Xoops\Core\Registry
  • Xoops\Core\Request
  • Xoops\Core\Security
  • Xoops\Core\Service\AbstractContract
  • Xoops\Core\Service\Manager
  • Xoops\Core\Service\NullProvider
  • Xoops\Core\Service\Provider
  • Xoops\Core\Service\Response
  • Xoops\Core\Session\Fingerprint
  • Xoops\Core\Session\Handler
  • Xoops\Core\Session\Manager
  • Xoops\Core\Session\RememberMe
  • Xoops\Core\Session\SessionUser
  • Xoops\Core\Text\Sanitizer
  • Xoops\Core\Text\Sanitizer\Configuration
  • Xoops\Core\Text\Sanitizer\ConfigurationAbstract
  • Xoops\Core\Text\Sanitizer\DefaultConfiguration
  • Xoops\Core\Text\Sanitizer\ExtensionAbstract
  • Xoops\Core\Text\Sanitizer\Extensions\Censor
  • Xoops\Core\Text\Sanitizer\Extensions\Clickable
  • Xoops\Core\Text\Sanitizer\Extensions\Embed
  • Xoops\Core\Text\Sanitizer\Extensions\Flash
  • Xoops\Core\Text\Sanitizer\Extensions\Iframe
  • Xoops\Core\Text\Sanitizer\Extensions\Image
  • Xoops\Core\Text\Sanitizer\Extensions\Mms
  • Xoops\Core\Text\Sanitizer\Extensions\Mp3
  • Xoops\Core\Text\Sanitizer\Extensions\Quote
  • Xoops\Core\Text\Sanitizer\Extensions\Rtsp
  • Xoops\Core\Text\Sanitizer\Extensions\SoundCloud
  • Xoops\Core\Text\Sanitizer\Extensions\SyntaxHighlight
  • Xoops\Core\Text\Sanitizer\Extensions\TextFilter
  • Xoops\Core\Text\Sanitizer\Extensions\UnorderedList
  • Xoops\Core\Text\Sanitizer\Extensions\Wiki
  • Xoops\Core\Text\Sanitizer\Extensions\Wmp
  • Xoops\Core\Text\Sanitizer\Extensions\XoopsCode
  • Xoops\Core\Text\Sanitizer\Extensions\Xss
  • Xoops\Core\Text\Sanitizer\Extensions\YouTube
  • Xoops\Core\Text\Sanitizer\FilterAbstract
  • Xoops\Core\Text\Sanitizer\NullExtension
  • Xoops\Core\Text\Sanitizer\NullFilter
  • Xoops\Core\Text\Sanitizer\SanitizerComponent
  • Xoops\Core\Text\Sanitizer\SanitizerConfigurable
  • Xoops\Core\Text\ShortCodes
  • Xoops\Core\Theme\AdminFactory
  • Xoops\Core\Theme\Factory
  • Xoops\Core\Theme\NullTheme
  • Xoops\Core\Theme\PluginAbstract
  • Xoops\Core\Theme\Plugins\Blocks
  • Xoops\Core\Theme\XoopsTheme
  • Xoops\Core\XoopsTpl
  • Xoops\Core\Yaml
  • Xoops\Form\BlockForm
  • Xoops\Form\Button
  • Xoops\Form\ButtonTray
  • Xoops\Form\Captcha
  • Xoops\Form\Checkbox
  • Xoops\Form\ColorPicker
  • Xoops\Form\DateSelect
  • Xoops\Form\DateTime
  • Xoops\Form\DhtmlTextArea
  • Xoops\Form\Editor
  • Xoops\Form\Element
  • Xoops\Form\ElementFactory
  • Xoops\Form\ElementTray
  • Xoops\Form\File
  • Xoops\Form\Form
  • Xoops\Form\GroupCheckbox
  • Xoops\Form\GroupFormCheckbox
  • Xoops\Form\GroupPermissionForm
  • Xoops\Form\Hidden
  • Xoops\Form\Label
  • Xoops\Form\Mail
  • Xoops\Form\OptionElement
  • Xoops\Form\Password
  • Xoops\Form\Radio
  • Xoops\Form\RadioYesNo
  • Xoops\Form\Raw
  • Xoops\Form\Select
  • Xoops\Form\SelectCountry
  • Xoops\Form\SelectEditor
  • Xoops\Form\SelectGroup
  • Xoops\Form\SelectLanguage
  • Xoops\Form\SelectLocale
  • Xoops\Form\SelectMatchOption
  • Xoops\Form\SelectTheme
  • Xoops\Form\SelectTimeZone
  • Xoops\Form\SelectUser
  • Xoops\Form\SimpleForm
  • Xoops\Form\Tab
  • Xoops\Form\TableForm
  • Xoops\Form\TabTray
  • Xoops\Form\Text
  • Xoops\Form\TextArea
  • Xoops\Form\ThemeForm
  • Xoops\Form\Token
  • Xoops\Form\Url
  • Xoops\Html\Attributes
  • Xoops\Html\Img
  • Xoops\Locale
  • Xoops\Locale\AbstractLocale
  • Xoops\Module\Admin
  • Xoops\Module\Helper
  • Xoops\Module\Helper\Dummy
  • Xoops\Module\Helper\HelperAbstract
  • Xoops\Module\Plugin
  • Xoops\Module\Plugin\ConfigCollector
  • Xoops\Module\Plugin\PluginAbstract
  • Xoops\Utils
  • Xoops_Locale_Mailer_Abstract
  • XoopsAdminThemeFactory
  • XoopsApi
  • XoopsArt
  • XoopsBaseConfig
  • XoopsBlock
  • XoopsBlockHandler
  • XoopsBlockmodulelink
  • XoopsBlockmodulelinkHandler
  • XoopsCache
  • XoopsCaptcha
  • XoopsCaptchaImage
  • XoopsCaptchaImageHandler
  • XoopsCaptchaMethod
  • XoopsCaptchaRecaptcha
  • XoopsCaptchaText
  • XoopsConfigHandler
  • XoopsConfigItem
  • XoopsConfigItemHandler
  • XoopsConfigOption
  • XoopsConfigOptionHandler
  • XoopsDatabase
  • XoopsDatabaseFactory
  • XoopsDatabaseManager
  • XoopsDownloader
  • XoopsEditor
  • XoopsEditorHandler
  • XoopsFile
  • XoopsFileHandler
  • XoopsFilterInput
  • XoopsFolderHandler
  • XoopsForm
  • XoopsFormButton
  • XoopsFormButtonTray
  • XoopsFormCaptcha
  • XoopsFormCheckBox
  • XoopsFormColorPicker
  • XoopsFormDateTime
  • XoopsFormDhtmlTextArea
  • XoopsFormEditor
  • XoopsFormElement
  • XoopsFormElementTray
  • XoopsFormFile
  • XoopsFormHidden
  • XoopsFormHiddenToken
  • XoopsFormLabel
  • XoopsFormPassword
  • XoopsFormRadio
  • XoopsFormRadioYN
  • XoopsFormSelect
  • XoopsFormSelectCheckGroup
  • XoopsFormSelectCountry
  • XoopsFormSelectEditor
  • XoopsFormSelectGroup
  • XoopsFormSelectLang
  • XoopsFormSelectMatchOption
  • XoopsFormSelectTheme
  • XoopsFormSelectTimezone
  • XoopsFormSelectUser
  • XoopsFormText
  • XoopsFormTextArea
  • XoopsFormTextDateSelect
  • XoopsFormTinymce
  • XoopsFormTinymce4
  • XoopsGroup
  • XoopsGroupHandler
  • XoopsGroupPerm
  • XoopsGroupPermForm
  • XoopsGroupPermHandler
  • XoopsGTicket
  • XoopsGuiDefault
  • XoopsInstallWizard
  • XoopsLists
  • XoopsLoad
  • XoopsLocal
  • XoopsLocale
  • XoopsLocaleEn_US
  • XoopsLogger
  • XoopsMailer
  • XoopsMailerLocal
  • XoopsMailerLocale
  • XoopsMediaUploader
  • XoopsMemberHandler
  • XoopsMembership
  • XoopsMembershipHandler
  • XoopsModule
  • XoopsModuleHandler
  • XoopsMultiMailer
  • XoopsMySQLDatabase
  • XoopsMySQLDatabaseProxy
  • XoopsMySQLDatabaseSafe
  • XoopsObject
  • XoopsObjectHandler
  • XoopsObjectTree
  • XoopsOnline
  • XoopsOnlineHandler
  • XoopsPageNav
  • XoopsPathController
  • XoopsPersistableObjectHandler
  • XoopsPreload
  • XoopsPreloadItem
  • XoopsPrivmessage
  • XoopsPrivmessageHandler
  • XoopsRequest
  • XoopsSecurity
  • XoopsSimpleForm
  • XoopsTableForm
  • XoopsTarDownloader
  • XoopsTheme
  • XoopsThemeBlocksPlugin
  • XoopsThemeFactory
  • XoopsThemeForm
  • XoopsThemePlugin
  • XoopsThemeSetParser
  • XoopsTpl
  • XoopsTplfile
  • XoopsTplfileHandler
  • XoopsTplset
  • XoopsTplsetHandler
  • XoopsUser
  • XoopsUserHandler
  • XoopsUserUtility
  • XoopsUtility
  • XoopsXmlRpcApi
  • XoopsXmlRpcArray
  • XoopsXmlRpcBase64
  • XoopsXmlRpcBoolean
  • XoopsXmlRpcDatetime
  • XoopsXmlRpcDocument
  • XoopsXmlRpcDouble
  • XoopsXmlRpcFault
  • XoopsXmlRpcInt
  • XoopsXmlRpcParser
  • XoopsXmlRpcRequest
  • XoopsXmlRpcResponse
  • XoopsXmlRpcString
  • XoopsXmlRpcStruct
  • XoopsXmlRpcTag
  • XoopsXmlRss2Parser
  • XoopsZipDownloader
  • zipfile

Interfaces

  • CommentsPluginInterface
  • MenusDecoratorInterface
  • MenusPluginInterface
  • NotificationsPluginInterface
  • SearchPluginInterface
  • SystemPluginInterface
  • UserconfigsPluginInterface
  • Xoops\Core\AttributeInterface
  • Xoops\Core\Handler\Scheme\SchemeInterface
  • Xoops\Core\Service\Contract\AvatarInterface
  • Xoops\Core\Service\Contract\CountryflagInterface
  • Xoops\Core\Service\Contract\EmojiInterface
  • Xoops\Core\Service\Contract\HtmlToPdfInterface
  • Xoops\Core\Service\Contract\QrcodeInterface
  • Xoops\Core\Service\Contract\ThumbnailInterface
  • Xoops\Core\Service\Contract\UserRankInterface
  • Xoops\Core\Session\FingerprintInterface
  • Xoops\Form\ContainerInterface

Exceptions

  • Xoops\Core\Exception\InvalidHandlerSpecException
  • Xoops\Core\Exception\NoHandlerException

Functions

  • _changeMimeValue
  • _clearAddSessionVars
  • _clearEditSessionVars
  • _ee
  • _recaptcha_aes_encrypt
  • _recaptcha_aes_pad
  • _recaptcha_http_post
  • _recaptcha_mailhide_email_parts
  • _recaptcha_mailhide_urlbase64
  • _recaptcha_qsencode
  • _tt
  • add
  • addCriteria
  • admin_refcheck
  • b_comments_edit
  • b_comments_show
  • b_notification_show
  • b_search_show
  • b_system_info_edit
  • b_system_info_show
  • b_system_login_show
  • b_system_main_edit
  • b_system_main_show
  • b_system_newmembers_edit
  • b_system_newmembers_show
  • b_system_online_show
  • b_system_themes_edit
  • b_system_themes_show
  • b_system_topposters_edit
  • b_system_topposters_show
  • b_system_user_show
  • b_system_waiting_show
  • b_xlanguage_select_edit
  • b_xlanguage_select_show
  • banners_blocks_edit
  • banners_blocks_show
  • base_url
  • buildRssFeedCache
  • buildTable
  • check_files_extensions_on_path
  • check_files_extensions_on_phar
  • checkEmail
  • clearAddSession
  • clearEditSession
  • config_loading
  • create_folder
  • create_img
  • create_img_gd
  • createConfigform
  • createDir
  • createThemeform
  • dateSort
  • debugger
  • delete
  • deleteDir
  • duplicate_file
  • edit
  • endsWith
  • exception_handler
  • extensionSort
  • file_put_contents
  • filenameSort
  • filescount
  • fix_dirname
  • fix_filename
  • fix_get_params
  • fix_path
  • fix_strtolower
  • fix_strtoupper
  • foldersize
  • formatTimestamp
  • formatURL
  • genPathCheckHtml
  • get_file_by_url
  • get_writeoks_from_protector
  • getBrightness
  • getDbConnection
  • getDbConnectionParams
  • getDirList
  • handle_uploaded_files
  • http_response_code
  • image_check_memory_usage
  • install_acceptUser
  • install_finalize
  • installHtmlSpecialCharacters
  • is_function_callable
  • is_really_writable
  • load_functions
  • load_object
  • load_objectHandler
  • loadModuleAdminMenu
  • makeSize
  • manage
  • menus_block_edit
  • menus_block_show
  • menus_mainmenu_show
  • mod_clearCacheFile
  • mod_clearConfg
  • mod_clearConfig
  • mod_clearFile
  • mod_clearSmartyCache
  • mod_constant
  • mod_createCacheFile
  • mod_createCacheFile_byGroup
  • mod_createFile
  • mod_DB_prefix
  • mod_fetchConfg
  • mod_fetchConfig
  • mod_generateCacheId
  • mod_generateCacheId_byGroup
  • mod_getDirname
  • mod_getMysqlVersion
  • mod_isModuleAction
  • mod_loadCacheFile
  • mod_loadCacheFile_byGroup
  • mod_loadConfg
  • mod_loadConfig
  • mod_loadFile
  • mod_loadFunctions
  • mod_loadRenderer
  • mod_message
  • modify_chmod
  • new_thumbnails_creation
  • normalizeColor
  • page_blocks_edit
  • page_blocks_show
  • profile_getRegisterForm
  • profile_getUserForm
  • profile_install_addCategory
  • profile_install_addField
  • profile_install_addStep
  • profile_install_initializeProfiles
  • profile_install_setPermissions
  • protector_ip_cmp
  • protector_postcheck
  • protector_precheck
  • publisher_category_items_sel_edit
  • publisher_category_items_sel_show
  • publisher_cloneFileFolder
  • publisher_createLogo
  • publisher_date_to_date_edit
  • publisher_date_to_date_show
  • publisher_displayCategory
  • publisher_editCat
  • publisher_editFile
  • publisher_editItem
  • publisher_items_columns_edit
  • publisher_items_columns_show
  • publisher_items_menu_edit
  • publisher_items_menu_show
  • publisher_items_new_edit
  • publisher_items_new_show
  • publisher_items_random_item_show
  • publisher_items_recent_edit
  • publisher_items_recent_show
  • publisher_items_spot_edit
  • publisher_items_spot_show
  • publisher_latest_files_edit
  • publisher_latest_files_show
  • publisher_latest_news_edit
  • publisher_latest_news_show
  • publisher_mk_chkbox
  • publisher_mk_select
  • publisher_pagewrap_upload
  • publisher_search
  • publisher_search_show
  • publisher_tag_iteminfo
  • publisher_tag_synchronization
  • rcopy
  • recaptcha_check_answer
  • recaptcha_get_html
  • recaptcha_get_signup_url
  • recaptcha_mailhide_html
  • recaptcha_mailhide_url
  • redirect_header
  • rename_file
  • rename_folder
  • rrename
  • rrename_after_cleaner
  • search
  • sizeSort
  • smarty_block_assets
  • smarty_block_noshortcodes
  • smarty_compiler_xoAdminIcons
  • smarty_compiler_xoAdminNav
  • smarty_compiler_xoAppUrl
  • smarty_compiler_xoImgUrl
  • smarty_compiler_xoModuleIcons16
  • smarty_compiler_xoModuleIcons32
  • smarty_compiler_xoModuleIconsBookmarks
  • smarty_function_addBaseScript
  • smarty_function_addBaseStylesheet
  • smarty_function_securityToken
  • smarty_function_thumbnail
  • smarty_function_translate
  • smarty_function_translateTheme
  • smarty_function_xoblock
  • smarty_function_xoInboxCount
  • smarty_function_xoMemberInfo
  • smarty_function_xoops_link
  • smarty_function_xoPageNav
  • smarty_modifier_datetime
  • smarty_modifier_debug_print_var
  • smarty_outputfilter_shortcodes
  • synchronize
  • system_AdminIcons
  • system_adminVersion
  • system_cleanVars
  • system_loadLanguage
  • system_loadTemplate
  • updateMimeValue
  • userTimeToServerTime
  • xhtmlspecialchars
  • xlanguage_convert_encoding
  • xlanguage_convert_item
  • xlanguage_copyfile
  • xlanguage_detectLang
  • xlanguage_encoding
  • xlanguage_lang_detect
  • xlanguage_mkdirs
  • xlanguage_ml
  • xlanguage_ml_escape_bracket
  • xlanguage_select_show
  • xoBoolField
  • xoDiag
  • xoDiagBoolSetting
  • xoDiagIfWritable
  • xoFormField
  • xoops_comment_count
  • xoops_comment_delete
  • xoops_confirm
  • xoops_convert_encoding
  • xoops_cp_footer
  • xoops_cp_header
  • xoops_error
  • xoops_footer
  • xoops_getActiveModules
  • xoops_getbanner
  • xoops_getBaseDomain
  • xoops_getConfigOption
  • xoops_getcss
  • xoops_getenv
  • xoops_getHandler
  • xoops_getMailer
  • xoops_getModuleHandler
  • xoops_getModuleOption
  • xoops_getOption
  • xoops_getrank
  • xoops_getUrlDomain
  • xoops_getUserTimestamp
  • xoops_groupperm_deletebymoditem
  • xoops_header
  • xoops_isActiveModule
  • xoops_load
  • xoops_loadLanguage
  • xoops_makepass
  • xoops_message
  • xoops_module_install_avatars
  • xoops_module_install_banners
  • xoops_module_install_comments
  • xoops_module_install_debugbar
  • xoops_module_install_notifications
  • xoops_module_install_page
  • xoops_module_install_pm
  • xoops_module_install_profile
  • xoops_module_install_publisher
  • xoops_module_install_smilies
  • xoops_module_install_system
  • xoops_module_install_userrank
  • xoops_module_install_xlanguage
  • xoops_module_pre_uninstall_comments
  • xoops_module_pre_uninstall_notifications
  • xoops_module_update_comments
  • xoops_module_update_debugbar
  • xoops_module_update_notifications
  • xoops_module_update_pm
  • xoops_module_update_profile
  • xoops_module_update_publisher
  • xoops_module_update_search
  • xoops_module_update_system
  • xoops_module_update_xlanguage
  • xoops_notification_deletebyitem
  • xoops_notification_deletebymodule
  • xoops_notification_deletebyuser
  • xoops_result
  • xoops_setActiveModules
  • xoops_setConfigOption
  • xoops_substr
  • xoops_template_clear_module_cache
  • xoops_template_touch
  • xoops_trim
  • xoops_utf8_encode
  • xoopseditor_get_rootpath
  • xoPassField
  • xoPhpVersion
  • Overview
  • Namespace
  • Class
  • Tree
  1: <?php
  2: // $Id$
  3: 
  4: /**
  5:  * package::i.tools
  6:  *
  7:  * php-downloader    v1.0    -    www.ipunkt.biz
  8:  *
  9:  * (c)    2002 - www.ipunkt.biz (rok)
 10:  */
 11: /**
 12:  * =======================================================================
 13:  * Name:
 14:  * tar Class
 15:  *
 16:  * Author:
 17:  * Josh Barger <joshb@npt.com>
 18:  *
 19:  * Description:
 20:  * This class reads and writes Tape-Archive (TAR) Files and Gzip
 21:  * compressed TAR files, which are mainly used on UNIX systems.
 22:  * This class works on both windows AND unix systems, and does
 23:  * NOT rely on external applications!! Woohoo!
 24:  *
 25:  * Usage:
 26:  * Copyright (C) 2002  Josh Barger
 27:  *
 28:  * This library is free software; you can redistribute it and/or
 29:  * modify it under the terms of the GNU Lesser General Public
 30:  * License as published by the Free Software Foundation; either
 31:  * version 2.1 of the License, or (at your option) any later version.
 32:  *
 33:  * This library is distributed in the hope that it will be useful,
 34:  * but WITHOUT ANY WARRANTY; without even the implied warranty of
 35:  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 36:  * Lesser General Public License for more details at:
 37:  * http://www.gnu.org/copyleft/lesser.html
 38:  *
 39:  * If you use this script in your application/website, please
 40:  * send me an e-mail letting me know about it :)
 41:  *
 42:  * Bugs:
 43:  * Please report any bugs you might find to my e-mail address
 44:  * at joshb@npt.com.  If you have already created a fix/patch
 45:  * for the bug, please do send it to me so I can incorporate it into my release.
 46:  *
 47:  * Version History:
 48:  * 1.0    04/10/2002    - InitialRelease
 49:  *
 50:  * 2.0    04/11/2002    - Merged both tarReader and tarWriter
 51:  * classes into one
 52:  * - Added support for gzipped tar files
 53:  * Remember to name for .tar.gz or .tgz
 54:  * if you use gzip compression!
 55:  * :: THIS REQUIRES ZLIB EXTENSION ::
 56:  * - Added additional comments to
 57:  * functions to help users
 58:  * - Added ability to remove files and
 59:  * directories from archive
 60:  * 2.1    04/12/2002    - Fixed serious bug in generating tar
 61:  * - Created another example file
 62:  * - Added check to make sure ZLIB is
 63:  * installed before running GZIP
 64:  * compression on TAR
 65:  * 2.2    05/07/2002    - Added automatic detection of Gzipped
 66:  * tar files (Thanks go to Jidgen Falch
 67:  * for the idea)
 68:  * - Changed "private" functions to have
 69:  * special function names beginning with
 70:  * two underscores
 71:  * =======================================================================
 72:  * XOOPS changes onokazu <webmaster@xoops.org>
 73:  *
 74:  * 12/25/2002 - Added flag to addFile() function for binary files
 75:  *
 76:  * =======================================================================
 77:  */
 78: 
 79: /**
 80:  * tar Class
 81:  *
 82:  * This class reads and writes Tape-Archive (TAR) Files and Gzip
 83:  * compressed TAR files, which are mainly used on UNIX systems.
 84:  * This class works on both windows AND unix systems, and does
 85:  * NOT rely on external applications!! Woohoo!
 86:  *
 87:  * @author Josh Barger <joshb@npt.com>
 88:  * @copyright Copyright (C) 2002  Josh Barger
 89:  * @package class
 90:  */
 91: class tar
 92: {
 93:     /**
 94:      * *#@+
 95:      * Unprocessed Archive Information
 96:      */
 97:     public $filename;
 98:     public $isGzipped;
 99:     public $tar_file;
100:     /**
101:      * *#@-
102:      */
103: 
104:     /**
105:      * *#@+
106:      * Processed Archive Information
107:      */
108:     public $files;
109:     public $directories;
110:     public $numFiles;
111:     public $numDirectories;
112: 
113:     /**
114:      * *#@-
115:      */
116: 
117:     /**
118:      * Computes the unsigned Checksum of a file's header
119:      * to try to ensure valid file
120:      *
121:      * @param string $bytestring
122:      * @return int|string
123:      * @access private
124:      */
125:     private function __computeUnsignedChecksum($bytestring)
126:     {
127:         $unsigned_chksum = '';
128:         for ($i = 0; $i < 512; ++$i) {
129:             $unsigned_chksum += ord($bytestring[$i]);
130:         }
131:         for ($i = 0; $i < 8; ++$i) {
132:             $unsigned_chksum -= ord($bytestring[148 + $i]);
133:             $unsigned_chksum += ord(' ') * 8;
134:         }
135:         return $unsigned_chksum;
136:     }
137: 
138:     /**
139:      * Converts a NULL padded string to a non-NULL padded string
140:      *
141:      * @param string $string
142:      * @return string
143:      * @access private
144:      */
145:     private function __parseNullPaddedString($string)
146:     {
147:         $position = strpos($string, chr(0));
148:         return substr($string, 0, $position);
149:     }
150: 
151:     /**
152:      * This function parses the current TAR file
153:      *
154:      * @return bool always TRUE
155:      * @access private
156:      */
157:     private function __parseTar()
158:     {
159:         // Read Files from archive
160:         $tar_length = strlen($this->tar_file);
161:         $main_offset = 0;
162:         $this->numFiles = 0;
163:         while ($main_offset < $tar_length) {
164:             // If we read a block of 512 nulls, we are at the end of the archive
165:             if (substr($this->tar_file, $main_offset, 512) == str_repeat(chr(0), 512)) {
166:                 break;
167:             }
168:             // Parse file name
169:             $file_name = $this->__parseNullPaddedString(substr($this->tar_file, $main_offset, 100));
170:             // Parse the file mode
171:             $file_mode = substr($this->tar_file, $main_offset + 100, 8);
172:             // Parse the file user ID
173:             $file_uid = octdec(substr($this->tar_file, $main_offset + 108, 8));
174:             // Parse the file group ID
175:             $file_gid = octdec(substr($this->tar_file, $main_offset + 116, 8));
176:             // Parse the file size
177:             $file_size = octdec(substr($this->tar_file, $main_offset + 124, 12));
178:             // Parse the file update time - unix timestamp format
179:             $file_time = octdec(substr($this->tar_file, $main_offset + 136, 12));
180:             // Parse Checksum
181:             $file_chksum = octdec(substr($this->tar_file, $main_offset + 148, 6));
182:             // Parse user name
183:             $file_uname = $this->__parseNullPaddedString(substr($this->tar_file, $main_offset + 265, 32));
184:             // Parse Group name
185:             $file_gname = $this->__parseNullPaddedString(substr($this->tar_file, $main_offset + 297, 32));
186:             // Make sure our file is valid
187:             if ($this->__computeUnsignedChecksum(substr($this->tar_file, $main_offset, 512)) != $file_chksum) {
188:                 return false;
189:             }
190:             // Parse File Contents
191:             $file_contents = substr($this->tar_file, $main_offset + 512, $file_size);
192: 
193:             /**
194:              * ### Unused Header Information ###
195:              * $activeFile["typeflag"]        = substr($this->tar_file,$main_offset + 156,1);
196:              * $activeFile["linkname"]        = substr($this->tar_file,$main_offset + 157,100);
197:              * $activeFile["magic"]        = substr($this->tar_file,$main_offset + 257,6);
198:              * $activeFile["version"]        = substr($this->tar_file,$main_offset + 263,2);
199:              * $activeFile["devmajor"]        = substr($this->tar_file,$main_offset + 329,8);
200:              * $activeFile["devminor"]        = substr($this->tar_file,$main_offset + 337,8);
201:              * $activeFile["prefix"]        = substr($this->tar_file,$main_offset + 345,155);
202:              * $activeFile["endheader"]    = substr($this->tar_file,$main_offset + 500,12);
203:              */
204: 
205:             if ($file_size > 0) {
206:                 // Increment number of files
207:                 $this->numFiles++;
208:                 // Create us a new file in our array
209:                 $activeFile =& $this->files[];
210:                 // Asign Values
211:                 $activeFile["name"] = $file_name;
212:                 $activeFile["mode"] = $file_mode;
213:                 $activeFile["size"] = $file_size;
214:                 $activeFile["time"] = $file_time;
215:                 $activeFile["user_id"] = $file_uid;
216:                 $activeFile["group_id"] = $file_gid;
217:                 $activeFile["user_name"] = $file_uname;
218:                 $activeFile["group_name"] = $file_gname;
219:                 $activeFile["checksum"] = $file_chksum;
220:                 $activeFile["file"] = $file_contents;
221:             } else {
222:                 // Increment number of directories
223:                 $this->numDirectories++;
224:                 // Create a new directory in our array
225:                 $activeDir =& $this->directories[];
226:                 // Assign values
227:                 $activeDir["name"] = $file_name;
228:                 $activeDir["mode"] = $file_mode;
229:                 $activeDir["time"] = $file_time;
230:                 $activeDir["user_id"] = $file_uid;
231:                 $activeDir["group_id"] = $file_gid;
232:                 $activeDir["user_name"] = $file_uname;
233:                 $activeDir["group_name"] = $file_gname;
234:                 $activeDir["checksum"] = $file_chksum;
235:             }
236:             // Move our offset the number of blocks we have processed
237:             $main_offset += 512 + (ceil($file_size / 512) * 512);
238:         }
239: 
240:         return true;
241:     }
242: 
243:     /**
244:      * Read a non gzipped tar file in for processing.
245:      *
246:      * @param string $filename full filename
247:      * @return bool always TRUE
248:      * @access private
249:      */
250:     private function __readTar($filename = '')
251:     {
252:         // Set the filename to load
253:         if (!$filename) {
254:             $filename = $this->filename;
255:         }
256:         // Read in the TAR file
257:         $fp = fopen($filename, 'rb');
258:         $this->tar_file = fread($fp, filesize($filename));
259:         fclose($fp);
260: 
261:         if ($this->tar_file[0] == chr(31) && $this->tar_file[1] == chr(139) && $this->tar_file[2] == chr(8)) {
262:             if (!function_exists('gzinflate')) {
263:                 return false;
264:             }
265:             $this->isGzipped = true;
266:             $this->tar_file = gzinflate(substr($this->tar_file, 10, -4));
267:         }
268:         // Parse the TAR file
269:         $this->__parseTar();
270: 
271:         return true;
272:     }
273: 
274:     /**
275:      * Generates a TAR file from the processed data
276:      *
277:      * @return bool always TRUE
278:      * @access private
279:      */
280:     private function __generateTar()
281:     {
282:         // Clear any data currently in $this->tar_file
283:         unset($this->tar_file);
284:         // Generate Records for each directory, if we have directories
285:         if ($this->numDirectories > 0) {
286:             foreach ($this->directories as $key => $information) {
287:                 $header = '';
288:                 // Generate tar header for this directory
289:                 // Filename, Permissions, UID, GID, size, Time, checksum, typeflag, linkname, magic, version, user name, group name, devmajor, devminor, prefix, end
290:                 $header .= str_pad($information["name"], 100, chr(0));
291:                 $header .= str_pad(decoct($information["mode"]), 7, "0", STR_PAD_LEFT) . chr(0);
292:                 $header .= str_pad(decoct($information["user_id"]), 7, "0", STR_PAD_LEFT) . chr(0);
293:                 $header .= str_pad(decoct($information["group_id"]), 7, "0", STR_PAD_LEFT) . chr(0);
294:                 $header .= str_pad(decoct(0), 11, "0", STR_PAD_LEFT) . chr(0);
295:                 $header .= str_pad(decoct($information["time"]), 11, "0", STR_PAD_LEFT) . chr(0);
296:                 $header .= str_repeat(" ", 8);
297:                 $header .= "5";
298:                 $header .= str_repeat(chr(0), 100);
299:                 $header .= str_pad("ustar", 6, chr(32));
300:                 $header .= chr(32) . chr(0);
301:                 $header .= str_pad("", 32, chr(0));
302:                 $header .= str_pad("", 32, chr(0));
303:                 $header .= str_repeat(chr(0), 8);
304:                 $header .= str_repeat(chr(0), 8);
305:                 $header .= str_repeat(chr(0), 155);
306:                 $header .= str_repeat(chr(0), 12);
307:                 // Compute header checksum
308:                 $checksum = str_pad(decoct($this->__computeUnsignedChecksum($header)), 6, "0", STR_PAD_LEFT);
309:                 for ($i = 0; $i < 6; ++$i) {
310:                     $header[(148 + $i)] = substr($checksum, $i, 1);
311:                 }
312:                 $header[154] = chr(0);
313:                 $header[155] = chr(32);
314:                 // Add new tar formatted data to tar file contents
315:                 $this->tar_file .= $header;
316:             }
317:         }
318:         // Generate Records for each file, if we have files (We should...)
319:         if ($this->numFiles > 0) {
320:             $this->tar_file = '';
321:             foreach ($this->files as $key => $information) {
322:                 $header = '';
323:                 // Generate the TAR header for this file
324:                 // Filename, Permissions, UID, GID, size, Time, checksum, typeflag, linkname, magic, version, user name, group name, devmajor, devminor, prefix, end
325:                 $header .= str_pad($information["name"], 100, chr(0));
326:                 $header .= str_pad(decoct($information["mode"]), 7, "0", STR_PAD_LEFT) . chr(0);
327:                 $header .= str_pad(decoct($information["user_id"]), 7, "0", STR_PAD_LEFT) . chr(0);
328:                 $header .= str_pad(decoct($information["group_id"]), 7, "0", STR_PAD_LEFT) . chr(0);
329:                 $header .= str_pad(decoct($information["size"]), 11, "0", STR_PAD_LEFT) . chr(0);
330:                 $header .= str_pad(decoct($information["time"]), 11, "0", STR_PAD_LEFT) . chr(0);
331:                 $header .= str_repeat(" ", 8);
332:                 $header .= "0";
333:                 $header .= str_repeat(chr(0), 100);
334:                 $header .= str_pad("ustar", 6, chr(32));
335:                 $header .= chr(32) . chr(0);
336:                 $header .= str_pad($information["user_name"], 32, chr(0)); // How do I get a file's user name from PHP?
337:                 $header .= str_pad($information["group_name"], 32, chr(0)); // How do I get a file's group name from PHP?
338:                 $header .= str_repeat(chr(0), 8);
339:                 $header .= str_repeat(chr(0), 8);
340:                 $header .= str_repeat(chr(0), 155);
341:                 $header .= str_repeat(chr(0), 12);
342:                 // Compute header checksum
343:                 $checksum = str_pad(decoct($this->__computeUnsignedChecksum($header)), 6, "0", STR_PAD_LEFT);
344:                 for ($i = 0; $i < 6; ++$i) {
345:                     $header[(148 + $i)] = substr($checksum, $i, 1);
346:                 }
347:                 $header[154] = chr(0);
348:                 $header[155] = chr(32);
349:                 // Pad file contents to byte count divisible by 512
350:                 $file_contents = str_pad($information["file"], (ceil($information["size"] / 512) * 512), chr(0));
351:                 // Add new tar formatted data to tar file contents
352:                 $this->tar_file .= $header . $file_contents;
353:             }
354:         }
355:         // Add 512 bytes of NULLs to designate EOF
356:         $this->tar_file .= str_repeat(chr(0), 512);
357:         return true;
358:     }
359: 
360:     /**
361:      * Open a TAR file
362:      *
363:      * @param string $filename
364:      * @return bool
365:      */
366:     public function openTAR($filename)
367:     {
368:         // Clear any values from previous tar archives
369:         unset($this->filename);
370:         unset($this->isGzipped);
371:         unset($this->tar_file);
372:         unset($this->files);
373:         unset($this->directories);
374:         unset($this->numFiles);
375:         unset($this->numDirectories);
376:         // If the tar file doesn't exist...
377:         if (!XoopsLoad::fileExists($filename)) {
378:             return false;
379:         }
380: 
381:         $this->filename = $filename;
382:         // Parse this file
383:         $this->__readTar();
384:         return true;
385:     }
386: 
387:     /**
388:      * Appends a tar file to the end of the currently opened tar file.
389:      *
390:      * @param string $filename
391:      * @return bool
392:      */
393:     public function appendTar($filename)
394:     {
395:         // If the tar file doesn't exist...
396:         if (!XoopsLoad::fileExists($filename)) {
397:             return false;
398:         }
399:         $this->__readTar($filename);
400:         return true;
401:     }
402: 
403:     /**
404:      * Retrieves information about a file in the current tar archive
405:      *
406:      * @param string $filename
407:      * @return string FALSE on fail
408:      */
409:     public function getFile($filename)
410:     {
411:         if ($this->numFiles > 0) {
412:             foreach ($this->files as $information) {
413:                 if ($information['name'] == $filename) {
414:                     return $information;
415:                 }
416:             }
417:         }
418:         return false;
419:     }
420: 
421:     /**
422:      * Retrieves information about a directory in the current tar archive
423:      *
424:      * @param string $dirname
425:      * @return string FALSE on fail
426:      */
427:     public function getDirectory($dirname)
428:     {
429:         if ($this->numDirectories > 0) {
430:             foreach ($this->directories as $information) {
431:                 if ($information['name'] == $dirname) {
432:                     return $information;
433:                 }
434:             }
435:         }
436:         return false;
437:     }
438: 
439:     /**
440:      * Check if this tar archive contains a specific file
441:      *
442:      * @param string $filename
443:      * @return bool
444:      */
445:     public function containsFile($filename)
446:     {
447:         if ($this->numFiles > 0) {
448:             foreach ($this->files as $information) {
449:                 if ($information['name'] == $filename) {
450:                     return true;
451:                 }
452:             }
453:         }
454:         return false;
455:     }
456: 
457:     /**
458:      * Check if this tar archive contains a specific directory
459:      *
460:      * @param string $dirname
461:      * @return bool
462:      */
463:     public function containsDirectory($dirname)
464:     {
465:         if ($this->numDirectories > 0) {
466:             foreach ($this->directories as $information) {
467:                 if ($information['name'] == $dirname) {
468:                     return true;
469:                 }
470:             }
471:         }
472:         return false;
473:     }
474: 
475:     /**
476:      * Add a directory to this tar archive
477:      *
478:      * @param string $dirname
479:      * @return bool
480:      */
481:     public function addDirectory($dirname)
482:     {
483:         if (!XoopsLoad::fileExists($dirname)) {
484:             return false;
485:         }
486:         // Get directory information
487:         $file_information = stat($dirname);
488:         // Add directory to processed data
489:         $this->numDirectories++;
490:         $activeDir =& $this->directories[];
491:         $activeDir['name'] = $dirname;
492:         $activeDir['mode'] = $file_information['mode'];
493:         $activeDir['time'] = $file_information['time'];
494:         $activeDir['user_id'] = $file_information['uid'];
495:         $activeDir['group_id'] = $file_information['gid'];
496:         $activeDir['checksum'] = isset($checksum) ? $checksum : '';
497: 
498:         return true;
499:     }
500: 
501:     /**
502:      * Add a file to the tar archive
503:      *
504:      * @param string $filename
505:      * @param boolean $binary Binary file?
506:      * @return bool
507:      */
508:     public function addFile($filename, $binary = false)
509:     {
510:         // Make sure the file we are adding exists!
511:         if (!XoopsLoad::fileExists($filename)) {
512:             return false;
513:         }
514:         // Make sure there are no other files in the archive that have this same filename
515:         if ($this->containsFile($filename)) {
516:             return false;
517:         }
518:         // Get file information
519:         $file_information = stat($filename);
520:         // Read in the file's contents
521:         if (!$binary) {
522:             $fp = fopen($filename, 'r');
523:         } else {
524:             $fp = fopen($filename, 'rb');
525:         }
526:         $file_contents = fread($fp, filesize($filename));
527:         fclose($fp);
528:         // Add file to processed data
529:         $this->numFiles++;
530:         $activeFile =& $this->files[];
531:         $activeFile['name'] = $filename;
532:         $activeFile['mode'] = $file_information['mode'];
533:         $activeFile['user_id'] = $file_information['uid'];
534:         $activeFile['group_id'] = $file_information['gid'];
535:         $activeFile['size'] = $file_information['size'];
536:         $activeFile['time'] = $file_information['mtime'];
537:         $activeFile['checksum'] = isset($checksum) ? $checksum : '';
538:         $activeFile['user_name'] = '';
539:         $activeFile['group_name'] = '';
540:         $activeFile['file'] = trim($file_contents);
541:         return true;
542:     }
543: 
544:     /**
545:      * Remove a file from the tar archive
546:      *
547:      * @param string $filename
548:      * @return bool
549:      */
550:     public function removeFile($filename)
551:     {
552:         if ($this->numFiles > 0) {
553:             foreach ($this->files as $key => $information) {
554:                 if ($information['name'] == $filename) {
555:                     $this->numFiles--;
556:                     unset($this->files[$key]);
557:                     return true;
558:                 }
559:             }
560:         }
561:         return false;
562:     }
563: 
564:     /**
565:      * Remove a directory from the tar archive
566:      *
567:      * @param string $dirname
568:      * @return bool
569:      */
570:     public function removeDirectory($dirname)
571:     {
572:         if ($this->numDirectories > 0) {
573:             foreach ($this->directories as $key => $information) {
574:                 if ($information['name'] == $dirname) {
575:                     $this->numDirectories--;
576:                     unset($this->directories[$key]);
577:                     return true;
578:                 }
579:             }
580:         }
581:         return false;
582:     }
583: 
584:     /**
585:      * Write the currently loaded tar archive to disk
586:      *
587:      * @return bool
588:      */
589:     public function saveTar()
590:     {
591:         if (!$this->filename) {
592:             return false;
593:         }
594:         // Write tar to current file using specified gzip compression
595:         $this->toTar($this->filename, $this->isGzipped);
596:         return true;
597:     }
598: 
599:     /**
600:      * Saves tar archive to a different file than the current file
601:      *
602:      * @param string $filename
603:      * @param bool $useGzip Use GZ compression?
604:      * @return bool
605:      */
606:     public function toTar($filename, $useGzip)
607:     {
608:         if (!$filename) {
609:             return false;
610:         }
611:         // Encode processed files into TAR file format
612:         $this->__generateTar();
613:         // GZ Compress the data if we need to
614:         if ($useGzip) {
615:             // Make sure we have gzip support
616:             if (!function_exists('gzencode')) {
617:                 return false;
618:             }
619:             $file = gzencode($this->tar_file);
620:         } else {
621:             $file = $this->tar_file;
622:         }
623:         // Write the TAR file
624:         $fp = fopen($filename, 'wb');
625:         fwrite($fp, $file);
626:         fclose($fp);
627:         return true;
628:     }
629: 
630:     /**
631:      * Sends tar archive to stdout
632:      *
633:      * @param string $filename
634:      * @param bool $useGzip Use GZ compression?
635:      * @return string
636:      */
637:     public function toTarOutput($filename, $useGzip)
638:     {
639:         if (!$filename) {
640:             return false;
641:         }
642:         // Encode processed files into TAR file format
643:         $this->__generateTar();
644:         // GZ Compress the data if we need to
645:         if ($useGzip) {
646:             // Make sure we have gzip support
647:             if (!function_exists('gzencode')) {
648:                 return false;
649:             }
650:             $file = gzencode($this->tar_file);
651:         } else {
652:             $file = $this->tar_file;
653:         }
654:         return $file;
655:     }
656: }
657: 
API documentation generated by ApiGen