classes/php5_classes/HTML.class.php

Properties

Description

Holds the utility class geoHTML.

Classes

geoHTML

Properties

 
 
System  
4.0.0  
No 
No 

Description

Class to generate chunks of HTML that are very common, used the most in the admin panel.

Methods

addButton, addHeader, addOption, addSaveButton, addThreeColumnHeader, addThreeColumnRow, addTwoColumnHeader, adminGetRowColor, dateSelect, fieldset, getArrayDropDown, getNumericDropDown, input, resetRowColor, separator, showTooltip,

addButton( string   $label, string   $link, bool   $link_is_really_javascript = false, string   $id = '', string   $class = 'mini_button', ) : string

Description

Adds a simple button that links to somewhere. Use this so that all button type stuff looks uniform in the software.
If you need something more fancy, like an ajax button or something, look at the (not created yet) class geoButton.

Arguments

Name Type Description Default
$label string

The text in the button

$link string

Where the button links to.

$link_is_really_javascript bool false
$id string ''
$class string 'mini_button'

Return value

Type Description
string

addHeader( ) : string

Description

OK by header, the original author aparently meant heading. Just pass in stuff and it will get put into a heading, I think.
..

Return value

Type Description
string Some HTML.

addOption( string   $option, string   $html_value = null, string   $eg = null, boolean   $change_color_or_class = true, string   $left_html = '', string   $right_html = '', string   $id = '', ) : string

Description

For use in the admin mostly, to easily add a 2 column setting/value that uses the leftColumn rightColumn classes, and alternates the colors for you.

Arguments

Name Type Description Default
$option string

the right (or only) column/setting name

$html_value string

The left column/setting value. If not specified, the $option will fill the entire width.

null
$eg string

Displayed below the option but smaller.

null
$change_color_or_class boolean

if false, won't alternate the row color before setting it.

true
$left_html string

Don't use this, it's stupid

''
$right_html string

Don't use this one either!

''
$id string

Probably the id for the option

''

Return value

Type Description
string All the html needed to add the setting/value to the page

Tags

Name Description
deprecated Feb 19, 2013 7.1.1 - don't use this

addSaveButton( string   $url = null, string   $id = null, ) : string

Description

Generates a save button for admin pages

Arguments

Name Type Description Default
$url string null
$id string null

Return value

Type Description
string

addThreeColumnHeader( string   $col1 = null, string   $col2 = null, string   $col3 = null, ) : string

Description

Add a 3 column heading, this may be removed soon.

Arguments

Name Type Description Default
$col1 string null
$col2 string null
$col3 string null

Return value

Type Description
string

addThreeColumnRow(   $col1 = null,   $col2 = null,   $col3 = null,   $id = null, ) : string

Description

I don't even know what this does. Something to do with columns and rows and the number 3.

Arguments

Name Type Description Default
$col1 n/a null
$col2 n/a null
$col3 n/a null
$id n/a null

Return value

Type Description
string

addTwoColumnHeader( ) : string

Description

Not really a header, but a heading (we may be re-naming this soon). Pass in some stuff to put in a 2 column heading.

Return value

Type Description
string The HTML to use to display said heading.

adminGetRowColor( int   $default = 1, boolean   $change_color = true, ) : string

Description

Gets the class name for a row color to be used in the admin in an HTML element. Automatically alternates between row_color1 and row_color2.

Arguments

Name Type Description Default
$default int

If you want to change it so that the first row is row_color2, set this to 2

1
$change_color boolean

if set to false, the row class will not be alternated before returning it.

true

Return value

Type Description
string

dateSelect( array   $fields, array   $labels = array(), int   $timestamp = 0, array   $values = array(), bool   $isPlacementEndTime = false, ) : String

Description

SMARTY version of the multi-dropdown date selects

Arguments

Name Type Description Default
$fields array

"name" attributes of the select fields. Required indecies: year, month, day, hour, minute

$labels array

text labels for each dropdown. optional. Required indecies: year, month, day, hour, minute

array()
$timestamp int

ticktime to set all dropdowns. overrides individual settings in $values param.

0
$values array

starting values of the select fields. Required indecies: year, month, day, hour, minute. Only used if $timestamp = 0

array()
$isPlacementEndTime bool

special-case used to assign ID parameter to endtime fields during listing placement

false

Return value

Type Description
String HTML select dropdowns from template

fieldset( string   $html = '', string   $legend = '', string   $id = '', ) : string

Description

Wraps some HTML in a fieldset, handy if you are feeling particularly lazy.

Arguments

