clickMenu Class Reference

List of all members.

Public Member Functions

 init ()
 doDisplayTopFrameCM ()
 printDBClickMenu ($table, $uid)
 printNewDBLevel ($table, $uid)
 externalProcessingOfDBMenuItems ($menuItems)
 processingByExtClassArray ($menuItems, $table, $uid)
 urlRefForCM ($url, $retUrl='', $hideCM=1, $overrideLoc='')
 DB_copycut ($table, $uid, $type)
 DB_paste ($table, $uid, $type, $elInfo)
 DB_info ($table, $uid)
 DB_history ($table, $uid)
 DB_perms ($table, $uid, $rec)
 DB_db_list ($table, $uid, $rec)
 DB_moveWizard ($table, $uid, $rec)
 DB_newWizard ($table, $uid, $rec)
 DB_editAccess ($table, $uid)
 DB_editPageHeader ($uid)
 DB_editPageProperties ($uid)
 DB_edit ($table, $uid)
 DB_new ($table, $uid)
 DB_delete ($table, $uid, $elInfo)
 DB_view ($id, $anchor='')
 DB_tempMountPoint ($page_id)
 DB_hideUnhide ($table, $rec, $hideField)
 DB_changeFlag ($table, $rec, $flagField, $title, $name, $iconRelPath='gfx/')
 printFileClickMenu ($path)
 externalProcessingOfFileMenuItems ($menuItems)
 FILE_launch ($path, $script, $type, $image)
 FILE_copycut ($path, $type)
 FILE_delete ($path)
 FILE_paste ($path, $target, $elInfo)
 printDragDropClickMenu ($table, $srcId, $dstId)
 externalProcessingOfDragDropMenuItems ($menuItems)
 dragDrop_copymovepage ($srcUid, $dstUid, $action, $into)
 dragDrop_copymovefolder ($srcPath, $dstPath, $action)
 printItems ($menuItems, $item)
 printLayerJScode ($menuItems)
 wrapColorTableCM ($str)
 menuItemsForTopFrame ($menuItems)
 menuItemsForClickMenu ($menuItems)
 addMenuItems ($menuItems, $newMenuItems, $position='')
 linkItem ($str, $icon, $onClick, $onlyCM=0, $dontHide=0)
 excludeIcon ($iconCode)
 enableDisableItems ($menuItems)
 cleanUpSpacers ($menuItems)
 label ($label)
 isCMlayers ()
 frameLocation ($str)

Public Attributes

 $cmLevel = 0
 $CB
 $backPath = ''
 $PH_backPath = '###BACK_PATH###'
 $listFrame = 0
 $isDBmenu = 0
 $alwaysContentFrame = 0
 $iParts = array()
 $disabledItems = array()
 $dontDisplayTopFrameCM = 0
 $leftIcons = 0
 $extClassArray = array()
 $ajax = 0
 $elCount = 0
 $editPageIconSet = 0
 $editOK = 0
 $rec = array()


Detailed Description

Definition at line 136 of file alt_clickmenu.php.


Member Function Documentation

clickMenu::init (  ) 

Initialize click menu

Returns:
string The clickmenu HTML content

Definition at line 168 of file alt_clickmenu.php.

clickMenu::doDisplayTopFrameCM (  ) 

Returns true if the menu should (also?) be displayed in topframe, not just

-layers

Returns:
boolean

Definition at line 222 of file alt_clickmenu.php.

clickMenu::printDBClickMenu ( table,
uid 
)

Make 1st level clickmenu:

Parameters:
string Table name
integer UID for the current record.
Returns:
string HTML content

Definition at line 254 of file alt_clickmenu.php.

clickMenu::printNewDBLevel ( table,
uid 
)

Make 2nd level clickmenu (only for DBmenus)

Parameters:
string Table name
integer UID for the current record.
Returns:
string HTML content

Definition at line 349 of file alt_clickmenu.php.

clickMenu::externalProcessingOfDBMenuItems ( menuItems  ) 

Processing the $menuItems array (for extension classes) (DATABASE RECORDS)

Parameters:
array $menuItems array for manipulation.
Returns:
array Processed $menuItems array

Definition at line 386 of file alt_clickmenu.php.

clickMenu::processingByExtClassArray ( menuItems,
table,
uid 
)

Processing the $menuItems array by external classes (typ. adding items)

Parameters:
array $menuItems array for manipulation.
string Table name
integer UID for the current record.
Returns:
array Processed $menuItems array

Definition at line 398 of file alt_clickmenu.php.

clickMenu::urlRefForCM ( url,
retUrl = '',
hideCM = 1,
overrideLoc = '' 
)

Returning JavaScript for the onClick event linking to the input URL.

