JDatabase::loadObject: Difference between revisions
From Joomla! Documentation
Layout updates |
Updated to r1448:247ba8d88526 |
||
| Line 2: | Line 2: | ||
=={{JVer|11.1}} JDatabase::loadObject== | =={{JVer|11.1}} JDatabase::loadObject== | ||
===Description=== | ===Description=== | ||
Method to get the first row of the result set from the database query as an object. | |||
{{Description:JDatabase::loadObject}} | {{Description:JDatabase::loadObject}} | ||
| Line 8: | Line 8: | ||
<nowiki>[</nowiki>[[Description:JDatabase::loadObject|Edit Descripton]]<nowiki>]</nowiki> | <nowiki>[</nowiki>[[Description:JDatabase::loadObject|Edit Descripton]]<nowiki>]</nowiki> | ||
</span> | </span> | ||
<source lang="php"> | <source lang="php"> | ||
public | public function loadObject ($class= 'stdClass') | ||
</source> | </source> | ||
= | {| class="wikitable" | ||
|- | |||
!Parameter | |||
libraries/joomla/database/database.php | !Type | ||
* | !Default | ||
!Description | |||
|- | |||
|$class | |||
| | |||
|'stdClass' | |||
| | |||
|- | |||
|} | |||
* '''Returns''' mixed The return value or null if the query failed. | |||
* '''Defined''' on line 671 of libraries/joomla/database/database.php | |||
* '''Since''' {{JVer|11.1 }} | |||
===See also=== | ===See also=== | ||
* {{JVer|11.1}} '''JDatabase::loadObject source code''' on [[jplatform:database/database.php#cl-663|BitBucket]] | |||
* {{JVer|11.1}} Class [[JDatabase/11.1|JDatabase]] | |||
* {{JVer|11.1}} Subpackage [[Subpackage_Database/11.1|Database]] | |||
* [[JDatabase::loadObject|Other versions of JDatabase::loadObject]] | |||
{{SeeAlso:JDatabase::loadObject}} | |||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
<nowiki>[</nowiki>[[SeeAlso:JDatabase::loadObject|Edit See Also]]<nowiki>]</nowiki> | <nowiki>[</nowiki>[[SeeAlso:JDatabase::loadObject|Edit See Also]]<nowiki>]</nowiki> | ||
</span> | </span> | ||
===User contributed notes=== | |||
=== | |||
<CodeExamplesForm /> | <CodeExamplesForm /> | ||
<dpl> | <dpl> | ||
| Line 33: | Line 44: | ||
category=MethodExample | category=MethodExample | ||
include=* | include=* | ||
namespace=CodeExample | |||
format= ,,, | format= ,,, | ||
</dpl> | </dpl> | ||
<noinclude>[[Category:JDatabase]][[Category:JDatabase::loadObject]]</noinclude> | <noinclude>[[Category:JDatabase]][[Category:JDatabase::loadObject]]</noinclude> | ||
Revision as of 01:26, 28 April 2011
JDatabase::loadObject
Description
Method to get the first row of the result set from the database query as an object.
Template:Description:JDatabase::loadObject [Edit Descripton]
public function loadObject ($class= 'stdClass')
| Parameter | Type | Default | Description |
|---|---|---|---|
| $class | 'stdClass' |
- Returns mixed The return value or null if the query failed.
- Defined on line 671 of libraries/joomla/database/database.php
- Since

See also
JDatabase::loadObject source code on BitBucket
Class JDatabase
Subpackage Database- Other versions of JDatabase::loadObject
Template:SeeAlso:JDatabase::loadObject [Edit See Also]
User contributed notes
<CodeExamplesForm />