Questions tagged [apostrophe-cms]

The official tag for ApostropheCMS. You can post code-related how-to questions about using Apostrophe, so that other community members can easily find answers to their problems. Please do not ask non-code related questions. Discussions, best practices, and ideas for development should be posted on the forum.

ApostropheCMS is an open source, highly modular content management system on top of Node.js, MongoDB and Nunjucks. It supports in-context editing, schema-driven content types, flexible widgets, and much more.

Start by reading the documentation. There are helpful getting started guides. Want to dive deeper? Understand Apostrophe deeply by consulting the technical overview.

Join the community on the forum. New release notes will be announced there.

Found a bug or want to contribute? File an issue or a pull request on GitHub. Feel free to also contribute to the official modules.

Got stuck? Now post your question. We're happy to help.

529 questions
6
votes
1 answer

How do I email out ApostropheCMS contact form submissions?

I created a contact-form module per this documentation: https://apostrophecms.org/docs/tutorials/intermediate/forms.html Submissions work and submitted forms are showing under "Contact Forms" admin menu item. I also want generate an email to a…
geochanto
  • 972
  • 2
  • 13
  • 45
3
votes
1 answer

Adding custom parameters to a widget

Lets say we created a simple widget which may have a string or a richtext field. When I insert the widget into the html, I would like to specify which field to be visible/active. In other words I'd like to add some custom options to the widget,…
3
votes
0 answers

Limit a widget on an area

I want to know if you can set a limit of a specific widget in an area. I know that with the property "limit" you can limit all the widgets of an area, however, I could not implement to limit a specific widget. Is there any way to do it?
3
votes
1 answer

Editor needs the permission to edit pages and add widgets to them

Im trying to create the role of an Editor, with permissions to edit piece-pages create pieces add widgets in piece-pages The problems i encountered were the following Editor could only edit the widgets, that have been added to the…
brhnblkr
  • 45
  • 7
3
votes
1 answer

Add more character SEO Description and Field for Page Setting

I'm running SEO for our website and our website is using Apostrophe-cms. However, SEO Description field has the limit 155 characters. SEO Description: And I want to add one more field in Page Setting such as Text field. Page Setting: Could you…
Alviss Tran
  • 41
  • 1
  • 5
3
votes
1 answer

How to pass js scripts to specific page type?

Currently I have all page scripts in site.js and passing it through apostrophe-assets like this: module.exports = { stylesheets: [...], scripts: [ { name: 'site' } ] How can I pass some server/client-side js code to a specific…
antonys
  • 45
  • 4
3
votes
1 answer

How to make Apostrophe/Node.js content pages crawlable?

Obviously Apostrophe CMS code is javascript-based, so I'm wondering to what extent Apostrophe pages are 'properly' indexable (i.e. "Ready for JavaScript Crawling & Indexing"?). The reason I ask this is because of this article, in which Moz tested a…
Steve
  • 614
  • 5
  • 16
3
votes
2 answers

apostrophe cms - customize page settings

I want to add meta-key and meta-description fields to the page setting dialog, and then render them to the page. I was able to find that one can do something like this in the page template (html) file: {% extends data.outerLayout %} {% block…
3
votes
1 answer

Apostrophe default value

module.exports = { extend: 'apostrophe-widgets', label: 'Learn More', instructions: 'Learn More Widgets', addFields: [ { name: 'learnMore', type: 'string', label: 'Name for the Link', …
Grewal
  • 55
  • 6
3
votes
2 answers

Images with Apostrophe CMS

I am trying to figure out the best way to upload and show images in articles. Right now I have the following code under the apostrophe-blog-pages show.html template
{{ apos.area(data.piece, 'main', { widgets: { …
Parik Tiwari
  • 1,525
  • 1
  • 12
  • 19
3
votes
1 answer

Injecting backend data into view for use in client-side JS

I'd like to return a list of docs to an array that will be used in some client side JS. In my apsotrophe-pages module I have this apos.docs.find call that is working and returning documents I need to fetch. Now that I have this array of docs, I need…
lance-p
  • 1,050
  • 1
  • 14
  • 28
3
votes
1 answer

Auto login users to Apostrophe

I've extended the apostrophe-express module implementing logic to check cookies in the request headers. One of the cases in this check is to auto login users. If a cookie key/val matches a preset flag value, then I would like to do a lookup for the…
lance-p
  • 1,050
  • 1
  • 14
  • 28
3
votes
1 answer

Check headers on each page request

I need to check the request headers on each page request. I thought the place to try this would be in the 'apostrophe-express' module. I've created my own module 'auth' that extends 'apostrophe-express': module.exports = { extend:…
lance-p
  • 1,050
  • 1
  • 14
  • 28
2
votes
1 answer

Not able to reach the apostrophe-cms server

So I have installed the Apostrophe-CMS per http://aclouda.com/blog/services/how-to-install-apostrophe-content-management-system-on-ubuntu/ on my Oracle Cloud Infrastructure Ubuntu compute instance and I configured my security list to allow port…
Rich Wi
  • 21
  • 3
2
votes
1 answer

How to get current year in a Nunjucks template within Apostrophe CMS

I am in the process of adding a copyright line to the footer of a website that I have been working on and I cannot find the best way to get the current dynamically into the footer so I never have to set it again. I have tried multiple things,…
Doug Niccum
  • 196
  • 4
  • 16
1
2 3
35 36