Parameters:
string The URL relative to TYPO3_mainDir
string The return_url-parameter
boolean If set, the "hideCM()" will be called
string If set, gives alternative location to load in (for example top frame or somewhere else)
Returns:
string JavaScript for an onClick event.

Definition at line 418 of file alt_clickmenu.php.

clickMenu::DB_copycut ( table,
uid,
type 
)

Adding CM element for Clipboard "copy" and "cut"

Parameters:
string Table name
integer UID for the current record.
string Type: "copy" or "cut"
Returns:
array Item array, element in $menuItems

Definition at line 435 of file alt_clickmenu.php.

clickMenu::DB_paste ( table,
uid,
type,
elInfo 
)

Adding CM element for Clipboard "paste into"/"paste after" NOTICE: $table and $uid should follow the special syntax for paste, see clipboard-class :: pasteUrl();

Parameters:
string Table name
integer UID for the current record. NOTICE: Special syntax!
string Type: "into" or "after"
array Contains instructions about whether to copy or cut an element.
Returns:
array Item array, element in $menuItems
See also:
t3lib_clipboard::pasteUrl()

Definition at line 464 of file alt_clickmenu.php.

clickMenu::DB_info ( table,
uid 
)

Adding CM element for Info

Parameters:
string Table name
integer UID for the current record.
Returns:
array Item array, element in $menuItems

Definition at line 489 of file alt_clickmenu.php.

clickMenu::DB_history ( table,
uid 
)

Adding CM element for History

Parameters:
string Table name
integer UID for the current record.
Returns:
array Item array, element in $menuItems

Definition at line 505 of file alt_clickmenu.php.

clickMenu::DB_perms ( table,
uid,
rec 
)

Adding CM element for Permission setting

Parameters:
string Table name
integer UID for the current record.
array The "pages" record with "perms_*" fields inside.
Returns:
array Item array, element in $menuItems

Definition at line 524 of file alt_clickmenu.php.

clickMenu::DB_db_list ( table,
uid,
rec 
)

Adding CM element for DBlist

Parameters:
string Table name
integer UID for the current record.
array Record of the element (needs "pid" field if not pages-record)
Returns:
array Item array, element in $menuItems

Definition at line 543 of file alt_clickmenu.php.

clickMenu::DB_moveWizard ( table,
uid,
rec 
)

Adding CM element for Moving wizard

Parameters:
string Table name
integer UID for the current record.
array Record. Needed for tt-content elements which will have the sys_language_uid sent
Returns:
array Item array, element in $menuItems

Definition at line 562 of file alt_clickmenu.php.

clickMenu::DB_newWizard ( table,
uid,
rec 
)

Adding CM element for Create new wizard (either db_new.php or sysext/cms/layout/db_new_content_el.php or custom wizard)

Parameters:
string Table name
integer UID for the current record.
array Record.
Returns:
array Item array, element in $menuItems

Definition at line 583 of file alt_clickmenu.php.

clickMenu::DB_editAccess ( table,
uid 
)

Adding CM element for Editing of the access related fields of a table (disable, starttime, endtime, fe_groups)

Parameters:
string Table name
integer UID for the current record.
Returns:
array Item array, element in $menuItems

Definition at line 606 of file alt_clickmenu.php.

clickMenu::DB_editPageHeader ( uid  ) 

Adding CM element for edit page header

Parameters:
integer page uid to edit (PID)
Returns:
array Item array, element in $menuItems

Definition at line 625 of file alt_clickmenu.php.

clickMenu::DB_editPageProperties ( uid  ) 

Adding CM element for edit page properties

Parameters:
integer page uid to edit (PID)
Returns:
array Item array, element in $menuItems

Definition at line 636 of file alt_clickmenu.php.

clickMenu::DB_edit ( table,
uid 
)

Adding CM element for regular editing of the element!

Parameters:
string Table name
integer UID for the current record.
Returns:
array Item array, element in $menuItems

Definition at line 654 of file alt_clickmenu.php.

clickMenu::DB_new ( table,
uid 
)

Adding CM element for regular Create new element

Parameters:
string Table name
integer UID for the current record.
Returns:
array Item array, element in $menuItems

Definition at line 696 of file alt_clickmenu.php.

clickMenu::DB_delete ( table,
uid,
elInfo 
)

Adding CM element for Delete

Parameters:
string Table name
integer UID for the current record.
array Label for including in the confirmation message, EXT:lang/locallang_core.php:mess.delete
Returns:
array Item array, element in $menuItems

Definition at line 721 of file alt_clickmenu.php.

clickMenu::DB_view ( id,
anchor = '' 
)

Adding CM element for View Page

Parameters:
integer Page uid (PID)
string Anchor, if any
Returns:
array Item array, element in $menuItems

Definition at line 747 of file alt_clickmenu.php.

clickMenu::DB_tempMountPoint ( page_id  ) 

