<?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/"
	>

<channel>
	<title>99° Labor</title>
	<atom:link href="http://labor.99grad.de/feed" rel="self" type="application/rss+xml" />
	<link>http://labor.99grad.de</link>
	<description></description>
	<pubDate>Fri, 20 Apr 2012 08:55:45 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Formhandler mit Newsletter-Anmeldung und Opt-In (formhandler, direct_mail, direct_mail_subscription)</title>
		<link>http://labor.99grad.de/%post-name%</link>
		<comments>http://labor.99grad.de/%post-name%#comments</comments>
		<pubDate>Fri, 20 Apr 2012 08:29:51 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Formhandler mit Newsletter-Abo]]></category>

		<guid isPermaLink="false">http://labor.99grad.de/?p=386</guid>
		<description><![CDATA[Hier eine Schritt-für-Schritt Anleitung, wie man ein Typo3-Kontaktformular mit Formhandler um eine Checkbox &#8220;Newsletter bestellen&#8221; erweitern kann, die über die direct_mail-Extension und direct_mail_subscription-Extension das Double-Opt-In übernimmt.
1. Extensions installieren und konfigurieren
Es werden folgende Extensions benötigt: direct_mail, direct_mail_subscription und formhandler und tt_address. Die folgende Beschreibung setzt voraus, dass diese Extensions installiert und korrekt konfiguriert wurden.
Das Mindest-TS-Setup für [...]]]></description>
			<content:encoded><![CDATA[<p>Hier eine Schritt-für-Schritt Anleitung, wie man ein Typo3-Kontaktformular mit Formhandler um eine Checkbox &#8220;Newsletter bestellen&#8221; erweitern kann, die über die direct_mail-Extension und direct_mail_subscription-Extension das Double-Opt-In übernimmt.</p>
<h3>1. Extensions installieren und konfigurieren</h3>
<p>Es werden folgende Extensions benötigt: <a href="http://typo3.org/extensions/repository/view/direct-mail" target="_blank">direct_mail</a>, <a href="http://typo3.org/extensions/repository/view/direct-mail-subscription" target="_blank">direct_mail_subscription</a> und <a href="http://typo3.org/extensions/repository/view/formhandler" target="_blank">formhandler</a> und <a href="http://typo3.org/extensions/repository/view/tt-address">tt_address</a>. Die folgende Beschreibung setzt voraus, dass diese Extensions installiert und korrekt konfiguriert wurden.<br />
Das Mindest-TS-Setup für direct_mail_subscription sollte sein:</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;">plugin.<span style="color: #006600;">feadmin</span>.<span style="color: #006600;">dmailsubscription</span> <span style="color: #66cc66;">&#123;</span>
  <span style="color: #808080; font-style: italic;"># SysFolder, in dem die tt_address-Einträge gespeichert werden</span>
  pid = <span style="color: #cc66cc;">144</span>
  email <span style="color: #66cc66;">&#123;</span>
    from = deine<span style="color: #66cc66;">@</span>email.<span style="color: #006600;">de</span>
    fromName = Direct Mail Subscription
    admin = deine<span style="color: #66cc66;">@</span>email.<span style="color: #006600;">de</span>
  <span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<h3>2. Formhandler-Template anpassen</h3>
<p>Eine Checkbox mit der Variable &#8220;newsletter&#8221; ins E-Mail-Formular einbauen:</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;"><span style="color: #66cc66;">&lt;</span>input <span style="color: #0066CC;">type</span>=<span style="color: #ff0000;">&quot;checkbox&quot;</span> <span style="color: #0066CC;">name</span>=<span style="color: #ff0000;">&quot;formhandler[newsletter]&quot;</span> value=<span style="color: #ff0000;">&quot;1&quot;</span> id=<span style="color: #ff0000;">&quot;newsletter&quot;</span> <span style="color: #808080; font-style: italic;">###checked_newsletter_1###/&gt; Ich möchte den Newsletter erhalten</span></pre></div></div>

<h3>3. Finisher für Formhandler erstellen</h3>
<p>Eine PHP-Datei mit dem Namen &#8220;<b>Tx_Formhandler_direct_mail_subscription.php</b>&#8221; im Filesystem anlegen, hier z.B. unter &#8220;<b>fileadmin/scripts/Tx_Formhandler_direct_mail_subscription.php</b>&#8221;</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;"><span style="color: #66cc66;">&lt;</span>?php
&nbsp;
<span style="color: #000000; font-weight: bold;">class</span> Tx_Formhandler_direct_mail_subscription <span style="color: #0066CC;">extends</span> Tx_Formhandler_AbstractFinisher <span style="color: #66cc66;">&#123;</span>
&nbsp;
	<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> process <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
&nbsp;
		$gp = $this-<span style="color: #66cc66;">&gt;</span>gp;
		$settings = $this-<span style="color: #66cc66;">&gt;</span>settings;
&nbsp;
		<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">!</span>$gp<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'newsletter'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #b1b100;">return</span> $gp;
&nbsp;
		require_once<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;typo3/sysext/cms/tslib/media/scripts/fe_adminLib.inc&quot;</span><span style="color: #66cc66;">&#41;</span>;
		require_once<span style="color: #66cc66;">&#40;</span>t3lib_extMgm::extPath<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'direct_mail_subscription'</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #ff0000;">'pi/class.dmailsubscribe.php'</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
		$conf = $GLOBALS<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'TSFE'</span><span style="color: #66cc66;">&#93;</span>-<span style="color: #66cc66;">&gt;</span>tmpl-<span style="color: #66cc66;">&gt;</span>setup<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'plugin.'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'feadmin.'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'dmailsubscription.'</span><span style="color: #66cc66;">&#93;</span>;
&nbsp;
		<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>$settings<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'optInPID'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
			$conf<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'formurl.'</span><span style="color: #66cc66;">&#93;</span> = <span style="color: #0066CC;">array</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'parameter'</span>=<span style="color: #66cc66;">&gt;</span>$settings<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'optInPID'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span>
&nbsp;
		$_POST<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'FE'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'tt_address'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'name'</span><span style="color: #66cc66;">&#93;</span> = $gp<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'name'</span><span style="color: #66cc66;">&#93;</span>;
		$_POST<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'FE'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'tt_address'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'email'</span><span style="color: #66cc66;">&#93;</span> = $gp<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'email'</span><span style="color: #66cc66;">&#93;</span>;
		$_POST<span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'FE'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'tt_address'</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">'module_sys_dmail_html'</span><span style="color: #66cc66;">&#93;</span> = <span style="color: #cc66cc;">1</span>;
&nbsp;
		$feadmin = <span style="color: #000000; font-weight: bold;">new</span> user_feAdmin<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
		$feadmin-<span style="color: #66cc66;">&gt;</span>cObj = t3lib_div::makeInstance<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'tslib_cObj'</span><span style="color: #66cc66;">&#41;</span>;
		$status = $feadmin-<span style="color: #66cc66;">&gt;</span>init<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">''</span>,$conf<span style="color: #66cc66;">&#41;</span>;
&nbsp;
		<span style="color: #b1b100;">return</span> $gp;
&nbsp;
	<span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span>
&nbsp;
?<span style="color: #66cc66;">&gt;</span></pre></div></div>

<h3>4. TS-Setup für Formhandler anpassen</h3>
<p>Folgende Anpassung für das TypoScript-Setup von Formhandler machen, damit der Finisher eingebunden wird. Als <b>optInPID</b> sollte die Seite angegeben werden, auf die der Opt-In-Link in der E-Mail führen soll. Hier macht es Sinn, das direct_mail_subscription-PlugIn als Inhaltselement zu platzieren, damit die Nachricht &#8220;Vielen Dank, Sie wurden erfolgreich registriert&#8221; etc. erscheinen.</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;">&nbsp;
<span style="color: #808080; font-style: italic;"># Pfad zu dem ORDNER, in dem sich die Klassen befinden!</span>
plugin.<span style="color: #006600;">Tx_Formhandler</span>.<span style="color: #006600;">settings</span>.<span style="color: #006600;">additionalIncludePaths</span>.1 = fileadmin<span style="color: #66cc66;">/</span>extensions<span style="color: #66cc66;">/</span>formhandler_eswe<span style="color: #66cc66;">/</span>
&nbsp;
plugin.<span style="color: #006600;">Tx_Formhandler</span>.<span style="color: #006600;">settings</span>.<span style="color: #006600;">predef</span>.<span style="color: #006600;">formular</span> <span style="color: #66cc66;">&#123;</span>
   <span style="color: #808080; font-style: italic;"># ... hier stehen die üblichen Konfigurationen ...</span>
   <span style="color: #808080; font-style: italic;"># Entscheidend ist dann das hier:</span>
   finishers <span style="color: #66cc66;">&#123;</span>
      1.<span style="color: #000000; font-weight: bold;">class</span> = Tx_Formhandler_direct_mail_subscription
      1.<span style="color: #006600;">config</span> <span style="color: #66cc66;">&#123;</span>
         <span style="color: #808080; font-style: italic;"># Hier die PID angeben, die nach dem Klick auf den Opt-In-Link geöffnet werden soll</span>
         optInPID = <span style="color: #cc66cc;">100</span>
      <span style="color: #66cc66;">&#125;</span>
   <span style="color: #66cc66;">&#125;</span> 
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<h3>Links und Dankeschöns</h3>
<p><a target="_blank" href="http://lists.typo3.org/pipermail/typo3-german/2011-July/079052.html">Eigener Finischer Beispiel von Dirk</a><br />
<a target="_blank" href="http://www.scribd.com/doc/67412682/48/How-to-use-your-own-controller s.47">Formhandler Dokumentation</a><br />
<a target="_blank" href="http://examples.typo3-formhandler.com/start/">Formhandler Offizielle Webseite</a><br />
<a target="_blank" href="http://mediavrog.net/blog/2008/03/25/typo3/direct-mail-newsletter-anmeldung-uber-mailformplus-oder-ein-anderes-kontaktformular/">Mediavrog Beispiel</a></p>
]]></content:encoded>
			<wfw:commentRss>http://labor.99grad.de/%post-name%/feed</wfw:commentRss>
		</item>
		<item>
		<title>TemplaVoila Cheat-Sheet</title>
		<link>http://labor.99grad.de/%post-name%</link>
		<comments>http://labor.99grad.de/%post-name%#comments</comments>
		<pubDate>Fri, 09 Mar 2012 13:23:51 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[templavoila cheat-sheet]]></category>

		<guid isPermaLink="false">http://labor.99grad.de/?p=381</guid>
		<description><![CDATA[Pfad zu mehreren hochgeladenen Bildern eines FCE ausgeben, z.B. um sie in einer Lightbox zu öffnen:

10 = COA
10 &#123;
  10 = HTML
  10 &#123;
    value.field = field_images
    value.split &#123;
      token = ,
      cObjNum = 1
   [...]]]></description>
			<content:encoded><![CDATA[<p>Pfad zu mehreren hochgeladenen Bildern eines FCE ausgeben, z.B. um sie in einer Lightbox zu öffnen:</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;"><span style="color: #cc66cc;">10</span> = COA
<span style="color: #cc66cc;">10</span> <span style="color: #66cc66;">&#123;</span>
  <span style="color: #cc66cc;">10</span> = <span style="color: #0066CC;">HTML</span>
  <span style="color: #cc66cc;">10</span> <span style="color: #66cc66;">&#123;</span>
    value.<span style="color: #006600;">field</span> = field_images
    value.<span style="color: #0066CC;">split</span> <span style="color: #66cc66;">&#123;</span>
      token = ,
      cObjNum = <span style="color: #cc66cc;">1</span>
      <span style="color: #cc66cc;">1</span> <span style="color: #66cc66;">&#123;</span>
        <span style="color: #cc66cc;">10</span> = IMG_RESOURCE
        10.<span style="color: #006600;">stdWrap</span>.<span style="color: #006600;">wrap</span> = <span style="color: #66cc66;">&lt;</span>span<span style="color: #66cc66;">&gt;|&lt;/</span>span<span style="color: #66cc66;">&gt;</span>
        <span style="color: #cc66cc;">10</span> <span style="color: #66cc66;">&#123;</span>
          file <span style="color: #66cc66;">&#123;</span>
            <span style="color: #0066CC;">import</span>.<span style="color: #006600;">current</span> = <span style="color: #cc66cc;">1</span>
            <span style="color: #0066CC;">import</span> = uploads<span style="color: #66cc66;">/</span>tx_templavoila<span style="color: #66cc66;">/</span>
            format = jpg
            <span style="color: #0066CC;">width</span> = 950c
            <span style="color: #0066CC;">height</span> = 700c
          <span style="color: #66cc66;">&#125;</span>
        <span style="color: #66cc66;">&#125;</span>
      <span style="color: #66cc66;">&#125;</span>
    <span style="color: #66cc66;">&#125;</span>
  <span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://labor.99grad.de/%post-name%/feed</wfw:commentRss>
		</item>
	</channel>
</rss>

