<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Blog for the Web Programmers &#187; &#8211;div&#8211;</title>
	<atom:link href="http://blog.chandanweb.com/tags/div/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.chandanweb.com</link>
	<description>A useful blog with code assitance on Typo3, Drupal, PHP, Apache, OpenSSL and PHP Frameworks</description>
	<lastBuildDate>Thu, 08 Jul 2010 05:44:43 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Dividers to Tabs in Extensions</title>
		<link>http://blog.chandanweb.com/typo3/dividers-to-tabs-in-extensions</link>
		<comments>http://blog.chandanweb.com/typo3/dividers-to-tabs-in-extensions#comments</comments>
		<pubDate>Thu, 04 Feb 2010 06:11:11 +0000</pubDate>
		<dc:creator>spabhat</dc:creator>
				<category><![CDATA[Extension Programming]]></category>
		<category><![CDATA[Typo3]]></category>
		<category><![CDATA[--div--]]></category>
		<category><![CDATA[dividers2tabs]]></category>
		<category><![CDATA[record tabs]]></category>
		<category><![CDATA[tabs for insert records]]></category>
		<category><![CDATA[Tabs in Extensions]]></category>

		<guid isPermaLink="false">http://blog.chandanweb.com/typo3/dividers-to-tabs-in-extensions</guid>
		<description><![CDATA[This article explains how easily we can get Tabs in the content elements of type &#8220;insert records&#8221;. Generally we will need to edit tca.php and ext_tables.php. To be more specific it involves adding two parameters. 1. Specify that you are using dividers to tabs &#8220;dividersstabs&#8221; 2. Mark all tabs using &#8211;div&#8211; Let us see how. [...]]]></description>
			<content:encoded><![CDATA[<p>This article explains how easily we can get Tabs in the content elements of type &#8220;insert records&#8221;.</p>
<p>Generally we will need to edit tca.php and ext_tables.php.</p>
<p>To be more specific it involves adding two parameters.</p>
<p>1. Specify that you are using dividers to tabs &#8220;dividersstabs&#8221; <br/>2. Mark all tabs using &#8211;div&#8211;</p>
<p>Let us see how.</p>
<h4>1. Specify that you are using dividers to tabs &#8220;dividersstabs&#8221;</h4>
<p>In the TCA array first look at the start of table definition. Generally this is located</p>
<blockquote><p>EX: <br/></p>
<pre>
$TCA['tx_myext_table] = array (
        'ctrl' =&gt; array (
                'title' =&gt; 'LLL:EXT:myext/locallang_db.xml:tx_myext_table,
                'label' =&gt; 'title',
                'tstamp' =&gt; 'tstamp',
                'crdate' =&gt; 'crdate',
                'cruser_id' =&gt; 'cruser_id',
                'languageField' =&gt; 'sys_language_uid',
                'transOrigPointerField' =&gt; 'l10n_parent',
                'transOrigDiffSourceField' =&gt; 'l10n_diffsource',
                'sortby' =&gt; 'sorting',
                'delete' =&gt; 'deleted',
                'dividers2tabs' =&gt; TRUE,
                'enablecolumns' =&gt; array (
                        'disabled' =&gt; 'hidden',
                ),
                'dynamicConfigFile' =&gt; t3lib_extMgm::extPath($_EXTKEY).'tca.php',
                'iconfile' =&gt; t3lib_extMgm::extRelPath($_EXTKEY).'icon_tx_myext_table.gif',
        ),
);
</pre>
</blockquote>
<p>In the above config you can see that <strong>&#8216;dividers2tabs&#8217; is set to TRUE</strong></p>
<pre>
2. Mark all tabs using --div--
</pre>
<p>This is the step in which you would group all fields into different Tabs. This generally involves editing the TCA config usually locatd in tca.php. <br/></p>
<pre>
In tca.php, look the section showitem, and add --div--;Tab Name,
</pre>
<blockquote>
<pre>
EX:
'types' =&gt; array (
        '0' =&gt; array(
                'showitem' =&gt; '--div--;General,
                                sys_language_uid;;;;1-1-1, l10n_parent,
                                l10n_diffsource, hidden;;1,
                                --div--;Content,title;;;;3-3-3, parentid,top_page,content,
                                --div--;Header and Footer,footer,
                                background_image,background_align'
                )
),
</pre>
</blockquote>
<p>As you can see I have added 3 tabs, General, Content, Header and Footer. <br/></p>
<pre>
The idea is to add --div--; (two hypen followed by div and two hyphen and semicolon)
</pre>
<p><br/>After semicolon add the &#8220;Title of your tab&#8221; and followed by a comma. <br/></p>
<pre>
This section <strong>--div--;Tab Name,</strong> must be added just before a field, or after a field ends.
</pre>
<p>That should be it.</p>
<p>Happy coding.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.chandanweb.com/typo3/dividers-to-tabs-in-extensions/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