Adding element for setting temporary mount point.

Parameters:
integer Page uid (PID)
Returns:
array Item array, element in $menuItems

Definition at line 762 of file alt_clickmenu.php.

clickMenu::DB_hideUnhide ( table,
rec,
hideField 
)

Adding CM element for hide/unhide of the input record

Parameters:
string Table name
array Record array
string Name of the hide field
Returns:
array Item array, element in $menuItems

Definition at line 779 of file alt_clickmenu.php.

clickMenu::DB_changeFlag ( table,
rec,
flagField,
title,
name,
iconRelPath = 'gfx/' 
)

Adding CM element for a flag field of the input record

Parameters:
string Table name
array Record array
string Name of the flag field
string Menu item Title
string Name of the item used for icons and labels
string Icon path relative to typo3/ folder
Returns:
array Item array, element in $menuItems

Definition at line 794 of file alt_clickmenu.php.

clickMenu::printFileClickMenu ( path  ) 

Make 1st level clickmenu:

Parameters:
string The absolute path
Returns:
string HTML content

Definition at line 828 of file alt_clickmenu.php.

clickMenu::externalProcessingOfFileMenuItems ( menuItems  ) 

Processing the $menuItems array (for extension classes) (FILES)

Parameters:
array $menuItems array for manipulation.
Returns:
array Processed $menuItems array

Definition at line 892 of file alt_clickmenu.php.

clickMenu::FILE_launch ( path,
script,
type,
image 
)

Multi-function for adding an entry to the $menuItems array

Parameters:
string Path to the file/directory (target)
string Script (eg. file_edit.php) to pass &target= to
string "type" is the code which fetches the correct label for the element from "cm."
string icon image-filename from "gfx/" (12x12 icon)
Returns:
array Item array, element in $menuItems

Definition at line 906 of file alt_clickmenu.php.

clickMenu::FILE_copycut ( path,
type 
)

Returns element for copy or cut of files.

Parameters:
string Path to the file/directory (target)
string Type: "copy" or "cut"
Returns:
array Item array, element in $menuItems

Definition at line 926 of file alt_clickmenu.php.

clickMenu::FILE_delete ( path  ) 

Creates element for deleting of target

Parameters:
string Path to the file/directory (target)
Returns:
array Item array, element in $menuItems

Definition at line 952 of file alt_clickmenu.php.

clickMenu::FILE_paste ( path,
target,
elInfo 
)

Creates element for pasting files.

Parameters:
string Path to the file/directory (target)
string target - NOT USED.
array Various values for the labels.
Returns:
array Item array, element in $menuItems

Definition at line 979 of file alt_clickmenu.php.

clickMenu::printDragDropClickMenu ( table,
srcId,
dstId 
)

Make 1st level clickmenu:

Parameters:
string The absolute path
integer UID for the current record.
integer Destination ID
Returns:
string HTML content

Definition at line 1016 of file alt_clickmenu.php.

clickMenu::externalProcessingOfDragDropMenuItems ( menuItems  ) 

