In dieser Extension werden maximal 20 Einträge auf einer Seite angezeigt. Ich möchte das ändern auf 10, finde aber den passenden Eintrag nicht.
Wer kann mir da helfen
In dieser Extension werden maximal 20 Einträge auf einer Seite angezeigt. Ich möchte das ändern auf 10, finde aber den passenden Eintrag nicht.
Wer kann mir da helfen
wenn das mal wer braucht, hier der entscheidende Codeausschnitt von class.tx_thpdfarchive_pi1.php.
function listView($content,$conf) {
global $TYPO3_CONF_VARS;
$this->conf=$conf; // Setting the TypoScript passed to this function in $this->conf
$this->pi_setPiVarDefaults();
$this->pi_loadLL(); // Loading the LOCAL_LANG values
$lConf = $this->conf['listView.']; // Local settings for the listView function
if ($this->piVars['showUid']) { // If a single element should be displayed:
$this->internal['currentTable'] = 'tx_thpdfarchive_document';
$this->internal['currentRow'] = $this->pi_getRecord('tx_thpdfarchive_document',$this->piVars['showUid']);
$content = $this->singleView($content,$conf);
return $content;
} else {
if (!isset($this->piVars['pointer'])) $this->piVars['pointer']=0;
if (!isset($this->piVars['mode'])) $this->piVars['mode']=0;
// Offset für LIMIT im SQL Select, bei 4 auszugebenden Datensätzen
$offset=$this->piVars['pointer']*4;
// EDIT by Steffen Ritter
// ShowAll Param of Flexform: if ShowAll is set, sYear will be left --> all files will be shown
// if ShowAll is not set sYear will be set to current year...
if (!isset($this->piVars['sYear']) && ($this->lConf['showAll'] == 0)) $this->piVars['sYear'] = date('Y',time());
$sorting = $this->piVars['sorting'] == '' ? 'DESC' : $this->piVars['sorting'];
$this->piVars['row'] = $this->piVars['row'] == '' ? 'date' : $this->piVars['row'];
// Initializing the query parameters:
list($this->internal['orderBy'],$this->internal['descFlag']) = explode(':',$this->piVars['sort']);
$this->internal['results_at_a_time']=t3lib_div::intInRange(4,0,1000,4); // Number of results to show in a listing (4).
$this->internal['maxPages']=t3lib_div::intInRange($lConf['maxPages'],0,1000,2);; // The maximum number of "pages" in the browse-box: "Page 1", "Page 2", etc.
$this->internal['searchFieldList']='title,teaser,date';
$this->internal['orderByList']='date';
// Get number of records:
$res = (isset($this->conf['code']) && $this->piVars['sYear'] != 0) ? $GLOBALS['TYPO3_DB']->exec_SELECTquery(
'count(*)',
'tx_thpdfarchive_document,tx_thpdfarchive_division',
$this->sqlWhere($this->conf['code'],$this->piVars['sYear'])
) : $GLOBALS['TYPO3_DB']->exec_SELECTquery('count(*)','tx_thpdfarchive_document,tx_thpdfarchive_division',$this->sqlWhere($this->conf['code'],''));
list($this->internal['res_count']) = $GLOBALS['TYPO3_DB']->sql_fetch_row($res);
$res = (isset($this->conf['code']) ) ? $GLOBALS['TYPO3_DB']->exec_SELECTquery(
'*','tx_thpdfarchive_document,tx_thpdfarchive_division',
$this->sqlWhere($this->conf['code'],$this->piVars['sYear']),'',$this->piVars['row'].' '.$sorting,$offset.',4'
) : $GLOBALS['TYPO3_DB']->exec_SELECTquery(
'*','tx_thpdfarchive_document,tx_thpdfarchive_division',
'','',$this->piVars['row'].' '.$sorting
);
$this->internal['currentTable'] = 'tx_thpdfarchive_document';
// Put the whole list together:
$fullTable=''; // Clear var;
$id = $GLOBALS['TSFE']->id;
$link = $this->pi_getPageLink($id);
....
Hallo Crossl,
die Steuerung müsste eigentlich über die Zeile 35 erfolgen. Nach diesen Einstellungen sollten nur 4 Datensätze pro ListView Seite ausgegeben werden.
Evtl. wird das irgendwo nochmals verändert, wenn bei dir 20 Datensätze pro Zeile ausgegeben werden.
Vieleicht hilft dir das ja erstmal weiter:
$this->internal['results_at_a_time']=t3lib_div::intInRange($lConf['results_at_a_time'],0,1000,10);
Gruß
Liquidblue