# What event do I need for new orders

**URL:** <https://forum.shopware.com/t/what-event-do-i-need-for-new-orders/65545>\
**Category:** Programming (EN)\
**Created:** [17. März 2020 um 09:05 UTC](https://forum.shopware.com/t/what-event-do-i-need-for-new-orders/65545 "2020-03-17T09:05:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ronn0](https://avatars.discourse-cdn.com/v4/letter/r/3e96dc/32.png) [@ronn0](https://forum.shopware.com/u/ronn0)\
**Post date:** [17. März 2020 um 09:05 UTC](https://forum.shopware.com/t/what-event-do-i-need-for-new-orders/65545/1 "2020-03-17T09:05:45Z")

</div>

Good day everybody,

I’m quite new to programming for Shopware and did create a plugin, and load it with systems.xml, but when I subscribe to this event nothing happend on creating a new order in the checkout

```
public static function getSubscribedEvents(): array
{
    return[
        CartEvents::CHECKOUT_ORDER_PLACED => 'onCheckoutOrderPlaced'
    ];
}

/**
 * Test
 */
public function onCheckoutOrderPlaced(CheckoutOrderPlacedEvent $event)
{
    file_put_contents( __DIR__. '/test.log', 'test');
}

```

Is there something I am doing wrong?&nbsp;

&nbsp;

Kind. Regards&nbsp;

---

<div class="post-metadata">

**Author:** ![ronn0](https://avatars.discourse-cdn.com/v4/letter/r/3e96dc/32.png) [@ronn0](https://forum.shopware.com/u/ronn0)\
**Post date:** [17. März 2020 um 09:23 UTC](https://forum.shopware.com/t/what-event-do-i-need-for-new-orders/65545/2 "2020-03-17T09:23:09Z")

</div>

When I do listen to&nbsp;`Shopware\Core\Checkout\Cart\Event\CheckoutOrderPlacedEvent` is does work
