[TYPO3-mvc] including frontent plugin with typoscript doesn't work

Thomas Hucke thucke at web.de
Sun Oct 9 14:53:21 CEST 2011


Hey Miguel,

I think you´ve got a mistake in cascading your sections.
Section "newsletter" is closed right after section "switchableControllers".
You have to make sure that you also include "persistence" and "view".
Try

plugin.tx_attacforms{
newsletter = USER
newsletter {
  userFunc=tx_extbase_core_bootstrap->run
  pluginName=Pi8
  extensionName=Attacforms
  controller=Newsletter
  action=index
  switchableControllerActions {
   Newsletter {
    1=index
   }
  }
  settings {
  }
  persistence{
   # cat=plugin.tx_blogexample//a; type=int+; label=Default storage PID
   storagePid=121
  }
  view {
   # cat=plugin.tx_blogexample/file; type=string; label=Path to template
   root (FE)
   templateRootPath=EXT:attacforms/Resources/Private/Templates/
   # cat=plugin.tx_blogexample/file; type=string; label=Path to template
   partials (FE)
   partialRootPath=EXT:attacforms/Resources/Private/Partials/
   # cat=plugin.tx_blogexample/file; type=string; label=Path to template
   layouts (FE)
   layoutRootPath=EXT:attacforms/Resources/Private/Layouts/
  }
}
}
###
page=PAGE
page.10=COA
page.10{

10=TEXT
10.value=<h3>Bundes-Newsletter</h3>
20<plugin.tx_attacforms.newsletter
}



"Miguel Ayala"  schrieb im Newsbeitrag 
news:mailman.1368.1318161280.633.typo3-project-typo3v4mvc at lists.typo3.org...

Hello Thomas,
thanks for your reply, I tried your suggestions, but it didnt change
anything, I tried a couple of other things too, like changing storagePid
or leaving it out alltogether, but I am really out of ideas. This
configuration always displays the whole TS setup on the frontpage and
then the normal page, it is really frustrating. If someone has a clue
why this would happen, please feel free to share.
cheers
miguel


currently this my TS:
plugin.tx_attacforms{

newsletter=USER
newsletter{
userFunc=tx_extbase_core_bootstrap->run
pluginName=Pi8
extensionName=Attacforms
controller=Newsletter
action=index
switchableControllerActions{
Newsletter{
1=index
}
}
}
settings{
}
persistence{
# cat=plugin.tx_blogexample//a; type=int+; label=Default storage PID
storagePid=121
}
view{
# cat=plugin.tx_blogexample/file; type=string; label=Path to template
root (FE)
templateRootPath=EXT:attacforms/Resources/Private/Templates/
# cat=plugin.tx_blogexample/file; type=string; label=Path to template
partials (FE)
partialRootPath=EXT:attacforms/Resources/Private/Partials/
# cat=plugin.tx_blogexample/file; type=string; label=Path to template
layouts (FE)
layoutRootPath=EXT:attacforms/Resources/Private/Layouts/
}
}
###
page=PAGE
page.10=COA
page.10{

10=TEXT
10.value=<h3>Bundes-Newsletter</h3>
20<plugin.tx_attacforms.newsletter
}

On 10/08/2011 08:25 AM, Thomas Hucke wrote:
> Give it a try and set
>
> switchableControllerActions{
> Newsletter{
> 1=index
> }
>
> Just remove "2=mail" in switchableControllerActions.
>
> Regards
> Thomas
>
>
>
> "Miguel Ayala"  schrieb im Newsbeitrag 
> news:mailman.431.1317907808.633.typo3-project-typo3v4mvc at lists.typo3.org...
>
> Hello List,
> I am having a Problem with a Newsletter Plugin that doesnt work, when I
> try to include it via TS.
> It works as content element though, it is just an input field for
> emails, with two actions: indexAction(), mailAction().
> This is my TS:
> page=PAGE
> page{
>
> typeNum=0
> 10=COA
> 10{
> 10=TEXT
> 10.value=<h3>Bundes-Newsletter</h3>
> 20<USER
> 20{
> userFunc=tx_extbase_core_bootstrap->run
> pluginName=Pi8
> extensionName=Attacforms
> controller=Newsletter
> action=index
> switchableControllerActions{
> Newsletter{
> 1=index
> 2=mail
> }
> }
> settings=<plugin.tx_attacforms.settings
> persistence=<plugin.tx_attacforms.persistence
> view=<plugin.tx_attacforms.view
> }
>
> Strangely enough it does work, when I change "20<USER" to "20 = USER",
> but the frontpage loads width an array of the whole
> Typo3 configuration, like a display of debug. And on the bottom of the
> page the normal content is shown.
> I tried different ways of writing this code, like:
>         plugin.tx_attacforms {
>
> newsletter = USER
> newsletter {
> userFunc = tx_extbase_core_bootstrap->run
> pluginName = Pi8
> extensionName = Attacforms
> controller = Newsletter
> action = index
> switchableControllerActions {
> AdminMenu {
> 1 = index
> 2 = mail
> }
> }
> settings =< plugin.plugin.tx_attacforms.settings
> persistence =< plugin.plugin.tx_attacforms.persistence
> view =< plugin.plugin.tx_attacforms.view
> }
>
> and then 20 < plugin.tx_attacforms.newsletter, the result is the same.
>
> Does anybody have a clue, what is happening here?
> Help is much appreciated.
> cheers miguel
> _______________________________________________
> TYPO3-project-typo3v4mvc mailing list
> TYPO3-project-typo3v4mvc at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc
> 



More information about the TYPO3-project-typo3v4mvc mailing list