Created
September 9, 2015 15:25
-
-
Save christian-fries/70f6cf1b9d2f0f8ca380 to your computer and use it in GitHub Desktop.
Neos 2.0 ContentCollection without wrapping DIV tag (div.neos-contentcollection)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prototype(TYPO3.Neos:ContentCollection) { | |
@class = 'ACME\\SitePackage\\TypoScriptObjects\\TagImplementation' | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// In the Root.ts2 of your site package, include the custom ContentCollection prototype | |
include: ContentCollection.ts2 | |
// Your template typoscript here |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace ACME\SitePackage\TypoScriptObjects; | |
/* * | |
* This script belongs to the TYPO3 Flow package "TYPO3.TypoScript". * | |
* * | |
* It is free software; you can redistribute it and/or modify it under * | |
* the terms of the GNU General Public License, either version 3 of the * | |
* License, or (at your option) any later version. * | |
* * | |
* The TYPO3 project - inspiring people to share! * | |
* */ | |
use TYPO3\Flow\Annotations as Flow; | |
/** | |
* Return only content, don't render tag | |
*/ | |
class TagImplementation extends \TYPO3\TypoScript\TypoScriptObjects\TagImplementation { | |
/** | |
* Return content without tag | |
* | |
* @return mixed | |
*/ | |
public function evaluate() { | |
return $this->tsValue('content'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment