New answers tagged

0

If that is really all that you're doing, and you have no other integration with Craft, you can parse the .env however you like. Craft uses vlucas/phpdotenv internally so that library is already in your vendor directory. You should be able to pick that up after including Composer's autoloader. If however you have any kind if integration with Craft, look at ...


2

As per the docs at https://craftcms.com/docs/3.x/extend/element-types.html#saving-custom-field-values When saving values on a custom field, always use the setFieldValue() or setFieldValues() methods rather than directly accessing the field handle as a property on the element object. This ensures the value is normalized and marked as dirty for delta saves. $...


1

The priority option is for setting the jobs in priority order before they start. A job that is already running will not be interrupted for a more important one. I would suggest setting up another queue for the longer tasks. That way, your smaller tasks can continue to run separate to the more demanding ones. There is some guidance on how to do this on an ...


Top 50 recent answers are included