Widok prosty Przejdź do komentarzy ] Widok zaawansowany ] Historia zagadnienia ] Drukuj ]
Identyfikator Kategoria Ważność Powtarzalność Data zgłoszenia Data modyfikacji
0000051 [Typogento] Bug upadek zawsze 2011-06-29 11:46 2011-09-13 09:39
Zgłaszający heob Widoczność publiczny  
Przypisany do Frederic Gaus
Priorytet normalny Rozwiązanie poprawiony  
Stan rozwiązany  
Temat 0000051: Error 404 Page not found - Whoops you are bad
Opis There is a bug in class.tx_fbmagento_pi1.php.
If you insert the typogento plugin on a page and you delete it later on, typogento will not find a page and in bad case it will report an error 404.
typogento will also process deleted records on a page because there is an error in the sql query.
it costet me 2 days to find the problem :-) ... i hope it could help to anyone.


the error is on line 159 in class.tx_fbmagento_pi1.php

replace:
$rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows('pi_flexform', 'tt_content', 'pid=\''.$GLOBALS ['TSFE']->id.'\' AND list_type=\'fb_magento_pi1\' '.$this->cObj->enableFields('tt_content'), 'sorting');


to
$rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows('pi_flexform', 'tt_content', 'pid=\''.$GLOBALS ['TSFE']->id.'\' and deleted = 0 AND list_type=\'fb_magento_pi1\' '.$this->cObj->enableFields('tt_content'), 'sorting');
Dodatkowe informacje
Tagi Brak powiązanych tagów.
Dołączone pliki

- Powiązania

-  Komentarze
(0000120)
Frederic Gaus (zarządca)
2011-09-09 18:41

"If you insert the typogento plugin on a page and you delete it later on, typogento will not find a page and in bad case it will report an error 404."

Sorry, but I don't understand exactly what you mean. So I can not reproduce this error. Could you please try to explain the steps to reproduce this error?
(0000122)
Frederic Gaus (zarządca)
2011-09-09 18:44

"typogento will also process deleted records on a page because there is an error in the sql query."

I don't know what went wrong here. Maybe there is something very stange going on in your TYPO3 installation. The deleted field is respected by cObj->enableFields function.

Anyhow, I tried to reproduce this error and debugged the SQL-Query:

SELECT pi_flexform FROM tt_content WHERE pid='20' AND list_type='fb_magento_pi1' AND tt_content.deleted=0 AND tt_content.t3ver_state<=0 AND tt_content.pid!=-1 AND tt_content.hidden=0 AND tt_content.starttime<=1315586160 AND (tt_content.endtime=0 OR tt_content.endtime>1315586160) AND (tt_content.fe_group='' OR tt_content.fe_group IS NULL OR tt_content.fe_group='0' OR FIND_IN_SET('0',tt_content.fe_group) OR FIND_IN_SET('-1',tt_content.fe_group)) GROUP BY sorting

As you can see, tt_content.deleted=0 is present.
(0000127)
heob (zgłaszający)
2011-09-12 22:26

hi Frederic,

i added the deleted = 0 to the sql query .. maybe it is resolved in later versions .. but it was not present up to that time i inserted it.

the problem is, that the sql query also find's delted records because deleted = 0 was not present before my change.

regards
(0000128)
Frederic Gaus (zarządca)
2011-09-13 09:39

Hello heob,

ok, this seems to be fixed now.

Regards,
Frederic

- Historia zagadnienia
Data modyfikacji Nazwa użytkownika Pole Zmiana
2011-06-29 11:46 heob Nowe Zagadnienie
2011-09-09 18:41 Frederic Gaus Dodano komentarz: 0000120
2011-09-09 18:44 Frederic Gaus Dodano komentarz: 0000122
2011-09-12 22:26 heob Dodano komentarz: 0000127
2011-09-13 09:39 Frederic Gaus Dodano komentarz: 0000128
2011-09-13 09:39 Frederic Gaus Stan nowy => rozwiązany
2011-09-13 09:39 Frederic Gaus Rozwiązanie otwarty => poprawiony
2011-09-13 09:39 Frederic Gaus Przypisany do => Frederic Gaus


Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker