Hot answers tagged

4

You can do this with a simple module. You can set one up at pluginfactory.io with no controllers and a service called Email. If you're unsure about how modules work or how to set one up, I can highly recommend reading Andrew Welch's guide to creating a module in Craft 3. In this code, I've called the module 'MyModule' but you can give it any name you like. ...


3

If you are using the popular 'Contact Form' plugin, try Settings > Contact Form (under Plugins heading) and the field you want is the first field, 'To Email'. The variables in Globals are 100% custom but usually change the email address that is displayed sitewide such as in your footer or contact page. They can be, but are not necessarily, wired into your ...


3

You would need to attach such functionality to EVENT_AFTER_SAVE event in the custom php module. The module can be built using plugin factory website. For attaching functionality to the event, you don't need to select any additional components. https://pluginfactory.io/ You can find useful information about modules here: https://nystudio107.com/blog/enhancing-...


2

Found it, this works: <img src="{{ dataUrl('@webroot' ~ myAsset.getUrl({width: 200, height: 200}, true)) }}" /> Two important things: prepend the @webroot alias to the myAsset.getUrl(...) set the second parameter of getUrl(...) to true: myAsset.getUrl({...}, true). This ensures that a real file path is returned by getUrl, because the image ...


2

I think I figured out the problem. This was my first time switching to the project.yaml configuration Deleting and rebuilding the project config allowed me to change the Commerce > System Settings > Email > Language which fixed the error.


2

When using a frontend form to create a new user it is actually straight forward, because you can easily send a preferredLanguage attribute with the request that sets the language on creation (see this line in the user controller). However, if you want to use the CP form to create a user, there doesn't seem to be an out of the box solution for your problem. ...


1

After endless try and error I finally got it work. I used the ACE version of the email address e.g. client@clientwithö.de -> client@xn--clientwith-ncb.de Although I tried this at the beginning it is working now and I do not know what changed the result. :)


1

As the original poster reported in the comment above. This "looks like a completely different issue unrelated to email."


1

You can use Asset::setTransform or Asset::copyWithTransform to get (a copy) of the asset object with your transform applied. Then you can pass that into dataUrl(). {# Apply the transform to myAsset directly #} {% do myAsset.setTransform({width: 200, height: 200}) %} {{ dataUrl(myAsset) }} {# Use this if you need myAsset without the transform later #} {% ...


1

One method that comes to my mind is to create an asset configuration in admin panel (Settings -> Assets), where you can create different Image Transform configurations. For example, I can create an Image Transforms called Thumbnail then set the required dimensions and quality of the image. Once you create an Image Transforms, you can utilize them with ...


1

Simple step missing on the setup of this. I needed to actually assign this email to the status New, to send when a New order is placed, in the Order Statuses section, as per this documentation. So simply a case of RTFM: https://craftcms.com/docs/commerce/3.x/order-status-emails.html#selecting-an-email


1

In case someone else is struggling with this: For development purposes I usually install Craft taking a subdomain. So my base domain "name.com" has an SSL certificate, the subdomain "sub.name.com" doesn't - that's causing the same problem. Just add a SSL certificate to the subdomain aswell and it should be working fine. Hope it's helping ...


1

If you are just testing email under MAMP try using ToolHeap Mail tool: Test Mail Server Tool. It will save you a lot of headaches. George Campbell


Only top voted, non community-wiki answers of a minimum length are eligible