# Plugin Konfiguration - Button 'handler' neues Element/Feld in der Konfiguration einfügen

**URL:** <https://forum.shopware.com/t/plugin-konfiguration-button-handler-neues-element-feld-in-der-konfiguration-einfugen/37003>\
**Category:** Programmierung\
**Created:** [26. Mai 2016 um 05:56 UTC](https://forum.shopware.com/t/plugin-konfiguration-button-handler-neues-element-feld-in-der-konfiguration-einfugen/37003 "2016-05-26T05:56:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nibo](https://avatars.discourse-cdn.com/v4/letter/n/edb3f5/32.png) [@Nibo](https://forum.shopware.com/u/Nibo)\
**Post date:** [26. Mai 2016 um 05:56 UTC](https://forum.shopware.com/t/plugin-konfiguration-button-handler-neues-element-feld-in-der-konfiguration-einfugen/37003/1 "2016-05-26T05:56:13Z")

</div>

Hallo Zusammen!

Ich hätte gerne für mein Plugin in der Plugin-Konfiguration einen Button über den ich weiter Elemente hinzufügen kann?

&nbsp;

Aus anderen Beiträge habe ich erfahren dass das Aufrufen von Php-Funktion dort nicht funktioniert -. Nun habe ich meine JavaScript function für den Handler :

$form-\>setElement(‚button‘, ‚button‘,  
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;array(  
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;‚label‘ =\> ‚Click here‘,  
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;‚handler‘ =\> ‚function(btn) { alert(„This is my JavaScript function!“); }‘  
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;)  
&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;);

, nun müsste ich von&nbsp;dort aus an das Konfigurations-Formular komme um über die Funktion ein weiteres Element hinzuzufügen. Oder gibt es doch eine andere Möglichkeit?

---

<div class="post-metadata">

**Author:** ![shyim](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/shyim/32/7681_2.png) [@shyim](https://forum.shopware.com/u/shyim)\
**Post date:** [27. Mai 2016 um 19:22 UTC](https://forum.shopware.com/t/plugin-konfiguration-button-handler-neues-element-feld-in-der-konfiguration-einfugen/37003/2 "2016-05-27T19:22:07Z")

</div>

Du möchtest anhand eines Buttons mehrere Felder in die Plugin Konfiguration einfügen oder wie?

---

<div class="post-metadata">

**Author:** ![Nibo](https://avatars.discourse-cdn.com/v4/letter/n/edb3f5/32.png) [@Nibo](https://forum.shopware.com/u/Nibo)\
**Post date:** [30. Mai 2016 um 06:33 UTC](https://forum.shopware.com/t/plugin-konfiguration-button-handler-neues-element-feld-in-der-konfiguration-einfugen/37003/3 "2016-05-30T06:33:43Z")

</div>

Ja genau! Ich möchte es dem Plugin Nutzer überlassen wie viele Parameter er übergibt.

Ein Feld soll pflicht sein. Und er soll eben über den Button die Möglichkeit haben weitere Felder hinzuzufügen
