We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [craft.entries]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
2answers
43 views

Removing URL's from Existing Entries

We've created a site which now has 40 entries in a Structure. We need to retrospectively remove the URI's because there isn't an individual page for each entry, they're all on one page but search ...
1
vote
0answers
12 views

Excluding entries based on a tag across whole site

I'm trying to exclude entries that are tagged "DO NOT PROMOTE" on any page where craft.entries is used minus their actual entry page. What I've come up with so far is this: public function init() { ...
1
vote
1answer
438 views

Load new entry(s) in the same page with ajax as a popup

First time I'm going to use Ajax with Craft CMS therefore I'm still confused how it works. What I need is this, when I click on a specified link in the front, I need the CMS to load some entry/...
1
vote
2answers
39 views

ANDing criteria in craft.entries

This works: {% set entries = craft.entries({ section: 'listing', listinglatitudenumber: '>=' ~ pluginResults.latmin }) %} But I need to do ...
2
votes
1answer
147 views

Trying to build params to be able find entries related to an entry and that are related to a specific category

I want to generate a list of events that are related to a specific festival and that are related to a specific category. This goal sits alongside some others that are inspiring me to attempt this in ...
1
vote
1answer
20 views

error when trying to loop through grouped entries according to dropdown field

I was trying to follow this example from stack overflow to loop through a list of entries and output them by a custom dropdown field {% set allEntries = craft.entries.section('resource').find() %} {% ...
1
vote
1answer
106 views

How do I programmatically add assets to an assets fieldtype on a Matrix

I have a json file with a bunch of id's & associated images. The id's relate to existing entries in my Craft installation. I have a Matrix field called Content with a block type called ...
1
vote
2answers
55 views

Event onPublishDraft not firing

We are still trying to make a custom mail plugin. We have one problem left. When someone makes a draft, and later publishes it, only the onSaveEntry fires but without NewEntry. So we were trying to ...
2
votes
2answers
250 views

How do I display entries 1 by 1?

I need to display entries that contain an image, and a piece of text, on the home page of my website. When someone clicks 'next', I would like it to go to the next entry (by post date) and display ...
3
votes
1answer
2k views

How to fetch entries from multiple sections

I have five separate sections with x number of entries each. I would like to render all the entries from all the sections on a single entry template page. Is there a way to do this ? I know we can set ...
2
votes
1answer
156 views

Displaying entries with pagination on a category page where the entry's last category in the array is the current category

I want to only display entries on the category page which is the last in the array of the entries category, so that it doesn't also show on parent category page. Let say these are my categories: ...
1
vote
1answer
351 views

How to load entries with a certain category only?

I am trying to load entries from a section which have a category field with multiple values. Based on that, I want to show specific entries filtered by category. Example: I have a news section and I ...
1
vote
1answer
558 views

List both parent entry and its child entry

I am trying to display a list of entries. Specifically the parent entry and it's children's entry. I started off using this: {% nav page in craft.entries.section('forms').isChildOf.slug('applicant-...
2
votes
1answer
36 views

Is it bad practice to re-use array variable name?

I have this line {% set entries = craft.entries.section('x') etc etc %} Which I use to pull data for a header in my _layout.html template. Then later, knowing I am done with the array, inside a ...