<?php include_once '../doc-typo3-funcs.php'; $doxygen_vars = array( "title" => "TYPO3 4.0.1: typo3_src-4.0.1/typo3/sysext/cms/layout/db_new_content_el.php Source File", "datetime" => "Sat Dec 2 19:22:27 2006", "date" => "2 Dec 2006", "doxygenversion" => "1.4.6", "projectname" => "TYPO3 4.0.1", "projectnumber" => "4.0.1" ); get_header($doxygen_vars); ?> <!-- Generated by Doxygen 1.4.6 --> <div class="tabs"> <ul> <li><a href="main.html"><span>Main Page</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="classes.html"><span>Classes</span></a></li> <li id="current"><a href="files.html"><span>Files</span></a></li> <li><a href="dirs.html"><span>Directories</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="examples.html"><span>Examples</span></a></li> <li> <form action="search.php" method="get"> <table cellspacing="0" cellpadding="0" border="0"> <tr> <td><label> <u>S</u>earch for </label></td> <td><input type="text" name="query" value="" size="20" accesskey="s"/></td> </tr> </table> </form> </li> </ul></div> <div class="nav"> <a class="el" href="dir_c8daf1ad746050abf985cc546c89e248.html">typo3_src-4.0.1</a> » <a class="el" href="dir_18071ae4545d8b3e0364d30c0659c74a.html">typo3</a> » <a class="el" href="dir_57bf1ed8249c1fd5b014486d01bcb27a.html">sysext</a> » <a class="el" href="dir_21aa24ee31dafa72450e939d0692a893.html">cms</a> » <a class="el" href="dir_fe9163c8c1bcebd3b932cd1f34a83105.html">layout</a></div> <h1>db_new_content_el.php</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <?php <a name="l00002"></a>00002 <span class="comment">/***************************************************************</span> <a name="l00003"></a>00003 <span class="comment">* Copyright notice</span> <a name="l00004"></a>00004 <span class="comment">*</span> <a name="l00005"></a>00005 <span class="comment">* (c) 1999-2005 Kasper Skaarhoj (kasperYYYY@typo3.com)</span> <a name="l00006"></a>00006 <span class="comment">* All rights reserved</span> <a name="l00007"></a>00007 <span class="comment">*</span> <a name="l00008"></a>00008 <span class="comment">* This script is part of the TYPO3 project. The TYPO3 project is</span> <a name="l00009"></a>00009 <span class="comment">* free software; you can redistribute it and/or modify</span> <a name="l00010"></a>00010 <span class="comment">* it under the terms of the GNU General Public License as published by</span> <a name="l00011"></a>00011 <span class="comment">* the Free Software Foundation; either version 2 of the License, or</span> <a name="l00012"></a>00012 <span class="comment">* (at your option) any later version.</span> <a name="l00013"></a>00013 <span class="comment">*</span> <a name="l00014"></a>00014 <span class="comment">* The GNU General Public License can be found at</span> <a name="l00015"></a>00015 <span class="comment">* http://www.gnu.org/copyleft/gpl.html.</span> <a name="l00016"></a>00016 <span class="comment">* A copy is found in the textfile GPL.txt and important notices to the license</span> <a name="l00017"></a>00017 <span class="comment">* from the author is found in LICENSE.txt distributed with these scripts.</span> <a name="l00018"></a>00018 <span class="comment">*</span> <a name="l00019"></a>00019 <span class="comment">*</span> <a name="l00020"></a>00020 <span class="comment">* This script is distributed in the hope that it will be useful,</span> <a name="l00021"></a>00021 <span class="comment">* but WITHOUT ANY WARRANTY; without even the implied warranty of</span> <a name="l00022"></a>00022 <span class="comment">* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span> <a name="l00023"></a>00023 <span class="comment">* GNU General Public License for more details.</span> <a name="l00024"></a>00024 <span class="comment">*</span> <a name="l00025"></a>00025 <span class="comment">* This copyright notice MUST APPEAR in all copies of the script!</span> <a name="l00026"></a>00026 <span class="comment">***************************************************************/</span> <a name="l00063"></a>00063 unset($MCONF); <a name="l00064"></a>00064 require('conf.php'); <a name="l00065"></a>00065 require($BACK_PATH.'init.php'); <a name="l00066"></a>00066 require($BACK_PATH.'<span class="keyword">template</span>.php'); <a name="l00067"></a>00067 <a name="l00068"></a>00068 <span class="comment">// Unset MCONF/MLANG since all we wanted was back path etc. for this particular script.</span> <a name="l00069"></a>00069 unset($MCONF); <a name="l00070"></a>00070 unset($MLANG); <a name="l00071"></a>00071 <a name="l00072"></a>00072 <span class="comment">// Merging locallang files/arrays:</span> <a name="l00073"></a>00073 $LANG->includeLLFile('EXT:lang/locallang_misc.xml'); <a name="l00074"></a>00074 $LOCAL_LANG_orig = $LOCAL_LANG; <a name="l00075"></a>00075 $LANG->includeLLFile('EXT:cms/layout/locallang_db_new_content_el.xml'); <a name="l00076"></a>00076 $LOCAL_LANG = <a class="code" href="classt3lib__div.html#3830505faadac8ae3b0fcb60077a2bf1">t3lib_div::array_merge_recursive_overrule</a>($LOCAL_LANG_orig,$LOCAL_LANG); <a name="l00077"></a>00077 <a name="l00078"></a>00078 <span class="comment">// Exits if 'cms' extension is not loaded:</span> <a name="l00079"></a>00079 <a class="code" href="classt3lib__extMgm.html#297116a3b1e17045ff193f170b8c4a29">t3lib_extMgm::isLoaded</a>('cms',1); <a name="l00080"></a>00080 <a name="l00081"></a>00081 <span class="comment">// Include needed libraries:</span> <a name="l00082"></a>00082 require_once(PATH_t3lib.'<span class="keyword">class</span>.t3lib_page.php'); <a name="l00083"></a>00083 require_once(PATH_t3lib.'<span class="keyword">class</span>.t3lib_positionmap.php'); <a name="l00084"></a>00084 <a name="l00085"></a>00085 <a name="l00086"></a>00086 <a name="l00087"></a>00087 <a name="l00088"></a>00088 <a name="l00089"></a>00089 <a name="l00090"></a>00090 <a name="l00091"></a>00091 <a name="l00092"></a>00092 <a name="l00093"></a>00093 <a name="l00101"></a>00101 <span class="keyword">class </span><a class="code" href="classext__posMap.html">ext_posMap</a> <span class="keyword">extends</span> <a class="code" href="classt3lib__positionMap.html">t3lib_positionMap</a> { <a name="l00102"></a>00102 var <a class="code" href="classext__posMap.html#04ccf7b798a5a8285e37bd3f9b2a3582">$dontPrintPageInsertIcons</a> = 1; <a name="l00103"></a>00103 <a name="l00111"></a><a class="code" href="classext__posMap.html#5a861df18e749c332d8d7e292febd0db">00111</a> function <a class="code" href="classext__posMap.html#5a861df18e749c332d8d7e292febd0db">wrapRecordTitle</a>($str,$row) { <a name="l00112"></a>00112 <span class="keywordflow">return</span> $str; <a name="l00113"></a>00113 } <a name="l00114"></a>00114 <a name="l00125"></a><a class="code" href="classext__posMap.html#6f39331351f4d1e046857bcb855194b3">00125</a> function <a class="code" href="classext__posMap.html#85bf4b6f6ef500faa1db0ede7aee4731">onClickInsertRecord</a>($row,$vv,<a class="code" href="classt3lib__positionMap.html#f52318668d290ea5d934c0caf801c892">$moveUid</a>,$pid,$sys_lang=0) { <a name="l00126"></a>00126 $table='tt_content'; <a name="l00127"></a>00127 <a name="l00128"></a>00128 $location=$this->backPath.'alt_doc.php?edit[tt_content]['.(is_array($row)?-$row['uid']:$pid).']=<span class="keyword">new</span>&defVals[tt_content][colPos]='.$vv.'&defVals[tt_content][sys_language_uid]='.$sys_lang.'&returnUrl='.rawurlencode($GLOBALS['SOBE']->R_URI); <a name="l00129"></a>00129 <a name="l00130"></a>00130 <span class="keywordflow">return</span> 'window.location.href=\''.$location.<span class="charliteral">'\'</span>+document.editForm.defValues.value; <span class="keywordflow">return</span> <span class="keyword">false</span>;'; <a name="l00131"></a>00131 } <a name="l00132"></a>00132 } <a name="l00133"></a>00133 <a name="l00134"></a>00134 <a name="l00135"></a>00135 <a name="l00136"></a>00136 <a name="l00137"></a>00137 <a name="l00138"></a>00138 <a name="l00139"></a>00139 <a name="l00140"></a>00140 <a name="l00141"></a>00141 <a name="l00142"></a>00142 <a name="l00143"></a>00143 <a name="l00144"></a>00144 <a name="l00145"></a>00145 <a name="l00153"></a><a class="code" href="classSC__db__new__content__el.html">00153</a> <span class="keyword">class </span><a class="code" href="classSC__db__new__content__el.html">SC_db_new_content_el</a> { <a name="l00154"></a>00154 <a name="l00155"></a>00155 <span class="comment">// Internal, static (from GPvars):</span> <a name="l00156"></a><a class="code" href="classSC__db__new__content__el.html#5773f59e75d7fb8dcc24eb3ef6f9c51b">00156</a> var <a class="code" href="classSC__db__new__content__el.html#5773f59e75d7fb8dcc24eb3ef6f9c51b">$id</a>; <span class="comment">// Page id</span> <a name="l00157"></a><a class="code" href="classSC__db__new__content__el.html#d204fa525de1a561321b0bf885b11e0f">00157</a> var <a class="code" href="classSC__db__new__content__el.html#d204fa525de1a561321b0bf885b11e0f">$sys_language</a>=0; <span class="comment">// Sys language</span> <a name="l00158"></a><a class="code" href="classSC__db__new__content__el.html#21f3b42c227f467f0b3b5f6bcc46b087">00158</a> var <a class="code" href="classSC__db__new__content__el.html#21f3b42c227f467f0b3b5f6bcc46b087">$R_URI</a>=''; <span class="comment">// Return URL.</span> <a name="l00159"></a><a class="code" href="classSC__db__new__content__el.html#d54cbdf26e2aae98f37dd7a79c4fb128">00159</a> var <a class="code" href="classSC__db__new__content__el.html#d54cbdf26e2aae98f37dd7a79c4fb128">$colPos</a>; <span class="comment">// If set, the content is destined for a specific column.</span> <a name="l00160"></a><a class="code" href="classSC__db__new__content__el.html#fc834a8a5cbf6e41ffcb7b7c408e96b6">00160</a> var <a class="code" href="classSC__db__new__content__el.html#fc834a8a5cbf6e41ffcb7b7c408e96b6">$uid_pid</a>; <span class="comment">//</span> <a name="l00161"></a>00161 <a name="l00162"></a>00162 <span class="comment">// Internal, static:</span> <a name="l00163"></a><a class="code" href="classSC__db__new__content__el.html#eda577d4530be4242ca662a3f46c5c74">00163</a> var <a class="code" href="classSC__db__new__content__el.html#eda577d4530be4242ca662a3f46c5c74">$modTSconfig</a>=array(); <span class="comment">// Module TSconfig.</span> <a name="l00164"></a><a class="code" href="classSC__db__new__content__el.html#de8a5455ada574db1a7616c3897d4ccc">00164</a> var <a class="code" href="classSC__db__new__content__el.html#de8a5455ada574db1a7616c3897d4ccc">$doc</a>; <span class="comment">// Internal backend template object</span> <a name="l00165"></a>00165 <a name="l00166"></a>00166 <span class="comment">// Internal, dynamic:</span> <a name="l00167"></a><a class="code" href="classSC__db__new__content__el.html#93c2359dce8b56bbf0b2dc64f136554e">00167</a> var <a class="code" href="classSC__db__new__content__el.html#93c2359dce8b56bbf0b2dc64f136554e">$include_once</a> = array(); <span class="comment">// Includes a list of files to include between init() and main() - see init()</span> <a name="l00168"></a><a class="code" href="classSC__db__new__content__el.html#30e9872ab82a3c87ea60115ef8f16b9d">00168</a> var <a class="code" href="classSC__db__new__content__el.html#30e9872ab82a3c87ea60115ef8f16b9d">$content</a>; <span class="comment">// Used to accumulate the content of the module.</span> <a name="l00169"></a><a class="code" href="classSC__db__new__content__el.html#67d545df24b56382cad6504e40be19b8">00169</a> var <a class="code" href="classSC__db__new__content__el.html#67d545df24b56382cad6504e40be19b8">$access</a>; <span class="comment">// Access boolean.</span> <a name="l00170"></a>00170 <a name="l00176"></a><a class="code" href="classSC__db__new__content__el.html#95c98ad8973b19524681806ad72618ad">00176</a> function <a class="code" href="classSC__db__new__content__el.html#95c98ad8973b19524681806ad72618ad">init</a>() { <a name="l00177"></a>00177 global $BE_USER,$BACK_PATH,$TBE_MODULES_EXT; <a name="l00178"></a>00178 <a name="l00179"></a>00179 <span class="comment">// Setting class files to include:</span> <a name="l00180"></a>00180 <span class="keywordflow">if</span> (is_array($TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses'])) { <a name="l00181"></a>00181 $this->include_once = array_merge($this->include_once,$TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses']); <a name="l00182"></a>00182 } <a name="l00183"></a>00183 <a name="l00184"></a>00184 <span class="comment">// Setting internal vars:</span> <a name="l00185"></a>00185 $this-><span class="keywordtype">id</span> = intval(<a class="code" href="classt3lib__div.html#016d2190758279b2dbb953826c690118">t3lib_div::_GP</a>('<span class="keywordtype">id</span>')); <a name="l00186"></a>00186 $this->sys_language = intval(<a class="code" href="classt3lib__div.html#016d2190758279b2dbb953826c690118">t3lib_div::_GP</a>('sys_language_uid')); <a name="l00187"></a>00187 $this->R_URI = <a class="code" href="classt3lib__div.html#016d2190758279b2dbb953826c690118">t3lib_div::_GP</a>('returnUrl'); <a name="l00188"></a>00188 $this->colPos = <a class="code" href="classt3lib__div.html#016d2190758279b2dbb953826c690118">t3lib_div::_GP</a>('colPos'); <a name="l00189"></a>00189 $this->uid_pid = intval(<a class="code" href="classt3lib__div.html#016d2190758279b2dbb953826c690118">t3lib_div::_GP</a>('uid_pid')); <a name="l00190"></a>00190 <a name="l00191"></a>00191 $this->MCONF['name'] = 'xMOD_db_new_content_el'; <a name="l00192"></a>00192 $this->modTSconfig = <a class="code" href="classt3lib__BEfunc.html#3e3f63eb1c3bb4ae0d5ad009dea00cc5">t3lib_BEfunc::getModTSconfig</a>($this-><span class="keywordtype">id</span>,'mod.'.$this->MCONF['name']); <a name="l00193"></a>00193 <a name="l00194"></a>00194 <span class="comment">// Starting the document template object:</span> <a name="l00195"></a>00195 $this->doc = <a class="code" href="classt3lib__div.html#b47f8a8e8be44b79a0b8064dcd427bc1">t3lib_div::makeInstance</a>('<a class="code" href="classmediumDoc.html">mediumDoc</a>'); <a name="l00196"></a>00196 $this->doc->docType= 'xhtml_trans'; <a name="l00197"></a>00197 $this->doc->backPath = $BACK_PATH; <a name="l00198"></a>00198 $this->doc->JScode=''; <a name="l00199"></a>00199 $this->doc->form='<form action=<span class="stringliteral">""</span> name=<span class="stringliteral">"editForm"</span>><input type=<span class="stringliteral">"hidden"</span> name=<span class="stringliteral">"defValues"</span> value=<span class="stringliteral">""</span> />'; <a name="l00200"></a>00200 <a name="l00201"></a>00201 <span class="comment">// Getting the current page and receiving access information (used in main())</span> <a name="l00202"></a>00202 $perms_clause = $BE_USER->getPagePermsClause(1); <a name="l00203"></a>00203 $pageinfo = <a class="code" href="classt3lib__BEfunc.html#b99fd2c4e3d5bae861525165091fe5de">t3lib_BEfunc::readPageAccess</a>($this-><span class="keywordtype">id</span>,$perms_clause); <a name="l00204"></a>00204 $this->access = is_array($pageinfo) ? 1 : 0; <a name="l00205"></a>00205 } <a name="l00206"></a>00206 <a name="l00212"></a><a class="code" href="classSC__db__new__content__el.html#24648aa5a8c3daf50085338cdec7eba9">00212</a> function <a class="code" href="classSC__db__new__content__el.html#24648aa5a8c3daf50085338cdec7eba9">main</a>() { <a name="l00213"></a>00213 global $LANG,$BACK_PATH; <a name="l00214"></a>00214 <a name="l00215"></a>00215 <span class="keywordflow">if</span> ($this-><span class="keywordtype">id</span> && $this->access) { <a name="l00216"></a>00216 <a name="l00217"></a>00217 <span class="comment">// Init position map object:</span> <a name="l00218"></a>00218 $posMap = <a class="code" href="classt3lib__div.html#b47f8a8e8be44b79a0b8064dcd427bc1">t3lib_div::makeInstance</a>('<a class="code" href="classext__posMap.html">ext_posMap</a>'); <a name="l00219"></a>00219 $posMap->cur_sys_language = $this->sys_language; <a name="l00220"></a>00220 $posMap->backPath = $BACK_PATH; <a name="l00221"></a>00221 <a name="l00222"></a>00222 <span class="keywordflow">if</span> ((string)$this->colPos!='') { <span class="comment">// If a column is pre-set:</span> <a name="l00223"></a>00223 <span class="keywordflow">if</span> ($this->uid_pid<0) { <a name="l00224"></a>00224 $row=array(); <a name="l00225"></a>00225 $row['uid']=abs($this->uid_pid); <a name="l00226"></a>00226 } <span class="keywordflow">else</span> { <a name="l00227"></a>00227 $row=''; <a name="l00228"></a>00228 } <a name="l00229"></a>00229 $onClickEvent = $posMap->onClickInsertRecord($row,$this->colPos,'',$this->uid_pid,$this->sys_language); <a name="l00230"></a>00230 } <span class="keywordflow">else</span> { <a name="l00231"></a>00231 $onClickEvent=''; <a name="l00232"></a>00232 } <a name="l00233"></a>00233 <a name="l00234"></a>00234 $this->doc->JScode=$this->doc->wrapScriptTags(' <a name="l00235"></a>00235 function goToalt_doc() { <span class="comment">//</span> <a name="l00236"></a>00236 '.$onClickEvent.' <a name="l00237"></a>00237 } <a name="l00238"></a>00238 '); <a name="l00239"></a>00239 <a name="l00240"></a>00240 <a name="l00241"></a>00241 <span class="comment">// ***************************</span> <a name="l00242"></a>00242 <span class="comment">// Creating content</span> <a name="l00243"></a>00243 <span class="comment">// ***************************</span> <a name="l00244"></a>00244 $this->content=''; <a name="l00245"></a>00245 $this->content.=$this->doc->startPage($LANG->getLL('newContentElement')); <a name="l00246"></a>00246 $this->content.=$this->doc->header($LANG->getLL('newContentElement')); <a name="l00247"></a>00247 $this->content.=$this->doc->spacer(5); <a name="l00248"></a>00248 <a name="l00249"></a>00249 $elRow = <a class="code" href="classt3lib__BEfunc.html#2921570c91cd2543489c9d850cfec311">t3lib_BEfunc::getRecordWSOL</a>('pages',$this-><span class="keywordtype">id</span>); <a name="l00250"></a>00250 $hline = <a class="code" href="classt3lib__iconWorks.html#09ccf5c505e700d523bd9c71a43d0fb4">t3lib_iconWorks::getIconImage</a>('pages',$elRow,$BACK_PATH,' title=<span class="stringliteral">"'.htmlspecialchars(t3lib_BEfunc::getRecordIconAltText($elRow,'pages')).'"</span> align=<span class="stringliteral">"top"</span>'); <a name="l00251"></a>00251 $hline.= <a class="code" href="classt3lib__BEfunc.html#b2fd87d0623e4168bb0f1164572ca1a3">t3lib_BEfunc::getRecordTitle</a>('pages',$elRow,1); <a name="l00252"></a>00252 $this->content.=$this->doc->section('',$hline,0,1); <a name="l00253"></a>00253 $this->content.=$this->doc->spacer(10); <a name="l00254"></a>00254 <a name="l00255"></a>00255 <a name="l00256"></a>00256 <span class="comment">// Wizard</span> <a name="l00257"></a>00257 $code=''; <a name="l00258"></a>00258 $lines=array(); <a name="l00259"></a>00259 $wizardItems = $this-><a class="code" href="classSC__db__new__content__el.html#47fc9f8001113df32343b9b442be6770">getWizardItems</a>(); <a name="l00260"></a>00260 <a name="l00261"></a>00261 <span class="comment">// Traverse items for the wizard.</span> <a name="l00262"></a>00262 <span class="comment">// An item is either a header or an item rendered with a radio button and title/description and icon:</span> <a name="l00263"></a>00263 $cc=0; <a name="l00264"></a>00264 foreach($wizardItems as $k => $wInfo) { <a name="l00265"></a>00265 <span class="keywordflow">if</span> ($wInfo['header']) { <a name="l00266"></a>00266 <span class="keywordflow">if</span> ($cc>0) $lines[]=' <a name="l00267"></a>00267 <tr> <a name="l00268"></a>00268 <td colspan=<span class="stringliteral">"3"</span>><br /></td> <a name="l00269"></a>00269 </tr>'; <a name="l00270"></a>00270 $lines[]=' <a name="l00271"></a>00271 <tr <span class="keyword">class</span>=<span class="stringliteral">"bgColor5"</span>> <a name="l00272"></a>00272 <td colspan=<span class="stringliteral">"3"</span>><strong>'.htmlspecialchars($wInfo['header']).'</strong></td> <a name="l00273"></a>00273 </tr>'; <a name="l00274"></a>00274 } <span class="keywordflow">else</span> { <a name="l00275"></a>00275 $tL=array(); <a name="l00276"></a>00276 <a name="l00277"></a>00277 <span class="comment">// Radio button:</span> <a name="l00278"></a>00278 $oC = <span class="stringliteral">"document.editForm.defValues.value=unescape('"</span>.rawurlencode($wInfo['params']).<span class="stringliteral">"');goToalt_doc();"</span>.(!$onClickEvent?<span class="stringliteral">"window.location.hash='#sel2';"</span>:''); <a name="l00279"></a>00279 $tL[]='<input type=<span class="stringliteral">"radio"</span> name=<span class="stringliteral">"tempB"</span> value=<span class="stringliteral">"'.htmlspecialchars($k).'"</span> onclick=<span class="stringliteral">"'.htmlspecialchars($this->doc->thisBlur().$oC).'"</span> />'; <a name="l00280"></a>00280 <a name="l00281"></a>00281 <span class="comment">// Onclick action for icon/title:</span> <a name="l00282"></a>00282 $aOnClick = 'document.editForm.tempB['.$cc.'].checked=1;'.$this->doc->thisBlur().$oC.'<span class="keywordflow">return</span> <span class="keyword">false</span>;'; <a name="l00283"></a>00283 <a name="l00284"></a>00284 <span class="comment">// Icon:</span> <a name="l00285"></a>00285 $iInfo = @getimagesize($wInfo['icon']); <a name="l00286"></a>00286 $tL[]='<a href=<span class="stringliteral">"#"</span> onclick=<span class="stringliteral">"'.htmlspecialchars($aOnClick).'"</span>><img'.t3lib_iconWorks::skinImg($this->doc->backPath,$wInfo['icon'],'').' alt=<span class="stringliteral">""</span> /></a>'; <a name="l00287"></a>00287 <a name="l00288"></a>00288 <span class="comment">// Title + description:</span> <a name="l00289"></a>00289 $tL[]='<a href=<span class="stringliteral">"#"</span> onclick=<span class="stringliteral">"'.htmlspecialchars($aOnClick).'"</span>><strong>'.htmlspecialchars($wInfo['title']).'</strong><br />'.nl2br(htmlspecialchars(trim($wInfo['description']))).'</a>'; <a name="l00290"></a>00290 <a name="l00291"></a>00291 <span class="comment">// Finally, put it together in a table row:</span> <a name="l00292"></a>00292 $lines[]=' <a name="l00293"></a>00293 <tr> <a name="l00294"></a>00294 <td valign=<span class="stringliteral">"top"</span>>'.implode('</td> <a name="l00295"></a>00295 <td valign=<span class="stringliteral">"top"</span>>',$tL).'</td> <a name="l00296"></a>00296 </tr>'; <a name="l00297"></a>00297 $cc++; <a name="l00298"></a>00298 } <a name="l00299"></a>00299 } <a name="l00300"></a>00300 <span class="comment">// Add the wizard table to the content:</span> <a name="l00301"></a>00301 $code.=$LANG->getLL('sel1',1).'<br /><br /> <a name="l00302"></a>00302 <a name="l00303"></a>00303 <a name="l00304"></a>00304 <!-- <a name="l00305"></a>00305 Content Element wizard table: <a name="l00306"></a>00306 --> <a name="l00307"></a>00307 <table border=<span class="stringliteral">"0"</span> cellpadding=<span class="stringliteral">"1"</span> cellspacing=<span class="stringliteral">"2"</span> <span class="keywordtype">id</span>=<span class="stringliteral">"typo3-ceWizardTable"</span>> <a name="l00308"></a>00308 '.implode('',$lines).' <a name="l00309"></a>00309 </table>'; <a name="l00310"></a>00310 $this->content.=$this->doc->section(!$onClickEvent?$LANG->getLL('1_selectType'):'',$code,0,1); <a name="l00311"></a>00311 <a name="l00312"></a>00312 <a name="l00313"></a>00313 <a name="l00314"></a>00314 <span class="comment">// If the user must also select a column:</span> <a name="l00315"></a>00315 <span class="keywordflow">if</span> (!$onClickEvent) { <a name="l00316"></a>00316 <a name="l00317"></a>00317 <span class="comment">// Add anchor "sel2"</span> <a name="l00318"></a>00318 $this->content.=$this->doc->section('<span class="charliteral">','</span><a name=<span class="stringliteral">"sel2"</span>></a>'); <a name="l00319"></a>00319 $this->content.=$this->doc->spacer(20); <a name="l00320"></a>00320 <a name="l00321"></a>00321 <span class="comment">// Select position</span> <a name="l00322"></a>00322 $code=$LANG->getLL('sel2',1).'<br /><br />'; <a name="l00323"></a>00323 <a name="l00324"></a>00324 <span class="comment">// Load SHARED page-TSconfig settings and retrieve column list from there, if applicable:</span> <a name="l00325"></a>00325 $modTSconfig_SHARED = <a class="code" href="classt3lib__BEfunc.html#3e3f63eb1c3bb4ae0d5ad009dea00cc5">t3lib_BEfunc::getModTSconfig</a>($this-><span class="keywordtype">id</span>,'mod.SHARED'); <a name="l00326"></a>00326 $colPosList = strcmp(trim($modTSconfig_SHARED['properties']['colPos_list']),'') ? trim($modTSconfig_SHARED['properties']['colPos_list']) : '1,0,2,3'; <a name="l00327"></a>00327 $colPosList = implode(<span class="charliteral">','</span>,array_unique(<a class="code" href="classt3lib__div.html#93aed4f073a335dc8e804c46d405cbd6">t3lib_div::intExplode</a>(<span class="charliteral">','</span>,$colPosList))); <span class="comment">// Removing duplicates, if any</span> <a name="l00328"></a>00328 <a name="l00329"></a>00329 <span class="comment">// Finally, add the content of the column selector to the content:</span> <a name="l00330"></a>00330 $code.=$posMap->printContentElementColumns($this-><span class="keywordtype">id</span>,0,$colPosList,1,$this->R_URI); <a name="l00331"></a>00331 $this->content.=$this->doc->section($LANG->getLL('2_selectPosition'),$code,0,1); <a name="l00332"></a>00332 } <a name="l00333"></a>00333 <a name="l00334"></a>00334 <span class="comment">// IF there is a return-url set, then print a go-back link:</span> <a name="l00335"></a>00335 <span class="keywordflow">if</span> ($this->R_URI) { <a name="l00336"></a>00336 $code='<br /><br /><a href=<span class="stringliteral">"'.htmlspecialchars($this->R_URI).'"</span> <span class="keyword">class</span>=<span class="stringliteral">"typo3-goBack"</span>><img'.t3lib_iconWorks::skinImg($this->doc->backPath,'gfx/goback.gif<span class="charliteral">','</span>width=<span class="stringliteral">"14"</span> height=<span class="stringliteral">"14"</span>').' alt=<span class="stringliteral">""</span> />'.$LANG->getLL('goBack',1).'</a>'; <a name="l00337"></a>00337 $this->content.=$this->doc->section('',$code,0,1); <a name="l00338"></a>00338 } <a name="l00339"></a>00339 <a name="l00340"></a>00340 <span class="comment">// Add CSH:</span> <a name="l00341"></a>00341 $this->content.= $this->doc->section('',<a class="code" href="classt3lib__BEfunc.html#a235b246dec429e439742b1fc76c9d97">t3lib_BEfunc::cshItem</a>('xMOD_csh_corebe', 'new_ce', $GLOBALS['BACK_PATH'],'<br/>'),0,1); <a name="l00342"></a>00342 <a name="l00343"></a>00343 <span class="comment">// Add a very high clear-gif, 700 px (so that the link to the anchor "sel2" shows this part in top for sure...)</span> <a name="l00344"></a>00344 $this->content.=$this->doc->section('<span class="charliteral">','</span><img src=<span class="stringliteral">"clear.gif"</span> width=<span class="stringliteral">"1"</span> height=<span class="stringliteral">"700"</span> alt=<span class="stringliteral">""</span> />',0,1); <a name="l00345"></a>00345 <a name="l00346"></a>00346 } <span class="keywordflow">else</span> { <span class="comment">// In case of no access:</span> <a name="l00347"></a>00347 $this->content=''; <a name="l00348"></a>00348 $this->content.=$this->doc->startPage($LANG->getLL('newContentElement')); <a name="l00349"></a>00349 $this->content.=$this->doc->header($LANG->getLL('newContentElement')); <a name="l00350"></a>00350 $this->content.=$this->doc->spacer(5); <a name="l00351"></a>00351 } <a name="l00352"></a>00352 } <a name="l00353"></a>00353 <a name="l00359"></a><a class="code" href="classSC__db__new__content__el.html#f882e0411c89496ef750e9d4389293d7">00359</a> function <a class="code" href="classSC__db__new__content__el.html#f882e0411c89496ef750e9d4389293d7">printContent</a>() { <a name="l00360"></a>00360 global $SOBE; <a name="l00361"></a>00361 <a name="l00362"></a>00362 $this->content.= $this->doc->endPage(); <a name="l00363"></a>00363 echo $this->content; <a name="l00364"></a>00364 } <a name="l00365"></a>00365 <a name="l00366"></a>00366 <a name="l00367"></a>00367 <a name="l00368"></a>00368 <a name="l00369"></a>00369 <a name="l00370"></a>00370 <a name="l00371"></a>00371 <a name="l00372"></a>00372 <a name="l00373"></a>00373 <a name="l00374"></a>00374 <a name="l00375"></a>00375 <a name="l00376"></a>00376 <span class="comment">/***************************</span> <a name="l00377"></a>00377 <span class="comment"> *</span> <a name="l00378"></a>00378 <span class="comment"> * OTHER FUNCTIONS:</span> <a name="l00379"></a>00379 <span class="comment"> *</span> <a name="l00380"></a>00380 <span class="comment"> ***************************/</span> <a name="l00381"></a>00381 <a name="l00382"></a>00382 <a name="l00388"></a><a class="code" href="classSC__db__new__content__el.html#47fc9f8001113df32343b9b442be6770">00388</a> function <a class="code" href="classSC__db__new__content__el.html#47fc9f8001113df32343b9b442be6770">getWizardItems</a>() { <a name="l00389"></a>00389 <span class="keywordflow">return</span> $this-><a class="code" href="classSC__db__new__content__el.html#2c81d4602f6e69fb5b8dbad9d6ce07e3">wizardArray</a>(); <a name="l00390"></a>00390 } <a name="l00391"></a>00391 <a name="l00398"></a><a class="code" href="classSC__db__new__content__el.html#2c81d4602f6e69fb5b8dbad9d6ce07e3">00398</a> function <a class="code" href="classSC__db__new__content__el.html#2c81d4602f6e69fb5b8dbad9d6ce07e3">wizardArray</a>() { <a name="l00399"></a>00399 global $LANG,$TBE_MODULES_EXT; <a name="l00400"></a>00400 <a name="l00401"></a>00401 $wizardItems = array( <a name="l00402"></a>00402 'common' => array('header'=>$LANG->getLL('common')), <a name="l00403"></a>00403 'common_regularText' => array( <span class="comment">// Regular text element</span> <a name="l00404"></a>00404 'icon'=>'gfx/c_wiz/regular_text.gif', <a name="l00405"></a>00405 'title'=>$LANG->getLL('common_regularText_title'), <a name="l00406"></a>00406 'description'=>$LANG->getLL('common_regularText_description'), <a name="l00407"></a>00407 'tt_content_defValues' => array( <a name="l00408"></a>00408 'CType' => 'text' <a name="l00409"></a>00409 ) <a name="l00410"></a>00410 ), <a name="l00411"></a>00411 'common_textImage' => array( <span class="comment">// Text with image</span> <a name="l00412"></a>00412 'icon'=>'gfx/c_wiz/text_image_right.gif', <a name="l00413"></a>00413 'title'=>$LANG->getLL('common_textImage_title'), <a name="l00414"></a>00414 'description'=>$LANG->getLL('common_textImage_description'), <a name="l00415"></a>00415 'tt_content_defValues' => array( <a name="l00416"></a>00416 'CType' => 'textpic', <a name="l00417"></a>00417 'imageorient' => 17 <a name="l00418"></a>00418 ) <a name="l00419"></a>00419 ), <a name="l00420"></a>00420 'common_imagesOnly' => array( <span class="comment">// Images only</span> <a name="l00421"></a>00421 'icon'=>'gfx/c_wiz/images_only.gif', <a name="l00422"></a>00422 'title'=>$LANG->getLL('common_imagesOnly_title'), <a name="l00423"></a>00423 'description'=>$LANG->getLL('common_imagesOnly_description'), <a name="l00424"></a>00424 'tt_content_defValues' => array( <a name="l00425"></a>00425 'CType' => 'image', <a name="l00426"></a>00426 'imagecols' => 2 <a name="l00427"></a>00427 ) <a name="l00428"></a>00428 ), <a name="l00429"></a>00429 'common_bulletList' => array( <span class="comment">// Bullet list</span> <a name="l00430"></a>00430 'icon'=>'gfx/c_wiz/bullet_list.gif', <a name="l00431"></a>00431 'title'=>$LANG->getLL('common_bulletList_title'), <a name="l00432"></a>00432 'description'=>$LANG->getLL('common_bulletList_description'), <a name="l00433"></a>00433 'tt_content_defValues' => array( <a name="l00434"></a>00434 'CType' => 'bullets', <a name="l00435"></a>00435 ) <a name="l00436"></a>00436 ), <a name="l00437"></a>00437 'common_table' => array( <span class="comment">// Table</span> <a name="l00438"></a>00438 'icon'=>'gfx/c_wiz/table.gif', <a name="l00439"></a>00439 'title'=>$LANG->getLL('common_table_title'), <a name="l00440"></a>00440 'description'=>$LANG->getLL('common_table_description'), <a name="l00441"></a>00441 'tt_content_defValues' => array( <a name="l00442"></a>00442 'CType' => 'table', <a name="l00443"></a>00443 ) <a name="l00444"></a>00444 ), <a name="l00445"></a>00445 'special' => array('header'=>$LANG->getLL('special')), <a name="l00446"></a>00446 'special_filelinks' => array( <span class="comment">// Filelinks</span> <a name="l00447"></a>00447 'icon'=>'gfx/c_wiz/filelinks.gif', <a name="l00448"></a>00448 'title'=>$LANG->getLL('special_filelinks_title'), <a name="l00449"></a>00449 'description'=>$LANG->getLL('special_filelinks_description'), <a name="l00450"></a>00450 'tt_content_defValues' => array( <a name="l00451"></a>00451 'CType' => 'uploads', <a name="l00452"></a>00452 ) <a name="l00453"></a>00453 ), <a name="l00454"></a>00454 'special_multimedia' => array( <span class="comment">// Multimedia</span> <a name="l00455"></a>00455 'icon'=>'gfx/c_wiz/multimedia.gif', <a name="l00456"></a>00456 'title'=>$LANG->getLL('special_multimedia_title'), <a name="l00457"></a>00457 'description'=>$LANG->getLL('special_multimedia_description'), <a name="l00458"></a>00458 'tt_content_defValues' => array( <a name="l00459"></a>00459 'CType' => 'multimedia', <a name="l00460"></a>00460 ) <a name="l00461"></a>00461 ), <a name="l00462"></a>00462 'special_sitemap' => array( <span class="comment">// Sitemap</span> <a name="l00463"></a>00463 'icon'=>'gfx/c_wiz/sitemap2.gif', <a name="l00464"></a>00464 'title'=>$LANG->getLL('special_sitemap_title'), <a name="l00465"></a>00465 'description'=>$LANG->getLL('special_sitemap_description'), <a name="l00466"></a>00466 'tt_content_defValues' => array( <a name="l00467"></a>00467 'CType' => 'menu', <a name="l00468"></a>00468 'menu_type' => 2 <a name="l00469"></a>00469 ) <a name="l00470"></a>00470 ), <a name="l00471"></a>00471 'special_plainHTML' => array( <span class="comment">// Plain HTML</span> <a name="l00472"></a>00472 'icon'=>'gfx/c_wiz/html.gif', <a name="l00473"></a>00473 'title'=>$LANG->getLL('special_plainHTML_title'), <a name="l00474"></a>00474 'description'=>$LANG->getLL('special_plainHTML_description'), <a name="l00475"></a>00475 'tt_content_defValues' => array( <a name="l00476"></a>00476 'CType' => 'html', <a name="l00477"></a>00477 ) <a name="l00478"></a>00478 ), <a name="l00479"></a>00479 'forms' => array('header'=>$LANG->getLL('forms')), <a name="l00480"></a>00480 'forms_mail' => array( <span class="comment">// Mail form</span> <a name="l00481"></a>00481 'icon'=>'gfx/c_wiz/mailform.gif', <a name="l00482"></a>00482 'title'=>$LANG->getLL('forms_mail_title'), <a name="l00483"></a>00483 'description'=>$LANG->getLL('forms_mail_description'), <a name="l00484"></a>00484 'tt_content_defValues' => array( <a name="l00485"></a>00485 'CType' => 'mailform', <a name="l00486"></a>00486 'bodytext' => trim(' <a name="l00487"></a>00487 # Example content: <a name="l00488"></a>00488 Name: | *name = input,40 | Enter your name here <a name="l00489"></a>00489 Email: | *email=input,40 | <a name="l00490"></a>00490 Address: | address=textarea,40,5 | <a name="l00491"></a>00491 Contact me: | tv=check | 1 <a name="l00492"></a>00492 <a name="l00493"></a>00493 |formtype_mail = submit | Send form! <a name="l00494"></a>00494 |html_enabled=hidden | 1 <a name="l00495"></a>00495 |subject=hidden| This is the subject <a name="l00496"></a>00496 ') <a name="l00497"></a>00497 ) <a name="l00498"></a>00498 ), <a name="l00499"></a>00499 'forms_search' => array( <span class="comment">// Search form</span> <a name="l00500"></a>00500 'icon'=>'gfx/c_wiz/searchform.gif', <a name="l00501"></a>00501 'title'=>$LANG->getLL('forms_search_title'), <a name="l00502"></a>00502 'description'=>$LANG->getLL('forms_search_description'), <a name="l00503"></a>00503 'tt_content_defValues' => array( <a name="l00504"></a>00504 'CType' => 'search', <a name="l00505"></a>00505 ) <a name="l00506"></a>00506 ), <a name="l00507"></a>00507 'forms_login' => array( <span class="comment">// Login form</span> <a name="l00508"></a>00508 'icon'=>'gfx/c_wiz/login_form.gif', <a name="l00509"></a>00509 'title'=>$LANG->getLL('forms_login_title'), <a name="l00510"></a>00510 'description'=>$LANG->getLL('forms_login_description'), <a name="l00511"></a>00511 'tt_content_defValues' => array( <a name="l00512"></a>00512 'CType' => 'login', <a name="l00513"></a>00513 ) <a name="l00514"></a>00514 ), <a name="l00515"></a>00515 'plugins' => array('header'=>$LANG->getLL('plugins')), <a name="l00516"></a>00516 'plugins_general' => array( <span class="comment">// General plugin</span> <a name="l00517"></a>00517 'icon'=>'gfx/c_wiz/user_defined.gif', <a name="l00518"></a>00518 'title'=>$LANG->getLL('plugins_general_title'), <a name="l00519"></a>00519 'description'=>$LANG->getLL('plugins_general_description'), <a name="l00520"></a>00520 'tt_content_defValues' => array( <a name="l00521"></a>00521 'CType' => 'list', <a name="l00522"></a>00522 ) <a name="l00523"></a>00523 ), <a name="l00524"></a>00524 ); <a name="l00525"></a>00525 <a name="l00526"></a>00526 <a name="l00527"></a>00527 <span class="comment">// PLUG-INS:</span> <a name="l00528"></a>00528 <span class="keywordflow">if</span> (is_array($TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses'])) { <a name="l00529"></a>00529 reset($TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses']); <a name="l00530"></a>00530 <span class="keywordflow">while</span>(list($class,$path)=each($TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses'])) { <a name="l00531"></a>00531 $modObj = <a class="code" href="classt3lib__div.html#b47f8a8e8be44b79a0b8064dcd427bc1">t3lib_div::makeInstance</a>($class); <a name="l00532"></a>00532 $wizardItems = $modObj->proc($wizardItems); <a name="l00533"></a>00533 } <a name="l00534"></a>00534 } <a name="l00535"></a>00535 <a name="l00536"></a>00536 <span class="comment">// Remove elements where preset values are not allowed:</span> <a name="l00537"></a>00537 $this-><a class="code" href="classSC__db__new__content__el.html#f653bfeefcfe5c4d740e708b0c83c843">removeInvalidElements</a>($wizardItems); <a name="l00538"></a>00538 <a name="l00539"></a>00539 <span class="keywordflow">return</span> $wizardItems; <a name="l00540"></a>00540 } <a name="l00541"></a>00541 <a name="l00549"></a><a class="code" href="classSC__db__new__content__el.html#f653bfeefcfe5c4d740e708b0c83c843">00549</a> function <a class="code" href="classSC__db__new__content__el.html#f653bfeefcfe5c4d740e708b0c83c843">removeInvalidElements</a>(&$wizardItems) { <a name="l00550"></a>00550 global $TCA; <a name="l00551"></a>00551 <a name="l00552"></a>00552 <span class="comment">// Load full table definition:</span> <a name="l00553"></a>00553 <a class="code" href="classt3lib__div.html#3a04dbb9a707317b8beccbe92559dcc8">t3lib_div::loadTCA</a>('tt_content'); <a name="l00554"></a>00554 <a name="l00555"></a>00555 <span class="comment">// Get TCEFORM from TSconfig of current page</span> <a name="l00556"></a>00556 $row = array('pid'=>$this-><span class="keywordtype">id</span>); <a name="l00557"></a>00557 $TCEFORM_TSconfig = <a class="code" href="classt3lib__BEfunc.html#522caf53343de891bdb1a7caa5fe556e">t3lib_BEfunc::getTCEFORM_TSconfig</a>('tt_content',$row); <a name="l00558"></a>00558 $removeItems = <a class="code" href="classt3lib__div.html#cfb87d585b85e9b32841bde40beaa96c">t3lib_div::trimExplode</a>(<span class="charliteral">','</span>,$TCEFORM_TSconfig['CType']['removeItems'],1); <a name="l00559"></a>00559 <a name="l00560"></a>00560 $headersUsed = Array(); <a name="l00561"></a>00561 <span class="comment">// Traverse wizard items:</span> <a name="l00562"></a>00562 foreach($wizardItems as $key => $cfg) { <a name="l00563"></a>00563 <a name="l00564"></a>00564 <span class="comment">// Exploding parameter string, if any (old style)</span> <a name="l00565"></a>00565 <span class="keywordflow">if</span> ($wizardItems[$key]['params']) { <a name="l00566"></a>00566 <span class="comment">// Explode GET vars recursively</span> <a name="l00567"></a>00567 $tempGetVars = <a class="code" href="classt3lib__div.html#0b4d8ddedc5ebcb78bab2a87872e707b">t3lib_div::explodeUrl2Array</a>($wizardItems[$key]['params'],TRUE); <a name="l00568"></a>00568 <span class="comment">// If tt_content values are set, merge them into the tt_content_defValues array, unset them from $tempGetVars and re-implode $tempGetVars into the param string (in case remaining parameters are around).</span> <a name="l00569"></a>00569 <span class="keywordflow">if</span> (is_array($tempGetVars['defVals']['tt_content'])) { <a name="l00570"></a>00570 $wizardItems[$key]['tt_content_defValues'] = array_merge(is_array($wizardItems[$key]['tt_content_defValues']) ? $wizardItems[$key]['tt_content_defValues'] : array(), $tempGetVars['defVals']['tt_content']); <a name="l00571"></a>00571 unset($tempGetVars['defVals']['tt_content']); <a name="l00572"></a>00572 $wizardItems[$key]['params'] = <a class="code" href="classt3lib__div.html#7874ca6bd93d402c193542e864bb67f3">t3lib_div::implodeArrayForUrl</a>('',$tempGetVars); <a name="l00573"></a>00573 } <a name="l00574"></a>00574 } <a name="l00575"></a>00575 <a name="l00576"></a>00576 <span class="comment">// If tt_content_defValues are defined...:</span> <a name="l00577"></a>00577 <span class="keywordflow">if</span> (is_array($wizardItems[$key]['tt_content_defValues'])) { <a name="l00578"></a>00578 <a name="l00579"></a>00579 <span class="comment">// Traverse field values:</span> <a name="l00580"></a>00580 foreach($wizardItems[$key]['tt_content_defValues'] as $fN => $fV) { <a name="l00581"></a>00581 <span class="keywordflow">if</span> (is_array($TCA['tt_content']['columns'][$fN])) { <a name="l00582"></a>00582 <span class="comment">// Get information about if the field value is OK:</span> <a name="l00583"></a>00583 $config = &$TCA['tt_content']['columns'][$fN]['config']; <a name="l00584"></a>00584 $authModeDeny = $config['type']=='select' && $config['authMode'] && !$GLOBALS['BE_USER']->checkAuthMode('tt_content',$fN,$fV,$config['authMode']); <a name="l00585"></a>00585 <a name="l00586"></a>00586 <span class="keywordflow">if</span> ($authModeDeny || in_array($fV,$removeItems)) { <a name="l00587"></a>00587 <span class="comment">// Remove element all together:</span> <a name="l00588"></a>00588 unset($wizardItems[$key]); <a name="l00589"></a>00589 <span class="keywordflow">break</span>; <a name="l00590"></a>00590 } <span class="keywordflow">else</span> { <a name="l00591"></a>00591 <span class="comment">// Add the parameter:</span> <a name="l00592"></a>00592 $wizardItems[$key]['params'].= '&defVals[tt_content]['.$fN.']='.rawurlencode($fV); <a name="l00593"></a>00593 $tmp = explode(<span class="charliteral">'_'</span>, $key); <a name="l00594"></a>00594 $headersUsed[$tmp[0]] = $tmp[0]; <a name="l00595"></a>00595 } <a name="l00596"></a>00596 } <a name="l00597"></a>00597 } <a name="l00598"></a>00598 } <a name="l00599"></a>00599 } <a name="l00600"></a>00600 <span class="comment">// remove headers without elements</span> <a name="l00601"></a>00601 foreach ($wizardItems as $key => $cfg) { <a name="l00602"></a>00602 $tmp = explode(<span class="charliteral">'_'</span>,$key); <a name="l00603"></a>00603 <span class="keywordflow">if</span> ($tmp[0] && !$tmp[1] && !in_array($tmp[0], $headersUsed)) { <a name="l00604"></a>00604 unset($wizardItems[$key]); <a name="l00605"></a>00605 } <a name="l00606"></a>00606 } <a name="l00607"></a>00607 } <a name="l00608"></a>00608 } <a name="l00609"></a>00609 <a name="l00610"></a>00610 <span class="comment">// Include extension?</span> <a name="l00611"></a>00611 <span class="keywordflow">if</span> (defined('TYPO3_MODE') && $TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['ext/cms/layout/db_new_content_el.php']) { <a name="l00612"></a>00612 include_once($TYPO3_CONF_VARS[TYPO3_MODE]['XCLASS']['ext/cms/layout/db_new_content_el.php']); <a name="l00613"></a>00613 } <a name="l00614"></a>00614 <a name="l00615"></a>00615 <a name="l00616"></a>00616 <a name="l00617"></a>00617 <a name="l00618"></a>00618 <a name="l00619"></a>00619 <a name="l00620"></a>00620 <a name="l00621"></a>00621 <a name="l00622"></a>00622 <a name="l00623"></a>00623 <a name="l00624"></a>00624 <a name="l00625"></a>00625 <a name="l00626"></a>00626 <span class="comment">// Make instance:</span> <a name="l00627"></a>00627 $SOBE = <a class="code" href="classt3lib__div.html#b47f8a8e8be44b79a0b8064dcd427bc1">t3lib_div::makeInstance</a>('<a class="code" href="classSC__db__new__content__el.html">SC_db_new_content_el</a>'); <a name="l00628"></a>00628 $SOBE->init(); <a name="l00629"></a>00629 <a name="l00630"></a>00630 <span class="comment">// Include files?</span> <a name="l00631"></a>00631 foreach($SOBE->include_once as $INC_FILE) include_once($INC_FILE); <a name="l00632"></a>00632 <a name="l00633"></a>00633 $SOBE->main(); <a name="l00634"></a>00634 $SOBE->printContent(); <a name="l00635"></a>00635 ?> </pre></div><?php include_once '../doc-typo3-funcs.php'; get_footer(); ?>