Actions

API16

JDatabaseQuery/order

From Joomla! Documentation

< API16:JDatabaseQuery
Revision as of 22:03, 12 May 2013 by JoomlaWikiBot (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Replacement filing cabinet.png
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.

[<! removed edit link to red link >]

<! removed transcluded page call, red link never existed >

Contents

Syntax

order($columns)
Parameter Name Default Value Description
$columns A string or array of ordering columns

Defined in

libraries/joomla/database/databasequery.php

Importing

jimport( 'joomla.database.databasequery' );

Source Body

public function order($columns)
{
        if (is_null($this->_order)) {
                $this->_order = new JDatabaseQueryElement('ORDER BY', $columns);
        } else {
                $this->_order->append($columns);
        }
 
        return $this;
}

[<! removed edit link to red link >] <! removed transcluded page call, red link never existed >

Examples

<CodeExamplesForm />

$query->from('`#__categories` AS a');           
$query->where('a.extension = "com_weblinks" and a.published = "1"');            
$query->order('a.title ASC');