Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Bookmarks inbookmarks:mine
inbookmarks:1234
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options user 981

Entries hold the content that you want to display on your web pages. Each entry has an Author, a Post Date, an Expiration Date (if desired), a status (enabled or disabled), and, of course, content.

8
votes
You need to build a frontend login form and then block non logged in users from seeing the entries with something along the lines of this: {% if craft.session.isLoggedIn %} {# put content here #} …
answered Aug 10 '15 by megatrond
3
votes
Something along the line of this should do that: <ul> {% for category in craft.categories.group('categoryGroupHandle') %} <li> {{ category.title }} {% for entry in craft.entri …
answered Jul 31 '15 by megatrond
3
votes
Ok, so the answer was quite simple: I was using the PHP DateTime object instead of Crafts DateTime. Removed the \ on this line: $date = new \DateTime($article['article_start'], new \DateTimeZone('Eu …
answered Mar 21 '16 by megatrond
3
votes
1answer
I'm doing an import, and saving entries into a channel with saveEntry(), but the entry's URL gets saved in the wrong format. … entry->postDate = $date; $entry->enabled = true; $entry->getContent()->title = $title; $entry->setContentFromPost(array( 'leadText' => $description, 'bodyText' => $text )); $success = craft()->entries
asked Mar 21 '16 by megatrond
1
vote
If you change your query and sort by ascending postdate, it will start with the oldest and end with the newest: {% set entriesInYear = craft.entries.section('blog').limit(null).after(year).before …
answered Apr 3 '16 by megatrond