reverted change from r5603 (Fixed bug #11358: typoLink() perfomance improvement)...
authorIngo Renner <ingo.renner@typo3.org>
Sun, 21 Jun 2009 12:09:14 +0000 (12:09 +0000)
committerIngo Renner <ingo.renner@typo3.org>
Sun, 21 Jun 2009 12:09:14 +0000 (12:09 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/branches/TYPO3_4-2@5604 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_page.php

index ee36e4a..edf8afc 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,3 @@
-2009-06-21  Rupert Germann  <rupi@gmx.li>
-
-       * Fixed bug #11358: typoLink() perfomance improvement (thanks to Vladimir Podkovanov)
-
 2009-05-18  Oliver Hader  <oliver@typo3.org>
 
        * Fixed bug #11009: External Links get prepended with http://typo3 in the RTEhtmlarea in Firefox 3.0.11/3.5b4
index 700817e..2dba7e7 100755 (executable)
@@ -125,8 +125,6 @@ class t3lib_pageSelect {
                // Internal caching
        protected $cache_getRootLine = array();
        protected $cache_getPage = array();
-       protected $cache_getPage_noCheck = array();
-       protected $cache_getPageIdFromAlias = array();
        protected $cache_getMountPointInfo = array();
 
        /**
@@ -212,26 +210,20 @@ class t3lib_pageSelect {
         * Return the $row for the page with uid = $uid WITHOUT checking for ->where_hid_del (start- and endtime or hidden). Only "deleted" is checked!
         *
         * @param       integer         The page id to look up
-        * @return      array           The page row with overlayed localized fields. Empty array if no page.
+        * @return      array           The page row with overlayed localized fields. Empty it no page.
         * @see getPage()
         */
        function getPage_noCheck($uid)  {
-               if ($this->cache_getPage_noCheck[$uid]) {
-                       return $this->cache_getPage_noCheck[$uid];
-               }
                $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'pages', 'uid='.intval($uid).$this->deleteClause('pages'));
                $row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);
                $GLOBALS['TYPO3_DB']->sql_free_result($res);
                if ($row)       {
                        $this->versionOL('pages',$row);
                        if (is_array($row))     {
-                               $row = $this->getPageOverlay($row);
-                               $this->cache_getPage_noCheck[$uid] = $row;
-                               return $row;
+                               return $this->getPageOverlay($row);
                        }
                }
-               $this->cache_getPage_noCheck[$uid] = array();
-               return array();
+               return Array();
        }
 
        /**
@@ -264,17 +256,12 @@ class t3lib_pageSelect {
         */
        function getPageIdFromAlias($alias)     {
                $alias = strtolower($alias);
-               if ($this->cache_getPageIdFromAlias[$alias]) {
-                       return $this->cache_getPageIdFromAlias[$alias];
-               }
                $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid', 'pages', 'alias='.$GLOBALS['TYPO3_DB']->fullQuoteStr($alias, 'pages').' AND pid>=0 AND pages.deleted=0');  // "AND pid>=0" because of versioning (means that aliases sent MUST be online!)
                $row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);
                $GLOBALS['TYPO3_DB']->sql_free_result($res);
                if ($row)       {
-                       $this->cache_getPageIdFromAlias[$alias] = $row['uid'];
                        return $row['uid'];
                }
-               $this->cache_getPageIdFromAlias[$alias] = 0;
                return 0;
        }