cpm_daoThis object handles all database transactions with the backend
Located in /cpmfetch_dao.php (line 22)
| Class | Description |
|---|---|
cpm
|
CpmFetch allows you to easily access and display information from your Coppermine Photo Gallery (CPG) in a variety of ways. CpmFetch respects the privacy settings in your gallery and will not display images the public would not be allowed to see normally. |
mixed
$cfCfg
(line 31)
mixed
$cfDefaultComments
(line 34)
mixed
$dbconnection
= "" (line 28)
mixed
$filetypefilter
= "" (line 46)
mixed
$lastSQLErrorMessage
= "" (line 40)
mixed
$lastSQLRowsReturned
= "" (line 37)
mixed
$privacyfilter
= "" (line 43)
mixed
$resultArray
= "" (line 64)
This holds the results array as provided by the SQL call
mixed
$sqlPostSelect
= "" (line 58)
mixed
$sqlSelect
= "" (line 49)
mixed
$sqlTableSelect
= "" (line 52)
mixed
$sqlUserDataLink
= "" (line 55)
mixed
$VERSION
= "@@@RELEASEVERSION@@@" (line 25)
Constructor cpm_dao (line 74)
addPathInfo (line 1365)
Take an array of rows and add in tags for thumbnail, normal and large image paths
cpm_debugMode (line 207)
Toggles cpmFetch into a debug mode (default: returns setting)
Actives some extra output for troubleshooting. Debug data is output as HTML comments or blockquotes
cpm_getConfigEntry (line 304)
Returns a named config variable.
This will return anything in the cpg settings table with the exception of those deemed a security risk (dbname, dbpass, bridge info, etc...)
cpm_setDateFormat (line 287)
Sets the format as seen in the php DATE function to be used in rendering dates
Sets the format as seen in the php DATE function to be used in rendering dates. For more information on the kinds of date strings you can use check http://www.php.net/manual/en/function.date.php
cpm_setFilter (line 170)
Limits what types of media can be selected by this program
Allows you to specify a list of extensions that are allowable for displaying. Types not explicity identified are omitted from results. The format for submitting file types is an array of extensions. such as array(".jpg",".avi"). There is a limit as matches will be made against the lower case and upper case versions of the types. If you have only one type, you may specifiy it as a string instead of an array.
cpm_setMediaPrefixes (line 271)
Allows you to change the default media prefixes settings for large are now ignored since cpg does not support it
cpm_unlock_private (line 248)
Toggles access to non-public photos (default: false)
Allows images not publically available to be selected and displayed until it is turned off, or the object is recreated. This program makes no distinction beyond if a media item is public or not.
createDescription (line 1584)
createlink (line 1559)
Creates the href and img tags to be displayed
createOldFormatDescription (line 1674)
dbConnect (line 1267)
Creates a connection to the gallery database
If
dbDisconnect (line 1301)
Calls a mysql_close on the current db connection.
This will close the db connection, unless you are running PHP >= 4.2.0 and have CpmFetch configured to use an existing db connection (cfUseExistingDBConnection), in which case it will not close it at all.
dbExecuteSql (line 1318)
debugPrint (line 232)
destroy (line 154)
formatStats (line 942)
Provides shortcuts into different function that return data
The format is specified by placeholders indicated by percent signs '%'. If you actually want a percent sign you will need to put two percent signs in a row '%%'. The most up to date list for supported placeholders can be found in the coppermine_dao formatStats function. But the main ones are:
getAlbumCount (line 424)
Returns the number of albums in the database.
getAlbumListFrom (line 516)
getCategoryCount (line 474)
Returns the number of categories in the CPG database
getCategoryListFrom (line 545)
getCommentCount (line 442)
Returns the number of comments in the CPG database
getdefaultimagename (line 1452)
getImageToUse (line 1387)
The following methods are not data access per say, but do provide data back independing of formatting, and I did not want to include another file...
getLastAddedMediaFrom (line 744)
getLastImagesWithComments (line 851)
getLastUpdatedAlbumsFrom (line 777)
getMediaAddedSince (line 905)
Returns a report of media added since a timestamp
getMediaAddedToCategoriesSince (line 879)
Returns a report of media added since a timestamp
getMediaByPid (line 491)
getMediaCount (line 335)
getMediaCountAddedSince (line 401)
getMediaCountForAlbum (line 378)
getMediaCountFrom (line 353)
getMostVotedMediaFrom (line 602)
getRandomImageFrom (line 816)
Returns a random image from a category in cpm
getRandomMostViewedMediaFrom (line 692)
getRandomSeed (line 1793)
getRandomTopRatedMediaFrom (line 635)
getTopRatedMediaFrom (line 572)
getViewcount (line 455)
Returns the total views across the entire CPG database
makeSourceSql (line 995)
urlEncodeImagePath (line 1437)
Documentation generated on Fri, 22 Jun 2007 10:18:21 -0400 by phpDocumentor 1.3.0