Questions tagged [craft2]

Questions specific to the Craft 2 version of Craft CMS; avoid using for questions applicable to all or multiple versions.

30 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
2
votes
0answers
218 views

Order entries by custom date field

I want to modify this query so that the dated entries are sorted in descending order on a custom field called 'startDate'. Have tried adding .order('startDate') to the end of the craft.entries(query)....
2
votes
0answers
64 views

Can you make Craft 2 Stateless?

So we are moving to Google App Engine Flexible which means we cannot store sessions on files. So I wanted to know if anyone has been able to make Craft 2 Stateless and how was it accomplished? Thanks....
1
vote
1answer
52 views

How to build a web page using different sections created in Craft

I am a beginner in Craft. I have a Craft website. There is an HTML design with me. From admin, I divided the HTML into sections and created entries based on that. All the coding related to each ...
1
vote
0answers
82 views

Freeform submission only works if 'devMode' => true

I have a locally running form via Solspace's Freeform plugin (Craft2) which perfectly runs on my local setup, but fails silently without any logs or messages on my live-setup. The form is submitting ...
1
vote
0answers
15 views

Templating not displaying after Craft server migration

A small team and I have inherited a Craft 2 site. We are brand new to craft with no previous experience with it. In wanting to work on offline copies of the sight the team is attempting to migrate the ...
1
vote
1answer
68 views

Craft error on NFS filesystem

I have a Craft 2 install that's been working fine until recently when the admin page is giving an error: file_put_contents(): Exclusive locks are not supported for this stream The front end is fine....
1
vote
0answers
27 views

Shipping and billing addresses dissapear when close and open the page

I have the following problem. When I set shipping and billing address on my cart and exit the page, the addresses are cleared once I open the page again. Is it possible to disable this behavior? ...
1
vote
0answers
77 views

Avoiding includeJsFile, includeJS from caching

In my template, I have an includeJSFile that loads properly on the first load, but disappears on subsequent loads. The includeJSFile is outside the caching tags, so I'm not sure why this is still ...
1
vote
0answers
21 views

modifyEntrySources hook with reverse relations

Is it possible to do a reverse relation query in a custom entry source? https://docs.craftcms.com/v2/plugins/hooks-reference.html#modifyentrysources I have two entry sections, one called courses and ...
0
votes
0answers
13 views

Updated S3 library for Craft CMS 2

I've got a site stuck on an older version of Craft, v2. I'd like to switch to using S3 to store all my assets but I've ran into a problem. I cannot authenticate using the S3 api library, this is one ...
0
votes
1answer
19 views

How do I upgrade the MYSQL database from Craft 2 to Craft 3 on GoDaddy

How do I upgrade my MySQL DB for a Craft 2 site to Craft 3. I don't have access to the SSH server or use of Composer, so I have to move files via FTP and do everything manually. My client is on ...
0
votes
0answers
10 views

Category filter with localization?

I'm using craft 2 and have a list of category which are: category A. category B. An entry which have different assigned categories in 2 locales. An example entry belongs on category B in English ...
0
votes
0answers
19 views

Migrate SuperTable rows to new entry

I have a single with a SuperTable field with several rows. How can each row be saved into it's own entry, of a new entry type that uses the same field? Initially I tried doing it directly in the ...
0
votes
0answers
33 views

SEO by EtherCreative on Craft 2

I've installed the plugin, but do not understand where I need to change/add the following Fieldtype Usage and Custom SEO Object code. Fieldtype Usage Replace your title tag, and any other SEO related ...
0
votes
0answers
30 views

Issue with mcrypt extention in Craft 2.8.0

I upgraded Craft version from 2.6.x to 2.8.0 to make sure it runs properly in PHP 7.2 since mcrypt is no longer available in PHP 7.2+ . But after upgrades, I am getting serious errors when I visit ...
0
votes
0answers
12 views

Stalled Task During Locale Activation

When attempting to enable a new locale on an existing Craft 2 site, the task is stalling out at the same point every time. It gets to step 3 which is Resaving entries and then the following PHP error ...
0
votes
0answers
12 views

Craft 2 resave all entries via custom background task keeps failing

I have a craft 2 set with different locales. I deleted one locale and now some of chinese entires seem to be missing the proper url paths. As soon as I open and save the english version the chinese ...
0
votes
0answers
18 views

Contact form not sending email field

Currently the contact form on our site has Name, Email, Phone and Message fields but the Email a customer enters won't send through to us. Not sure if the below controls this but any help is much ...
0
votes
0answers
11 views

Craft 2: when searching for an entry can you select an entry by a fields value?

I have an entry in the section microsites these entries all have a required field called accessCode. I have the access code in a variable. I want to load in only that entry. Is this possible without a ...
0
votes
0answers
28 views

New locale showing content from default/main site (Craft 2)

I have a Craft 2 site I've inherited that is using locales for multiple sites (each with their own domains). When I set things up initially, I got all the locales working without issue. I've been ...
0
votes
0answers
22 views

Copy Live to a Test site on same domain?

I have copied my Craft 2.6 live site directory, and created a test directory on our webserver in an effort to create a test site. Also duplicated the db and changed the configure files to point to the ...
0
votes
0answers
28 views

Undefined property: DOMElement::$tagName HTMLPurifier

I got asked to edit the content on a website but whenever I edit an article and try to save it I get the following error: Undefined property: DOMElement::$tagName (/home/user/craft/app/framework/...
0
votes
0answers
41 views

Homepage is blank

Craft CMS 2.6.3017 I'm very new to Craft, so forgive me if this is a bit basic. I've cloned an existing Craft CMS site for a customer and set the site up so that 'index.php' is omitted from URLS. ...
0
votes
0answers
17 views

Craft 2.7.4 - Creating staging, blank screen

We have a live website running with Craft CMS 2.7.4, now I want create a staging environment so I made a copy of the live website files and the DB, I changed all the links from https://www.website.com ...
0
votes
0answers
25 views

EntryModel as model attribute doesn't get populated as model

I've created this custom plugin with a CP interface for a website running latest version of Craft 2. Each record in my custom table relates to an entry using an entryId. I've set up all the records ...
0
votes
0answers
16 views

Entries are being saved even when I try to upload files with the wrong extension

My Image service function throws an exception and sends it to the Craft logger that the extension is invalid. But my entry is being saved even though the field is set to only allow images. I am ...
0
votes
0answers
29 views

Generating pending image transforms get scheduled over and over again // Craft 2.6

I triggered "Generating pending image transforms" and now it keeps popping up, no matter how often it's completed. I tried deleting it from the craft_tasks table but it'll just add a new one. How can ...
0
votes
0answers
38 views

Open Tab on Page Load

The code below works when you click on the tab, but I am trying to get it to open the first tab on page load using Craft CMS. Any suggestions. <div class="available-options-tabs"> <h2&...
0
votes
0answers
23 views

Why does $entry['slug'] and $entry->slug return different values?

I'm writing a simple plugin for 'Craft 2' and It seems that a slug of an entry is returned if you reffer it like: $entry['slug'] but calling $entry->slug returns same value as entry title. Is ...
0
votes
0answers
42 views

CP doesn't recognize update from 2.7.3 to 2.7.4

I have a site running Craft 2.7.3. My update flow is to make sure that my development branch is up to date (with no outstanding commits) and that my local db is up to date with production. I then ...