[TYPO3-german] Re: zweiter datenbankaufruf innerhab eines newsindexers für ke_search

Ralf-Rene Schröder ralf.rene at online.de
Mon Jun 11 15:28:55 CEST 2012


gelöst... es fehlte ein lächerliches Komma (was ich hier in der Mail
sogar bei der Umformatierung wieder richtig drin hatte)
hier nochmal (für die Nachwelt in der Liste) der nun etwas überarbeitete
Codeblock:

// add news tags as searchtags
$newstags = '';
$tres = $GLOBALS['TYPO3_DB']->exec_SELECT_mm_query(
          'tx_news_domain_model_news.uid, tx_news_domain_model_tag.uid,
tx_news_domain_model_news_tag_mm.uid_local,
tx_news_domain_model_news_tag_mm.uid_foreign,
tx_news_domain_model_tag.title AS tx_news_domain_model_tag_title',
          'tx_news_domain_model_news',
          'tx_news_domain_model_news_tag_mm',
          'tx_news_domain_model_tag',
          'AND
tx_news_domain_model_news.uid=tx_news_domain_model_news_tag_mm.uid_local
AND
tx_news_domain_model_tag.uid=tx_news_domain_model_news_tag_mm.uid_foreign AND
tx_news_domain_model_news_tag_mm.uid_local='. $newsid,
          '',
          '',
          ''
          );
$tresCount = $GLOBALS['TYPO3_DB']->sql_num_rows($tres);
  if($tresCount) {
    while ($trecord = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($tres)) {
      $newstags .= ',' . $trecord['tx_news_domain_model_tag_title'];
   }
}
$tags .= $newstags;


-- 
image[FORMAT] - Ralf-René Schröder
http://image-format.eu ... Wir geben Ihrem Image das richtige Format
http://if-20.com  ... YAML templates for TYPO3


More information about the TYPO3-german mailing list