Back to Grid class

Method order

public static string
order
(mixed $rows, mixed $image = 'filesave.png', mixed $task = 'saveorder')
Method to create an icon for saving a new ordering in a grid
Parameters
  • array $rows The array of rows of rows
  • string $image The image [UNUSED]
  • string $task The task to use, defaults to save order
Returns
  • string
Since
  • 1.5
Class: Grid
Project: Joomla

Method order - Source code

/**
 * Method to create an icon for saving a new ordering in a grid
 *
 * @param   array   $rows   The array of rows of rows
 * @param   string  $image  The image [UNUSED]
 * @param   string  $task   The task to use, defaults to save order
 *
 * @return  string
 *
 * @since   1.5
 */
public static function order($rows, $image = 'filesave.png', $task = 'saveorder')
{
    return '<a href="javascript:saveorder(' . (count($rows) - 1) . ', \'' . $task . '\')" rel="tooltip" class="saveorder btn btn-sm btn-secondary float-end" title="' . Text::_('JLIB_HTML_SAVE_ORDER') . '"><span class="icon-sort"></span></a>';
}