# Problemen bei Hooks unter Shopware 3.5.4

**URL:** <https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320>\
**Category:** Shopware 3.5\
**Tags:** programming\
**Created:** [27. Juni 2011 um 17:23 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320 "2011-06-27T17:23:55Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shopman](https://avatars.discourse-cdn.com/v4/letter/s/51bf81/32.png) [@Shopman](https://forum.shopware.com/u/Shopman)\
**Post date:** [27. Juni 2011 um 17:23 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320/1 "2011-06-27T17:23:55Z")

</div>

Hat schon jemanden Hooks unter Shopware 3.5.4 probiert? Ich habe dieser einfache Beispiel als Pluging installiert und sehen im Shop keine Änderungen! (Da will ich einfach Preis mal 1000 machen) Mache ich da etwas falsch? [code]\<?php class Shopware\_Plugins\_Frontend\_Example3\_Bootstrap extends Shopware\_Components\_Plugin\_Bootstrap  
{  
public function install()  
{

```
	$hookAfter = $this->createHook( 'sArticles', 'sGetArticleById', 'onArticle', Enlight\_Hook\_HookHandler::TypeAfter, 0 ); $this-\>subscribeHook($hookAfter); return true; } static function onArticle (Enlight\_Hook\_HookArgs $args) { $article = $args-\>getReturn(); $article["price"] = str\_replace(",",".",$article["price"]); $article["price"]\*= 1000; $article["price"] = $args-\>getSubject()-\>sFormatPrice($article["price"]); $args-\>setReturn($article); } } [/code]
```

---

<div class="post-metadata">

**Author:** ![ottscho](https://avatars.discourse-cdn.com/v4/letter/o/7ba0ec/32.png) [@ottscho](https://forum.shopware.com/u/ottscho)\
**Post date:** [28. Juni 2011 um 07:48 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320/2 "2011-06-28T07:48:02Z")

</div>

Lösche mal den Proxy und installiere das Plugin neu. Dann könnte es gehen 😉

---

<div class="post-metadata">

**Author:** ![Shopman](https://avatars.discourse-cdn.com/v4/letter/s/51bf81/32.png) [@Shopman](https://forum.shopware.com/u/Shopman)\
**Post date:** [28. Juni 2011 um 09:50 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320/3 "2011-06-28T09:50:21Z")

</div>

Proxy Datei habe ich gelöscht, also ich habe die myArticlesProxy.php gelöscht aber geht immer noch nicht. Hat jemand eine Idee?

---

<div class="post-metadata">

**Author:** ![ottscho](https://avatars.discourse-cdn.com/v4/letter/o/7ba0ec/32.png) [@ottscho](https://forum.shopware.com/u/ottscho)\
**Post date:** [28. Juni 2011 um 09:56 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320/4 "2011-06-28T09:56:02Z")

</div>

Bau mal in die static function onArticle ein ` die("test"); exit; ` ein. Und schau ob dies ausgegeben wird. Wenn nicht, wird der Code schon garnicht ausgeführt.

---

<div class="post-metadata">

**Author:** ![Shopman](https://avatars.discourse-cdn.com/v4/letter/s/51bf81/32.png) [@Shopman](https://forum.shopware.com/u/Shopman)\
**Post date:** [28. Juni 2011 um 10:22 UTC](https://forum.shopware.com/t/problemen-bei-hooks-unter-shopware-3-5-4/3320/5 "2011-06-28T10:22:24Z")

</div>

Wird gar nicht ausgeführt.
