Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [craft3]

For use with questions relating to the Craft 3 version of Craft CMS, including the Beta and RC releases.

0
votes
0answers
1 view

Is it possible to change the group that a user belongs in the front-end?

A little background: I working on a website running Craft v.3 Pro and Commerce v.2 Pro The user can register as a member from the front-end. They will be able to select only one of 3 different ...
0
votes
0answers
10 views

Get entries whose title has a keyword or related to a category's title

I am trying to get entries that either their title has the keyword or their category field title. I am getting them from my plugin, not twig. I tried like this: $keywordCategory= Category::find()->...
0
votes
0answers
13 views

Craftcms 3 search form with filters

{% extends "_layouts/main" %} {# till nav #} {% block main %} <section class="content"> <h1>Search Results</h1> {% set searchParam = '' %} {# param handle #} ...
0
votes
1answer
14 views

Craft 3 - Matrix Block for currentUser

I have a matrix block named -> certificado with block -> certificados and fields -> nomeDoCurso, curso, certificado My matrix block has no entries, but is associated to a user. How can i fetch the ...
0
votes
0answers
7 views

Freeform Plugin: Form not redirecting to Success Page with Ajax

I have defined {{ siteUrl }}contact/success as my Return URL Ajax is turned on. I have uncommented the following in ajaxify.html if (response.returnUrl) { window.location.href = response....
0
votes
1answer
6 views

Freeform Plugin: Success Page and Submission ID - Template not Found

I am getting the following error when redirecting the form success message to a page. I am trying to pass in the submission ID... HTTP 404 – Not Found – yii\web\NotFoundHttpException Template not ...
0
votes
0answers
14 views

Craft 3 cannot upload file to entry in Control Panel

Cannot upload file to entry in CP from a form in the frontend of the site. The flash message in the CP is: Entry could not be saved. {% set section = craft.sections.getSectionByHandle('areaprivada') ...
1
vote
0answers
20 views

Missing templates using PHPStorm when using Craft 3

Following code show a warning "template not found" in PHPStorm: {% extends '_layout' %}. When adding .twig this warning dissapears, but I'd like to keep extends and includes filetype agnostic. What ...
1
vote
1answer
16 views

How do you get the user id on the front-end?

I'm using Craft Pro to make a website where users have a private area. Users register and when login happens they are redirected to a page in the private area with respective info about that user. ...
0
votes
0answers
17 views

templatecachequeries entries with of 157.000 characters in query column

after enableling querycaching in craft3 I found rows in templatecachequeries with big amount of characters in the query field. I decoded it with base64 and got this as the largest entry: query_length:...
1
vote
1answer
19 views

How to display images in templates

I am new to Craft CMS and struggling to figure out how to display my logo in my template. The error message is: Variable "siteLogo" does not exist This is the code I am using: {% for asset in ...
1
vote
1answer
22 views

Extend templates from outside templates directory

I have a setup where I'm using a component library that I have as an npm package. To use these components I need to extend templates that live outside of the /templates directory. So I need to achieve ...
1
vote
1answer
9 views

'Unable to find component class 'FocusPoint_FocusPoint' - Craft CMS 3 Migrating from Focus Point Fields

I am migrating from Craft 2 to Craft 3 where images have Focus Point fields. I've followed Dan Hoerr's FocalPoint Migration (migration guide) And the php migrate script seems to have run successfully,...
0
votes
0answers
12 views

Live preview breaks if adding trailing slash to htaccess

I noticed after one of the latest updates that live preview is no longer working, I seem to have narrowed it down to htaccess file which we have modified to add a trailing slash to all urls. e.g. # ...
1
vote
0answers
26 views

How to download private assets (without public URL) from dashboard

I would like to download asset files from Craft 3 dashboard. Those files are out of web folder because of security reason. I made "documents" folder just under the root of the project, and the files ...
0
votes
0answers
18 views

500 Memory Limit When uploading Images

Currently been getting the following error when trying to upload images: PHP Fatal Error 'yii\base\ErrorException' with message 'Allowed memory size of 268435456 bytes exhausted (tried to ...
1
vote
1answer
22 views

Matrix Field - variable entry does not exist

I'm trying to loop a Matrix field that has one block containing 3 items. {% for block in entry.galeria.type('itemsGaleria') %} {% if block.titulo|length %} {{ block.titulo.first }} {% ...
0
votes
0answers
21 views

Web installation fails

I am new to Craft and when I attempted at completing my Craft setup on the web the installation eventually failed, prompting me to check my error logs. When I try to restart the installation process ...
1
vote
0answers
27 views

Craft 3 CMS Poll Plugin

Are there any poll plugins available for Craft 3? As in have radio buttons, show % results for number of people that have voted for the different options after submission. Thanks
0
votes
0answers
11 views

Install Amazon plugin from Admin panel show error “No plugin exists with the handle ”aws-s3“.”

When install the plugin by the admin panel, show the below error.
3
votes
2answers
25 views

How do you save a new Entry to be enabled on 2+ Sites?

I've made a plugin that let's you import Entries from a CSV file and I'm working through adding localization (Sites) support to it, but I can't figure out the right way to enable an Entry for a second ...
1
vote
1answer
13 views

Craft 3 best way/steps to create a login client area in frontend

I have to make a website that needs an user area with login. In that area users should be able to upload to admin area or download files from admin area. Each user has its own account that is ...
0
votes
0answers
26 views

Emojis on Craft 3 front office

I'm making a blog. I have a wheelform comments input type that needs to be stored as utf8mb4 in the local database. My MySQL database version 5.6 is configured to utf8mb4 in the database, tables, ...
1
vote
1answer
23 views

Entry form with field translated accross multiple sites

I've got 2 sites, each with a locale (dutch - nl & french - fr). I've set up a frontend entry form that works nicely for all not translated fields, I am however struggling to get it to accept ...
1
vote
1answer
25 views

Custom Plugin for ZenDesk Tickets

I need all of the custom fields on an order submitted to ZenDesk to create a new ticket once the order is completed. Once a ticket is created in ZenDesk, we will need the ticket number saved on a new ...
1
vote
2answers
31 views

Which is the best place to learn Craft CMS with tutorials?

I am new to craft cms and would like to learn craft cms with tutorials. I am ready to pay for the subscription but would like to know is there any best place where I can learn the craft ?
1
vote
1answer
21 views

Craft 3 vs Apache directory structure

I am new to Craft CMS and am struggling with what and how to get the correct files in the right places. I started out with a LAMP stack on a Ubuntu 18.04 Digital Ocean droplet and proceeded with the ...
1
vote
0answers
11 views

Setting Quantity Field on Subscriptions

How can I pass in a quantity value while creating a subscription? Plugin (version): Craft CMS (3.1.21) Craft Commerce (2.1.2) Stripe for Craft Commerce (1.2.0) Problem: My website allows users to ...
0
votes
0answers
39 views

Is there some schema on gateway development?

I'm trying to make new offsite gateway(at my case for netaxept). Checked a lot of documentations and some gateway packages, but haven't clear view on how it should work and what moments are required ...
1
vote
1answer
9 views

Use a UUID for an entry ID in a URL path

When setting an "Entry URI Format" for a section, the values currently available to me are {slug} which is the title of the entry, or {id} which is usually a small number. I'd like to have an ...
0
votes
1answer
17 views

Ajax Contact Form not sending with Error 400

Hi I have I'm using Craft CMS 3.1.21.1 with the Contact Form plugin version (2.2.4) and Contact Form Honeypot plugin (1.0.2) along with jquery 3.2.1 on the site. Whenever the form is filled out and I ...
1
vote
1answer
23 views

Craft 3 CMS Solo setting general Logo option

I have installed Craft 3 Solo and it's installed on my local machine. I would like to know how can I get an option in Setting -> General to Logo (upload Login Page Logo). I am new to Craft, so would ...
1
vote
1answer
22 views

Order entries by a category field alphabetically then paginate

I've tried so many different things and can't get this to work... {% set makeCat = craft.categories() .group('make') .orderBy('title') .limit(21) %} {% paginate makeCat as pageInfo, ...
-1
votes
0answers
14 views

Sprout SEO upgrade breakage

Upgraded from Craft 2.6.2797 to Craft 3.1.21.1. Completely new file system, using mysqldump of old 2.6 installation. From this point, I had no plugins. Copied over the templates from the old install. ...
1
vote
2answers
30 views

Craft Commerce cart product as unique product with different notes

Our client wants a specific option built in Craft Commerce. I guess is possible, but don't know how? Maybe you can help me out? A customer selects a box: for example "giftbox custom 4" (priced $ 15). ...
1
vote
0answers
18 views

Query on Super Table field's entry field

I have a section with a Super Table field that has an entry field. Now I want to find the entries that have a relation to that entry. I found this answer here. This but I can not get it to work with ...
1
vote
2answers
67 views

CraftCMS config on WTServer / WinNMP for Windows with Nginx

Has anyone had success with using Craft and WTServer (WinNMP) together? I'm getting a 400 error at "http://craft.test/index.php?p=admintrigger/actions/users/login" after trying to login the admin. I'm ...
1
vote
1answer
21 views

Show events in month by specific category - Solspace Calendar

I've set up a category field for events. Multiple categories can be chosen. And I've set up a form to "filter" events to a specific category using query parameters. The URL looks something like this (...
1
vote
1answer
90 views

Error pages in multi site setup

I have a multi site setup for supporting multiple languages in Craft 3. '/' => German '/en/' => English In my general.php I have 'errorTemplatePrefix' => 'error/', When I enter '/...
-1
votes
0answers
13 views

siteSwitcher not working

I moved live site to on my local. And I get this error "Unknown 'siteSwitcher' function." Composer install already done and SiteSwitcher plugin exist in vendor directory. I am not sure why this is not ...
3
votes
1answer
24 views

How can additional custom fields be added to the Sites settings?

In Craft 3 Sites, there are some default fields like language, handle, etc. I would like to add additional fields. Is this possible. Specifically, I want to add an Image field so we can add a flag ...
2
votes
1answer
62 views

How do I prevent secrets beeing logged in the PHP error log?

Background: I'm running Craft Pro 3.1.19 on PHP 7.2.15 Craft CMS, by default, uses vlucas/phpdotenv to get the configuration (containing secrets / credentials and lots of other stuff) from .env ...
1
vote
1answer
39 views

Custom module that can define and have settings referenced (Craft 3)

I'm currently working on migrating a Craft 2 project which has a bunch of bespoke custom plugins that provided various bits of additional functionality that's tailored to this project only. I've been ...
0
votes
1answer
27 views

TypeError: Argument 1 passed to craft\services\Fields::getGroupById() must be of the type integer, null given

When I go to control panel > Settings > Fields, I get a page that throws TypeError: Argument 1 passed to craft\services\Fields::getGroupById() must be of the type integer, null given This is ...
1
vote
1answer
21 views

Can't login after restoring production DB locally

I'm attempting to restore a postgres DB backup on to my local dev environment but I encounter an error when trying to login as the admin user (the salient parts being): SQLSTATE[23502]: Not null ...
1
vote
1answer
18 views

Gatekeeper/Knock Knock Pluging not working

I feel like there must be something i've missed but i've followed the ReadMes for both of these plugins and they don't seem to work on my website. Does anyone have any experience with them? I'm ...
2
votes
1answer
23 views

Craft CMS V3 Create New User

Having difficulties creating a new user in a custom controller, here's my implementation: use craft\records\User; $user = new User; $user->firstName = $userData['firstName']; $user->lastName = ...
0
votes
1answer
11 views

Fee Me Plugin: Can Match fields but feed not importing

I can detect and match up the fields from my json file but when doing the import I get the following error in the log: No feed items to process. 3/28/2019 2:53 PM error Unable to reach data/case-...
-1
votes
0answers
22 views

Element API - Get slug of entries with same ID in other sites/locales

I am using the element-api to get entries. What I would like to do is have the slug of entries in the other languages in the data that correspond with ID of each entry. This is so I can use this in my ...
-1
votes
0answers
25 views

Returning A Plugin Date Setting

So I'm diving into Plugin development with Craft. Loving it so far, it's so easy to get started! But, I can't find any documentation on standard returning/initialization for all the different field ...