Processing the $menuItems array (for extension classes) (DRAG'N DROP)

Parameters:
array $menuItems array for manipulation.
Returns:
array Processed $menuItems array

Definition at line 1058 of file alt_clickmenu.php.

clickMenu::dragDrop_copymovepage ( srcUid,
dstUid,
action,
into 
)

Adding CM element for Copying/Moving a Page Into/After from a drag & drop action

Parameters:
integer source UID code for the record to modify
integer destination UID code for the record to modify
string Action code: either "move" or "copy"
string Parameter code: either "into" or "after"
Returns:
array Item array, element in $menuItems

Definition at line 1073 of file alt_clickmenu.php.

clickMenu::dragDrop_copymovefolder ( srcPath,
dstPath,
action 
)

Adding CM element for Copying/Moving a Folder Into from a drag & drop action

Parameters:
string source path for the record to modify
string destination path for the records to modify
string Action code: either "move" or "copy"
Returns:
array Item array, element in $menuItems

Definition at line 1098 of file alt_clickmenu.php.

clickMenu::printItems ( menuItems,
item 
)

Prints the items from input $menuItems array - both as topframe menu AND the JS section for writing to the div-layers. Of course the topframe menu will appear only if $this->doDisplayTopFrameCM() returns true

Parameters:
array $menuItems array
string HTML code for the element which was clicked - shown in the end of the horizontal menu in topframe after the close-button.
Returns:
string HTML code

Definition at line 1134 of file alt_clickmenu.php.

clickMenu::printLayerJScode ( menuItems  ) 

Create the JavaScript section

Parameters:
array The $menuItems array to print
Returns:
string The JavaScript section which will print the content of the CM to the div-layer in the target frame.

Definition at line 1186 of file alt_clickmenu.php.

clickMenu::wrapColorTableCM ( str  ) 

Wrapping the input string in a table with background color 4 and a black border style. For the pop-up menu

Parameters:
string HTML content to wrap in table.
Returns:
string

Definition at line 1227 of file alt_clickmenu.php.

clickMenu::menuItemsForTopFrame ( menuItems  ) 

Traverses the menuItems and generates an output array for implosion in the topframe horizontal menu

Parameters:
array $menuItem array
array Array with HTML content to be imploded between

-tags

Returns:
array Array of menu items for top frame.

Definition at line 1250 of file alt_clickmenu.php.

clickMenu::menuItemsForClickMenu ( menuItems  ) 

Traverses the menuItems and generates an output array for implosion in the CM div-layers table.

Parameters:
array $menuItem array
array Array with HTML content to be imploded between

-tags

Returns:
array array for implosion in the CM div-layers table.

Definition at line 1267 of file alt_clickmenu.php.

clickMenu::addMenuItems ( menuItems,
newMenuItems,
position = '' 
)

Adds or inserts a menu item Can be used to set the position of new menu entries within the list of existing menu entries. Has this syntax: [cmd]:[menu entry key],[cmd].... cmd can be "after", "before" or "top" (or blank/"bottom" which is default). If "after"/"before" then menu items will be inserted after/before the existing entry with [menu entry key] if found. "after-spacer" and "before-spacer" do the same, but inserts before or after an item and a spacer. If not found, the bottom of list. If "top" the items are inserted in the top of the list.

Parameters:
array Menu items array
array Menu items array to insert
string Position command string. Has this syntax: [cmd]:[menu entry key],[cmd].... cmd can be "after", "before" or "top" (or blank/"bottom" which is default). If "after"/"before" then menu items will be inserted after/before the existing entry with [menu entry key] if found. "after-spacer" and "before-spacer" do the same, but inserts before or after an item and a spacer. If not found, the bottom of list. If "top" the items are inserted in the top of the list.
Returns:
array Menu items array, processed.

Definition at line 1305 of file alt_clickmenu.php.

clickMenu::linkItem ( str,
icon,
onClick,
onlyCM = 0,
dontHide = 0 
)

Creating an array with various elements for the clickmenu entry

Parameters:
string The label, htmlspecialchar'ed already
string -tag for the icon
string JavaScript onclick event for label/icon
boolean ==1 and the element will NOT appear in clickmenus in the topframe (unless clickmenu is totally unavailable)! ==2 and the item will NEVER appear in top frame. (This is mostly for "less important" options since the top frame is not capable of holding so many elements horizontally)
boolean If set, the clickmenu layer will not hide itself onclick - used for secondary menus to appear...
Returns:
array $menuItem entry with 6 numerical entries: [0] is the HTML for display of the element with link and icon an mouseover etc., [1]-[5] is simply the input params passed through!

Definition at line 1381 of file alt_clickmenu.php.

clickMenu::excludeIcon ( iconCode  ) 

Returns the input string IF not a user setting has disabled display of icons.

Parameters:
string The icon-image tag
Returns:
string The icon-image tag prefixed with space char IF the icon should be printed at all due to user settings

Definition at line 1410 of file alt_clickmenu.php.

clickMenu::enableDisableItems ( menuItems  ) 

Enabling / Disabling items based on list provided from GET var ($this->iParts[3])

Parameters:
array Menu items array
Returns:
array Menu items array, processed.

Definition at line 1420 of file alt_clickmenu.php.

clickMenu::cleanUpSpacers ( menuItems  ) 

Clean up spacers; Will remove any spacers in the start/end of menu items array plus any duplicates.

Parameters:
array Menu items array
Returns:
array Menu items array, processed.

Definition at line 1458 of file alt_clickmenu.php.

clickMenu::label ( label  ) 

Get label from locallang_core.php:cm.*

Parameters:
string The "cm."-suffix to get.
Returns:
string

Definition at line 1500 of file alt_clickmenu.php.

clickMenu::isCMlayers (  ) 

Returns true if there should be writing to the div-layers (commands sent to clipboard MUST NOT write to div-layers)

Returns:
boolean

Definition at line 1509 of file alt_clickmenu.php.

clickMenu::frameLocation ( str  ) 

Appends ".location" to input string

Parameters:
string Input string, probably a JavaScript document reference
Returns:
string

Definition at line 1523 of file alt_clickmenu.php.


The documentation for this class was generated from the following file:
This documentation has been generated automatically from TYPO3 source code using Doxygen and is provided as is by Cast Iron Coding as a courtesy to other TYPO3 developers and users. Please consider Cast Iron Coding — a full-service web development agency in Portland, Oregon specializing in TYPO3 extension development — for all of your TYPO3 development and consulting needs!