Unanswered Questions

1,154 questions with no upvoted or accepted answers
9
votes
0answers
661 views

How do I upload images programmatically?

I'm working on a plugin that creates auto crops of a selected image, but I am unsure of the proper steps to create and upload an image programatically. I am hoping that Local asset sources and Remote ...
6
votes
0answers
218 views

Solspace Freeform Upload file dynamic location and duplicate file avoidance

Using Freeform for forms which have multiple file upload fields. Is it possible to have a unique asset directory for each submission? For example: uploads/maindirectory/submission.id/ I'm trying to ...
5
votes
0answers
266 views

How to load components into Craft 3 plugin?

what is the correct way to load third-party components into Craft 3 plugin I'm developing? I tried adding $this->setComponents([ 'authClientCollection' => [ 'class' => '\yii\...
4
votes
0answers
299 views

Craft 3 Custom Plugin: model validation

Struggling a bit here - have created a custom plugin where I want to validate form submission against a predefined model before saving to the database. All pretty straightforward so far … However, if ...
4
votes
0answers
731 views

How to handle Craft 3 events in a plugin? Element API is returning null data

The below refers to Craft 3 and the Element API plugin for Craft 3. I would like to do something when the Element API plugin fires its onBeforeSendData event, I can see in the controller for element ...
4
votes
0answers
231 views

Using plugin template on front end

I'm working on a plugin called modelselector and I want to use a template stored in the plugin templates folder but it should be shown on the front-end of the website. Currently the following direct ...
4
votes
0answers
127 views

Eagerloading Matrix fields resulting in empty array

I'm trying to eager-load a Matrix field with it's blocktype and related field types. For some reason the _eagerLoadedBlockTypeElements are empty arrays. If I get rid of the with clause on ...
4
votes
0answers
2k views

runtime isn't writable by PHP. Please fix that

I keep getting the error: mydomain.com/craft/storage/runtime isn't writable by PHP. Please fix that. I am running Redhat, and have set the folder permissions to 777, any ideas? Thanks in advance.
3
votes
0answers
75 views

Dukt Social Plugin Not Creating User

I'm currently Authenticating users via OAuth and Social Login by Dukt. I have Facebook app all set up and running as well as Twitter. The user gets redirected, asked to Authorise but when it returns ...
3
votes
0answers
259 views

Mailer config in Craft 3 not getting merged

I have this custom config in config/app.php, but Craft seems to keep using the default Control panel Sendmail config. It seems this doesn't get merged in the main.php file. (as promised) return [ '...
3
votes
0answers
81 views

Algolia indexing disabled items in Craft

We have Algolia search running on our Craft install through the Search Plus plunin. When I disable an entry I'm finding that it is still searchable through Algolia, which then results in a broken link....
3
votes
0answers
184 views

Is there any way to include Solspace Calendar events in a global site search?

I have a client that wants their Solspace Calendar Events to show up in the global site search results (along with entries from other sections) My first thought was to query the entries and calendar ...
3
votes
0answers
273 views

Restrict each user to a single Assets folder

I need every control panel user to have a single assets folder that is private to them. Is there any way of achieving this in Craft? I've tried using the "Restrict uploads to a single folder?" option ...
3
votes
0answers
442 views

Currency switcher

Folks: I'm setting up a multi-currency site (CAD, USD, EUR). I'd like the user to be able to select their currency before they actually put anything in the cart. And once selected, prices throughout ...
3
votes
0answers
274 views

Task “Resaving all localizable elements” is stuck when adding new new locale

I'm trying to add a new locale, but the task "Resaving all localizable elements" is stuck and the new locale is not being added to content. Even after restarting the task. There are no errors in the ...

15 30 50 per page