Name Type Description Default
$html string ''
$legend string ''
$id string ''

Return value

Type Description
string

getArrayDropDown( \unknown_type   $id = 'dropdown', \unknown_type   $input = array(), \unknown_type   $selected = 0, \unknown_type   $style = '', ) : \unknown

Description

Generate a dropdown within an array

Arguments

Name Type Description Default
$id \unknown_type 'dropdown'
$input \unknown_type array()
$selected \unknown_type 0
$style \unknown_type ''

Return value

Type Description
\unknown

getNumericDropDown( \unknown_type   $id = 'numeric', \unknown_type   $start = 0, \unknown_type   $len = 100, \unknown_type   $selected = 0, \unknown_type   $style = '', ) : \unknown

Description

Generate a numeric drop down

Arguments

Name Type Description Default
$id \unknown_type 'numeric'
$start \unknown_type 0
$len \unknown_type 100
$selected \unknown_type 0
$style \unknown_type ''

Return value

Type Description
\unknown

input( string   $type, string   $id_name, string   $default_value = '', ) : n/a

Description

Generare an html element

Arguments

Name Type Description Default
$type string
$id_name string
$default_value string ''

Return value

Type Description
n/a n/a

resetRowColor( ) : n/a

Description

Reset automatic color switchers to starting color, for use between groups of admin switches.

Return value

Type Description
n/a n/a

separator( ) : string

Description

Gives you a line looking thingy similar to an
but using a div because I guess we're too good for
's.

Return value

Type Description
string

showTooltip( string   $title, string   $text, ) : string

Description

Displays the little question mark icon with the tooltip specified elsewhere.

Arguments

Name Type Description Default
$title string

The title of the tooltip

$text string

The text to display, HTML allowed

Return value

Type Description
string HTML to put in your page to display the tooltip.

Properties

$_getRowColorCurrentColor,

int  private  static $_getRowColorCurrentColor =

Used by get row color function, to allow alternating colors.

1 or 2




Documentation was generated by phpDocumentor 2.2.0 .

Namespaces

  • global

    Packages

    • Default
      • ExampleAddon
        • addon_example_admin
          In charge of doing stuff on the admin side, this is optional.
        • addon_example_info
          Required class for addons, this is the Addon information class, used by the addon system to determine what the addon can do. Also contains info about the addon that can be viewed in the addon management page in the admin.
        • addon_example_pages
          Addon page class, used by the addon system to display pages on the client side.
        • addon_example_setup
          This class is not required. If it, and the function for a particular routine exist, then that function will be called IN ADDITION TO the automated routines of the addon framework.
        • addon_example_tags
          Expects one function for each tag. Function name should be the same as the tag name. Can also have a constructor if anything needs to be constructed.
        • addon_example_util
          This is where to put functions that the main part of the addon will use.
        • eWidgetOrderItem
          This order item is designed to allow users on your site to purchase an eWidget.
      • System
        • DataAccess
          This is the main Database access object.
        • Singleton
          Singleton method class
        • _templateOrderItem
          Developers: use this file as a template to create a new order item.
        • _templatePaymentGateway
          This is the "developer template" payment gateway handler, a developer could use this file as a starting point for creating a new payment gateway in the system.
        • geoAPI
          The main system class for receiving and handling remote API calls, this acts as a translation layer between the communication with the "outside" and each API call.
        • geoAddon
          This is the class that handles anything and everything to do with addons.
        • geoArrayTools
          Utility functions for manipulating arrays
        • geoBrowse
          Contains functions common to browsing listings
        • geoBrowsingFilter
          System for activating, storing, and deactivating browsing filters.
        • geoCJAX
          Class that wraps the CJAX_FRAMEWORK, used to get the CJAX class.
        • geoCache
          This is the main part of the Geo cache system, it does all the "low level" stuff like writing files and escaping cache data.
        • geoCacheModule
          Part of Geo Cache system, specifically tuned to work best with cacheing module data (which will be an array).
        • geoCachePage
          Cache system specifically tuned to work best with cacheing output of pages and modules
        • geoCacheSetting
          Part of Geo Cache system, specifically tuned to work best with cacheing site-wide key=value type settings.
        • geoCacheText
          Part of Geo Cache system, this part specifically tuned to work best with cacheing language specific messages.
        • geoCalendar
          Holds utility method(s) for manipulating stuff dealing with calendar selector.
        • geoCart
          This class is behind the cart, loading all the order items and such and displaying, and processing all the different pages.
        • geoCategory
          Utility class that holds various methods to do stuff with categories in the system.
        • geoCombineResources
          This class helps to combine CSS and JS files, minify them, and optionally compress them.
        • geoCron
          This is the cron job backend, it handles all the communication and security and all that.
        • geoCrypt
          Class to use for encrypting information that needs to be able to be retrieved later.
        • geoDate
          Holds utility method(s) for manipulating stuff dealing with dates.
        • geoEmail
          Class that sends out e-mails.
        • geoFields
          Class that holds settings information for fields to use.
        • geoFieldsField
          A mini object to hold data about a specific field.
        • geoFile
          As the name implies, this is used for file-based utility methods.
        • geoFilter
          A few utility methods, good for filtering stuff.
        • geoFormatString
          Used to display a message nice and pretty, we'll probably be getting rid of this class though so don't go crazy using it.
        • geoHTML
          Class to generate chunks of HTML that are very common, used the most in the admin panel.
        • geoImage
          This class is responsible for a lot of the image processing, along with other aspects like generating the image tag for thumbnails.
        • geoInvoice
          This is the invoice object representing an invoice in the system.
        • geoLeveledField
          Class for doing common things with leveled fields.
        • geoListing
          A listing object, basically a container object for particular listing.
        • geoListingDisplay
          This is basically a container that is responsible for helping to display {listing .
        • geoListingFeed
          Class that helps to render RSS or other types of feeds based on list of listings.
        • geoMaster
          This is dedicated class for getting the value of, and setting, the various "master switches" within the software. Since this is meant as an easy way to get the values of master switches, most of the methods are static.
        • geoNumber
          Utility functions relating to number conversion/manipulation/validation ect.
        • geoOrder
          The geoOrder object, an object representation of an order in the system.
        • geoOrderItem
          The class that all order items must extend.
        • geoPC
          Used for login credential validation, password hashing, etc. along with software licensing.
        • geoPagination
          Utility functions useful for generating pagination of a results page such as when browing ads or searching
        • geoPaymentGateway
          This class should be extended by each different payment gateway, this will have some default functions that each gateway will inherit, and also has a few final static methods used by the system to affect all order items.
        • geoPlanItem
          A container to hold settings for a particular order item type, according to price plan ID, and optionally category ID for category specific settings.
        • geoRecurringBilling
          The geoRecurringBilling object, an object representation of a recurring billing in the system.
        • geoRegion
          Stuff for regions and sub-regions.
        • geoRegistry
          Handy little object, can be used to set registry type settings.
        • geoSearchUtils
          Class for search utilities.
        • geoSellerBuyer
          Handles back-end for the seller/buyer payment gateways, to allow the buyer to more easily pay the seller for a won auction. This handles the underlying system, but the actual work is done by individual seller/buyer gateways, for instance the Paypal buy-now functionality.
        • geoSession
          Manages session storage and session cookies for user sessions.
        • geoString
          Utility functions relating to languages and string manipulation.
        • geoStringData
          This class is to store accented chars, to be used by {@link geoString::removeAccents()}, mainly to keep the String.class.php file un-cluttered.
        • geoTable
          NOT FULLY IMPLEMENTED! Do not use this class yet as it is not finished and may change drastically before we are done with it, or may even be removed.
        • geoTableRow
          NOT FULLY IMPLEMENTED! Do not use this class yet as it is not finished and may change drastically before we are done with it, or may even be removed.
        • geoTableRowset
          NOT FULLY IMPLEMENTED! Do not use this class yet as it is not finished and may change drastically before we are done with it, or may even be removed.
        • geoTableSelect
          Class used to generate a select query, useful when multiple areas want to affect a single query, for instance when generating a search query and there are addons involved.
        • geoTables
          Used to hold database table names, used throughout the code.
        • geoTemplate
          Template object that extends the Smarty class (a 3rd party library) to enable using templates to display things.
        • geoTransaction
          This is the object used for a transaction in the order and invoice system.
        • geoUser
          An object representative of a certain user in the system.
        • geoUserRating
          Store, retrieve, and display inter-user ratings
        • geoUtil
          Misc utility functions
        • geoView
          As the name implies, this is used for creating the page view. It does take a little setup (like any class), the setup is normally done in the display_page method in geoSite, or display_page in geoAdmin if displaying a page in the admin.
        • iApiTransport
          Interface for API Transports, a transport must implement this interface for the system to use it.
        • iOrderItem
          You cannot have abstract static functions, so instead need to have an interface to force the given static functions to be defined.
        • metaDbTables
          Used so that old locations that use the old name geoTables will still work.