Planet Plone - Where Developers And Integrators Write

Lightning talks Friday

Posted by Maurits van Rees on November 29, 2024 10:25 PM

Bonnie Tyler Sprint

On 12 August 2026 there is a total solar eclipse that can be seen from Valencia, Spain. So we organise a sprint there.

This conference

We had 291 participants, 234 in person and 57 online. 13 Brazilian states (that is all of them), 14 countries.

24.5 percent women, was 13% in 2013, so that has gone up, but we are not there yet. Thank you to PyLadies and Django Girls for making this happen.

We had more than 80 presenters, about 30 lightning talks, lots of talk in the hall ways.

Thanks also to the team!

Ramiro Luz: Yoga time

Yoga exercise.

Rikupekka: University case student portal

We have a student portal at the university. But mostly:

Welcome to Jyväskylä university in Finald for Plone conference 2025, October 13-19!

Jakob: Beethovensprint

26-30 mei 2025 in Bonn, Duitsland.

Afterwards, on May 30 and June 1 there will be FedCon in Bonn, a SciFi convention.

Piero/Victor: BYOUI

Add-ons first development with @plone/registry. See https://plone-registry.readthedocs.io/

It allows for development that is framework agnostic, so it is not only for Plone. It is around configuration that can be extended and injected, which is tricky in most javascript frameworks.

Imagine it.

Ana Dulce: 3D printing

For a difficult model I had trust the process, it took a week, but it worked.

Renan & Iza: Python Brasil

We organised the Python Brasil conference from 16 to 23 October this year in Rio de Janeiro.

Next year 21-27 October in São Paulo.

Erico: Python Cerrado

31 July to 2 August 2025 is the next Python Cerrado conference.

Paul Roeland: The value of longevity

Posted by Maurits van Rees on November 29, 2024 08:58 PM

Link to talk information on Plone conference website.

I work for the Clean Clothes Campaign: https://cleanclothes.org/

After three large disasters in factories in 2012 and 2013 with over 1000 deaths, it took three years to get an agreement with clothes manufacturers to get 30 million dollar compensation. It does not bring lives back, but it helps the survivors.

See Open Supply Hub for open data that we collected, for checking which brands are produced in which factories.

Documenting history matters. Stories must be told.

The global closing industry is worth around 1.8 trillion dollars, in a country that would put them on the 12th place in the world. 75 million workers.

Our strongest weapon: backlinks. We have links from OECD, UN, wikipedia, school curriculum, books. Especially those last two don't change ever, so you should never change urls.

Plone: enable the sitemap, please, why not by default? Create a good robots.txt. I weekly check Google Search console, looking for broken links. Tag early, tag often, great tool, even if you have an AI do it.

Our website: started 1998 written in Notepad, 2004 Dreamweaver, 2006 Bluefish, 2010 Joomla, 2013 Plone 4, 2020 Castle CMS (opinionated distribution of Plone, but does not really exist anymore) 2024 Plone 6 with Volto Light Theme (work in progress). Thank you kitconcept for all the help, especially Jonas.

Migrations are painful. Along the years we used wget to csv to SQL to csv, Python script, "Franken-mogrifier", collective.exportimport.

Lessons learned: stable urls are awesome, migrations are painful. Please don't try to salvage CSS from your old site, just start fresh in your new system. Do not try to migrate composite pages or listings.

What if your website does not provide an export? Use wget, still works and is better than httrack. sed/awk/regex are your friend. archivebox (WARC).

Document your steps for your own sanity.

To manage json, jq or jello can be used. sq is a Swiss knife for json/sql/csv. emuto is a hybrid between jq and GraphQL.

Normalize import/export. We have `plone.exportimport` in core now.

In the future I would like a plone exporter script that accepts a regex and exports only matching pages. Switch backends: ZODB, relstorage, nick, quantum-db. Sitewide search/replace/sed. Sneakernet is useful in difficult countries where you cannot send data over the internet: so export to a usb stick.

A backup is only a backup if it regularly gets restored so you know that it works.

  • Keeping content and URL stability is a superpower.
  • Assuming that export/import/backup/restore/migration are rare occurrences, is wrong.
  • Quick export/import is very useful.

Do small migrations, treat it as maintenance. Don't be too far behind. Large migrations one every five years will be costly. Do a small migration every year. Do your part. Clients should also do their part, by budgeting this yearly. That is how budgeting works. Use every iteration to review custom code.

Make your sites live long and prosper.

Fred van Dijk: Run Plone in containers on your own cluster with coolify.io

Posted by Maurits van Rees on November 29, 2024 07:58 PM

Link to talk information on Plone conference website.

Sorry, I ran out of time trying to set up https://coolify.io

So let's talk about another problem. Running applications (stacks) in containers is the future. Well: abstraction and isolation is the future, and containers is the current phase.

I am on the Plone A/I team, with Paul, Kim, Erico. All senior sysadmins, so we kept things running. In 2022 we worked on containerisation. Kubernetes was the kool kid then, but Docker Swarm was easier. Checkout Erico's training with new cookieplone templates.

Doing devops well is hard. You have a high workload, but still need to keep learning new stuff to keep up with what is changing.

I want to plug Coolify, which is a full open source product. "Self-hosting with super powers." The main developer, Andras Bacsal, believes in open source and 'hates' pay by usage cloud providers with a vengeance.

Coolify is still docker swarm. We also want Kubernetes support. But we still need sysadmins. Someone will still need to install coolify, and keep it updated.

I would like to run an online DevOps course somewhere January-March 2025. 4-6 meetings of 2 hours, maybe Friday afternoon. Talk through devops and sysadmin concepts, show docker swarm, try coolify, etc.

Ziming Yuan: How a Beginner Built an RSS Feed Provider in Volto

Posted by Maurits van Rees on November 29, 2024 06:52 PM

Link to talk information on Plone conference website.

I am studying computer science. This summer I have participated in the Google Summer of Code for Plone. Thank you to mentors Paul, Roeland and Mike!

I have built several full-stack web apps with React, but am new to open source.

What is RSS? It is Really Simple Syndication. It is used by websites to publish updated information, such as blog or news. It lets users decide what they read every day, instead of algorithms.

In Plone the RSS feed should use a catalog query to filter contents, for example a feed of science articles or of events.

For an RSS feed content type we could use a collection behavior or a blocks behavior with a listing block. The listing block is the way to go for Volto. So I did that. Plus extra fields like maximum title length and maximum description length.

I created a view component for the content type. Important is the Express middleware with which we got information from the backend.

We decided on `rss` as Node package for the feed. We looked at another newer one called `feed`, but it did not work for us or was missing features.

There were challenges for me as person new to Plone. Do I really understand the code? Often the answer is: no. For example ZCML? i18n? XML files in the profiles? There is a really nested structure. Create a new project, then you have backend / src / rss / src / rss, at least something very deeply nested. It was always confusing to me as I did not really know what should end up in git or in a release. The worst is that I don't know what are the most important files.

And what if my code fails, it was hard to understand errors on the front end. There are just too many things that may be the source of the error.

Another challenge: what if I want to create something new? The training lets you learn by example. But what does each line of the example code actually do? Are there other options?

Missing documentation: how do prevent the user from removing the title or rss block? We found out about initialBlocks per content type. And prevent adding new blocks? There is a feature disableNewBlocks, that could be set on an individual block, but what about doing this for all instances of this content type?

An overview of the code base would be good. How different components are connected, how different files work together. A guide about how to approach the source code, what files I should look at first.

For developers new to Plone: the source code is your friend, the Plone community is helpful, but be specific in the questions you ask, and tell what you have already tried.

Source code:

Érico Andrei: Plone + pytest: Tips and tricks

Posted by Maurits van Rees on November 29, 2024 06:52 PM

Link to talk information on Plone conference website.

Plone loves tests. The first was committed in October 2002 by Sidnei da Silva. We have used lots of different testing framework. I like using pytest. The unittest framework was inspired by Java testing and you see it. pytest is simple and pythonic. It does dependency injection, which can look magical, okay. There is a large ecosystem of plugins. It has support for unittest. There is a Brazilian maintainer.

I have created pytest-plone, built upon zope.pytest. It provides fixtures and helpers. it is the default in cookieplone templates. Take a look at plone.distribution and plone.exportimport for examples.

Golden rules

If you need a Plone site in your test, you need to wrap your test in a class. That helps for not tearing down everything after every test. Start with a method that gets portal and probably get_fti, and use @pytest.fixture(autouse=True).

Use @parametrize to run the same test function with multiple inputs and output.

Use fixtures.

Trust and love pytest plugins. There are plugins for running the tests in random order, or in parallel. Code coverage is a plugin. You can start a docker container.

Use helpers in pytest-plone to check that your latest upgrade step matches the metadata profile version. Check that your add-on is installed.

plone-pytest 1.0 is coming. Small problem: the tests are breaking on Python 3.9.

Write more tests with less code.  I will sprint on pytest-plone.

Fabiano Weimar: Plone on Kubernetes

Posted by Maurits van Rees on November 29, 2024 02:39 PM

Link to talk information on Plone conference website.

Kubernetes (k8s) is an open source system for managing containerised applications It provides mechanisms for deployment and scaling. It is part of the Cloud Native Computing Foundation.

Kubernetes' benefits are scalability, fault tolerant, self-healing, efficient resource utilisation, declarative configuration, rich ecosystem.

Kubernetes basics:

  • pods: the smallest deployable unit of computing, consisting of one or more containers. Containers in one pod can talk with each other like they are all on localhost.
  • deployments: manage the replication and updates of pods
  • RepicaSets: manage a fixed number of identical pods.
  • StatefulSets: manage stateful apps, lik databases
  • Jobs: one-off tasks
  • CronJob: regular tasks
  • ConfigMap: store configuration data
  • Secrets: store sensitive information 
  • PersistentVolumeClaims: request storage
  • PersistentVolumes: actual storage
  • Pod Disruption Budgets (pdb): limit the number of pods that can be unavailable at any given time, for example during upgrades, self-healing during disaster recovery.
  • Autoscaler: automatically scale the number of nodes in a cluster based on workload. Resource optimisation.
  • Ingress: routing external traffic to services, SSL termination, load balancing, caching, rate limiting.
  • Operator: software extensions to Kubernetes that make use of custom resources to manage applications and their components. Think of this as a human operator who would go in and do some stuff.

Plone components as Kubernetes resources:

  • Plone backend: StatefulSet
  • Plone frontend: Depoloyment
  • PostgreSQL: StatefulSet
  • Varnish: Deployment
  • nginx
  • cronjobs

Kubernetes for Devops.  It has a steep learning curve. For your laptop you have microk8s and k3d so you have the Kubernetes api, although without the options that you would have with multiple machines. Basics: `apt install docker.io` and `snap install kubectl --classic` and `snap install heml --classic`. And read https://k3d.io/ 

At the Alpine City Sprint this year we worked on helm charts for Plone: https://github.com/plone/helm-charts/

Tips and tricks:

  • You can use ArgoCD to automatically do a deploy when something changes in a git repo. You need to configure this correctly of course.
  • Plone can do better on integration with proper observability tools like Grafana and Prometheus. For example, how can such tools get the logs when they are in multiple places.
  • Use ZODB with PostgreSQL and relstorage. I think it is the most stable implementation today.
  • Varnish Operator from IBM looks promising when you want to run multiple instances of varnish.
  • If you run the `test.sh` from Plone help charts this may use a lot of bandwidth downloading docker images. k3d supports import of docker images so they are in a cache.

Rikupekka Oksanen: Building a secure video portal for researchers

Posted by Maurits van Rees on November 29, 2024 01:54 PM

Link to talk information on Plone conference website.

We needed a video platform for our university. Difficult, but we had a dev team of 8 with some architecture experience, so let's try. We did a successful POC in 2023.

We use: Plone 6, VideoJS player, Wowza streaming engine, Keycloak, WhisperX, Camunda 7, Nomad. Most important: open source and license free.

Security. We have it in a dedicated and separate server environment. All data is stored on own servers of the university. All data and files are encrypted. Plone is very secure. All transactions are logged. There is a process for data protection, and it has been reviewed and documented.

There was no definite deadline, which is both good and bad. We could focus on quality, but also needed to focus on other projects.

Now a nice working demo.

[Sorry, I was distracted by client work.]

Help Oshane get to the Tokyo Plone Conference

Posted by David "Pigeonflight" Bain on October 24, 2018 03:38 AM

Summary

Oshane Bailey, a talented Plone developer with loads of Plone experience has been selected as a presenter for the 2018 Tokyo Plone Conference. His Japanese visa was just approved.
He will share a streamlined approach to Plone development that he is applying on a Plone project targeted at Jamaican Developers. At the time of writing he has raised about 17% of the funds he needs to get to Tokyo. You can help him get to Japan by contributing to his crowd-funding campaign.

Oct 29, 2018 update
Thanks to generous contributions, Oshane's trip is now 70% funded. You are welcome to join the crowdfund and cover the rest of his trip.

Oct 30, 2018 update

Oshane's trip is now 89% funded. The plane ticket and conference ticket have been purchased. you can still pitch in by joining the crowdfund to cover the rest of his trip.

Since at least 2015, Oshane has worked on Plone projects for teams around the world and in the process has been exposed to varied approaches to the development and ongoing management of Plone sites. Over recent months he has poured his, hard earned, experience, into a side project -- the Jamaican Developers site.  Through this project he has refined a continuous development pipeline based on some of the best techniques used in the Plone community and enhanced with some of his own innovations.

Last year Oshane participated as a Plone Google Summer of Code student and presented his work at the Barcelona conference. He also participated in the after-conference sprints, contributing to efforts to port Plone to Python 3 and also looking into the WebSauna project.

Supporting his trip to Tokyo will serve to enrich PloneConf 2018 in many ways. Here are three that spring immediately to mind:
1) As part of his talk he will share the techniques he is using on the Jamaican Developers site
2) He plans to participate in the after conference sprints.
3) He will bring an important perspective to discussions influenced by constraints common to Jamaican developers.

How to Support Oshane

Appropriately, his crowdfunding campaign is running on the Jamaican Developers site that he built with Plone. His goal is to raise enough to cover his travel and expenses related to the Japan trip.

As we say in Jamaica... "Follow back a me" as I support Oshane's trip to PloneConf2018 in Tokyo.

Plone Conf 2017 Day 2: Timo Stollenwerk: Building Bridges - The Headless Future of Plone

Posted by David "Pigeonflight" Bain on October 19, 2017 08:48 AM
I decided to try a Maurits van Rees and live blog a conference talk.
Talk by Timo Stollenwerk on Building Bridges - The Headless Future of Plone



Plone's headless future

Working on what we call headless these days started in 2014
You already heard a part of this from the Keynote (about Pastanaga UI etc..) on the first day so I won't repeat that.
My ultimate goal is to bring the vision to reality.

A few observations


  • Mobile is overtaking Desktop (Plone is mobile ready but Pastanaga aims to have the best experience on every device)
  • Open Source is Mainstream (Plone is different, today large open source projects are coming from large players like Facebook and Google, this helps to make open source more mainstream). Github looked at contributions last year and visual studio code was the project that had the most contributions... Microsoft!!)
  • Javascript is taking over (Javascript is becoming more important, if you are a web developer in 2017 you have to learn modern Javascript)
  • The Web is everywhere (I visited my Uncle who is a Doctor, 5 years ago and noted that he was using a web app on his desktop for viewing scans of the body)

In recent studies they discovered that swift is losing popularity because web technologies are taking over. The web is coming back with technologies like Electron (Desktop) and Cordova (mobile)



Isn't it a great time to be a Web, Javascript, Open Source developer in 2017?

We're hearing that the CMS market is dead

If we see it in other sectors we say it is more efficient but when it happens to us we don't want to transform ourselves for the better. I think we are living in exciting times...

If JS is so great why don't we just go with it and build a CMS with Javascript?

Why do we keep using Python and Plone?

  • I love Python (wasn't my first language, but the first one I loved, I still miss Python with every line of Javascript I write). I can live with Javascript for the tooling and the community but would prefer to keep Python. I can't imagine using Node on the backend because I think Python is doing a way better job on the backend.
  • Plone the community. In the last year I've been to Jenkins, CI and testing conferences but there's no place like Plone. 
I went to a JS conference alone. Usually when you go to a conference alone you need to make an effort to talk to persons. Then I went to the sprint but out of 1000 persons there were only 20 or 30 persons at the Sprint. When I speak to Python conference attendees they ask me, how do you get people to come and even pay for a flight to Plone conferences, it's like magic!


  • Plone the Software is still unique (permissions, traversal, workflows)
  • Plone the CMS (as Eric says, Plone is doing Breadcrumbs since 2001) Go out and try all the Javascript CMSes, they all have awful user interfaces, they have nice libraries and everything you can imagine but lack the basic functionality of a CMS. I couldn't just jump and move to another system because I'd only have half or 10% of the current functionailty I have now.  We don't want to become Grandpas and isolate the new JS communities who have lots of energy


What do we have now?

Stabilising JS frameworks, it's not too hard to switch between VueJS, React, Angular. Which one you use depends on if you like a library vs a framework. How do we handle this? We want to give our clients something that can be supported over the next 5 to 10 years. That's a lot of time. If you look at Plone we are able to provide that. How do you handle that? The answer is plone.restapi (restful hypermedia for Plone).

Our idea with plone.restapi is to use it as a bridge. Stability on the backend with flexibility on the frontend. In two or three years the JS ecosystem will change further.

Status of plone.restapi

It is stable and used for 3 years, it is used in production by several companies. We consider plonerest.api to be feature complete.
I asked Eric what is plonerest.api missing, he said "nothing".

I'm just lazy about releasing a 1.0 release.

We can get back to our vision with plone.restapi being stable.

So we can get back to our vision of bridging...? One of our ideas about building with Plone 5

You can use React in the core today, if you want to go with a full framework like Angular you can too. We have 3 branches and the plonerest.api allows us to build bridges between
standard plone and the other branches.

How do we make this happen?

Regarding stories... Victor sometime says to me "Should we really say that, going on stage and telling people about these things? They will expect it to happen."

So who here would like to have Pastanaga UI today and use it. With projects in the Plone community we've building like that...



when we should be building like this..




I believe that if we want to have that we need to start with the Minimal viable product. Something, not just for users but for companies that can give them value right away. I want that skateboard.

What do we need to get that skateboard?

  • Login
  • Content Editing
  • Image upload

That might sound easy but it is not. We're aiming for making Plone stand out, we want people to be like "wow, that's the greatest editing experience I've ever had". I want us to iterate over that and focus on that user story.
I want to make image upload really easy. One thing we need to solve on a technical level, we currently have created a Medium-like editor but we don't have image scaling (something we take for granted in Plone). I want us to have the ability to add the image and have scaling done "magically".

There are things that are essential for an MVP


  • Performance
  • Image uploading
  • SEO


If we don't have this, users will abandon pages. Modern page builders focus on this (e.g. gatsby js is a modern page builder built in ReactJS). If you want to compete we have to provide users with a great out of the box performance. We'll need to use all the tooling, webpack etc...
We will also need server-side rendering. We saw that, without server-side rendering at kitconcept we can't do good SEO.

Visit https://github.com/plone/pastanaga#minimal-viable-product for details on our projections of a MVP.

Next

We have an open space at the conference and there will be sprints.
Real world projects (if you have any projects and want to use plone.restapi, angular sdk, plone.react, please talk to us)
At kticoncept we have a few projects where will do that
Sponsorship (we may be able to do something on that front)

Summary

We have a stable platform in plone.restapi for building bridges
I think Plone's future is bright is we combine our knowledge and experience with the new things
Pastanaga UI is really greate
I hope we can provide you with a roadmap
The great thing about the Plone community is tha tyou start with an idea and...
let's get together and do Plone magic together!

Help two Plonistas get from Jamaica to Barcelona (Catalonia) for the 2017 Plone Conference

Posted by David "Pigeonflight" Bain on September 07, 2017 01:23 AM

Jamaica to Catalonia for Plone Conference 2017

TL;DR - David Bain and Oshane Bailey are looking to attend the 2017 Plone Conference via crowd funding.

  • Sept 20, 2017 Update: We will mostly be walking so this reduces our transportation costs, we've adjusted our target to reflect this. We've extended the campaign until September 27.
  • Sept 17, 2017 Update: We're finding some cheaper fares, adjusting our target to reflect this
  • Sept 16, 2017 Update: Oshane has been offered a free room, this will lower the overall target further
  • Update: It looks like there are more cost effective accommodation options, as a result, we've further adjusted our estimates.
  • Update: We have found some cheaper flights via Google Flights so we're adjusting our estimates down by $2,000. 



  (David's the one on the right).

This is a manually managed crowdfunding tracker updated by David (no AI was harmed in the creation of this tracker)


We are trying to get from Jamaica to Catalonia for the 2017 Plone conference.  Our target is to raise a significant part of the roughly USD$7,000 USD$5000 USD$4,400 USD$3,700 USD$2,900 needed to cover airfare, accommodation etc.

How to support us

You can contribute to our travels via Paypal (see the button below), funds go to my Paypal account.

Why support us?

Support us so that we can deliver training, talks and participate in the sprints*.

Getting us there will allow David to deliver training and a talk or two, Oshane will be able to share his Google Summer of Code experiences and participate in his first face to face community sprint after the conference. Oshane worked this summer on improving the theme editor experience, here are some links with more information about what he did...
https://community.plone.org/t/gsoc-2017-improving-the-theme-editor-experience/3906
https://community.plone.org/t/thank-you-for-the-support-during-gsoc-2017/4792
We're hoping he'll be able to present his experience as a talk at the conference.

David has been an active part of the community for many years. He delivered training and two talks at the last conference and has been invited to be part of the training team at the 2017 conference as well.

Both of us are really excited to participate this year, however the cost of airfare is prohibitive.

* While Oshane will stay for the sprints, due to family commitments, David won't be able to stay for the sprints.

 Rough Breakdown of expenses

Why you had problems figuring out Plone (the webinar)

Posted by David "Pigeonflight" Bain on August 03, 2017 10:32 PM


Presenting... Why you had problems figuring out Plone (the webinar). Okay, that's not the actual name of the webinar. Instead, we went with the more descriptive but slightly less clever Plone for Newbies - The Big Picture.

The Big Picture is about understanding the model.

If you're a developer about to begin your journey of Plone development, The Big Picture aims to fill out your understanding of how the pieces of Plone fit together. Thinking of it as a purpose built system lays a strong foundation for success.

Only smart persons use Plone

I've heard someone suggest that you have to be really smart to use Plone (implying that it is hard to use). I call it the "this helicopter is harder to use than my bicycle" problem. Every time I benefit from Plone's link integrity support, flexible access control model or use cut and paste to move content around I'm glad I'm not using a "bicycle". I like to point out Plone's comprehensive suite of tools which you'll be glad exist when you need them. For developers, once you accept that you're looking at a "helicopter" you need to spend a little time "understanding the model". As you understand the purpose of the major controls you'll find it easier to use the system to solve problems.

Why Plone? 

Now is the right time, with an increase of cybersecurity related issues, organizations should be looking to adopt secure platforms. I've been using Plone for more than 15 years, and I can confidently recommend it as a secure platform. In case you took your eye of Plone for a few years, now is a great time to give it a second look, it has kept up with modern development practices and remains an excellent choice for your content management needs.

Why a webinar? 

My target audience isn't in one geographic location, the most effective way to reach them is a virtual medium and webinars provide a well-known, tried and tested approach.
Additionally, I have run one or two webinars before, if you count online training courses. Of course, it is different when you are doing more than just showing up, reaching out to a "less captive" audience and convincing them to commit 90 minutes to a webinar. So this is new ground for me. I am learning a lot from this experience and have had a fleeting thought, maybe I'll take all this webinar and Plone stuff and do the "meta" thing, build a webinar management tool on top of Plone. You never know.




Plone 5 custom views using Rapido 1.1.1

Posted by David "Pigeonflight" Bain on June 29, 2017 02:09 AM
After you've created a custom content type through the web (TTW), you'll want a custom view to go with it. In this simple example we create a custom youtube page content type and a supporting view all TTW.

Step 1 - Create a new content type

Start by creating the content type through the Dexterity Types control panel.

Site Setup > Dexterity Types

Select and clone the "Page".

.. ..
Then add a "youtube_url" field.

After adding your first "Youtube page" you'll notice that the default view isn't showing us the "youtube_url" field that we added. We'll fix that in the next step.

Step 2 - Create a custom rapido view

To create a custom view (sometimes called an "extra view"), start by creating a rapido app, we'll call ours views and to this we'll add a youtube-page block.
See the structure in the gist below:
.. ..
The video below explores the building blocks of our custom view. After some tinkering we settle on the id youtube-page-view for our view.
.. ..

Gotchas with registering view ids

What was not recorded in the video was the fact that the view id youtube-page had been used in the context of a different rapdio block (I was practicing before the real recording). If you were paying careful attention to the demo video you may have noticed some unusual behaviour when trying to use the view named youtube-page. When you define a view id and then change it later on, the id expects to work with the originally registered block. I've found that restarting the instance resolves this issue.

Plone theming: Injecting a class into an existing tag with Diazo and xsl

Posted by David "Pigeonflight" Bain on June 14, 2017 11:28 PM
In a recent post (https://community.plone.org/t/textareas-not-displaying-existing-content-when-my-theme-is-enabled/4117/2?u=pigeonflight) I mentioned a Diazo rule where I was injecting a new class into a tag, I used an <xsl:template>.

The following example adds a special class "gl-textarea" to all <textarea> elements it uses a Diazo <replace> directive instead of an <xsl:template>.
... ....

If you've done enough xslt then you probably know that this could have been achieved with an <xsl:template> element, the problem is that <xsl:template> elements won't work in all scenarios when using Diazo. 

A note about Diazo, <xsl:template> and nested scenarios

<xsl:template> elements in nested rules will fail silently. This also means that externally included files will also fail because rules in externally included files are implicitly nested.
So something like this, if located in the main rules.xml file, should work:
<rules>
    <xsl:template>
    ...
    </xsl:template>
</rules>

This will fail, because it is in a nested <rules> element.
<rules>
    <rules>
          <xsl:template>
          ...
         </xsl:template>
     </rules>
</rules>

On the other hand, Diazo's <replace> directive can be used as a work-alike to the <xsl:template> element and it works in nested scenarios.

Don't do this

Here's the <xsl:template> approach which works in very specific scenarios.
 ... ...

When you can do this

For comparison, here again, is an example that uses the <replace> directive and should work in most scenarios.
... ....
Don't forget to include the apply-template, it is needed.

Reading other people's code - first hour towards building custom tiles for plone.app.mosaic

Posted by David "Pigeonflight" Bain on June 07, 2017 12:03 PM
TL;DR looking at other people's code - my first steps in getting started with creating custom tiles for Mosaic involved looking at how other people did it.

Mosaic is a layout solution for Plone which allows end users to create custom page layouts within a Plone website (video) using a simple drag and drop.  There are ready made tiles for common situations, however I am starting to come across situations where the default tiles aren't what I want.

I decided it was time to explore the creation of custom tiles. I figured the best way to get going would be to look at how others have created custom tiles. I knew that custom tiles were used in the creation of the Plone 2016 conference website and that the source code for the site was published on github. I started by inspecting their code.

I setup Plone 5.0.7 with Mosaic 2.0rc5 and also the ploneconf2016 site profile (https://github.com/plone/ploneconf2016.policy). The code for the tile configuration is here: https://github.com/plone/ploneconf2016.policy/tree/master/ploneconf2016/policy/tiles

Once everything was installed I was able to create a fake conference website and add presentations, persons (speakers/presenters) and a few other content types.

The policy defines two custom tiles

  • A slider tile 
  • A presentation tile

I was able to use both custom tiles without issue, the slider custom tile doesn't work out the box, meaning I could define the slides but the actual sliding didn't work. The slider depends on other components that are provided by the ploneconf2016 theme. It shouldn't be too hard to add the right CSS and JS to my own theme to get the slider working the way I want.

One note, when I cheated by not including a speaker on my presentation item, things "broke". To be fair this is to be expected since the presentation content type does have a red dot indicating that speakers are required items on presentations.

I got this error on the console

```
...
  Module zope.component._api, line 120, in queryMultiAdapter
  Module zope.interface.registry, line 245, in queryMultiAdapter
  Module zope.interface.adapter, line 541, in queryMultiAdapter
  Module plone.jsonserializer.deserializer.converters, line 69, in from_unicode_converter
  Module zope.schema._field, line 322, in fromUnicode
  Module zope.schema._bootstrapfields, line 183, in validate
  Module zope.schema._field, line 338, in _validate
ConstraintNotSatisfied: (u'350d0a34ffcb4fc4943efdcf4bdb9f03', 'content_uid')
```

A quick guess... the content_uid was probably referring to the missing speaker.

I consider this a great first experiment. I have all the pieces working and I know how the code was put together. My next steps are 1) customize one of the conference tiles 2) create and register a brand new tile of my own.

Small Plone team ready for interesting problems

Posted by David "Pigeonflight" Bain on November 30, 2016 09:17 PM



Starting December 1, 2016 the Alteroo team will be available for new Plone gigs.

Our team members are ready to dive into modern Plone development including Diazo and Mosaic on Plone 5. We also have experience with older versions of Plone.

If you're into checking boxes we also have experience with Javascript/ReactJS/Webpack/Babel, Pyramid/Kotti, Firebase, QA, Linux server administration and General Design skills.

Send an email to newgigs - [ at ]- alteroo.com.

Installing Plone 5 on Windows: Part 2 - Installing Plone

Posted by David "Pigeonflight" Bain on November 17, 2016 06:10 PM
This is part 2 of installing Plone 5 on Windows. The following instructions are specific to installing Plone 5 on Windows. Part 1 covered preparing your Windows machine for Plone.

Assumptions




You now have all the tools needed to build a full Plone environment. Plone uses a tool called "buildout" for managing builds, this makes it possible to distribute build configurations using git or other revision management tools. The folder where your build configuration exists is also referred to as a buildout. We will checkout an existing buildout called "themedev.buildout". The intention of the "themedev.buildout" is to provide all the tools needed for Plone theme development.

In the steps below you will clone the buildout then run an initializaton script called "setup.bat"

Step 1 - Install Virtualenv

Launch git bash and run the following to install virtualenv.

pip install virtualenv

Step 2 - Clone the buildout, run the setup script and bin/buildout


git clone https://github.com/collective/themedev.buildout
cd themedev.buildout
./setup.bat
bin/buildout

Day to Day Usage

To launch the instance run the following:

bin/instance fg




Installing Plone 5 on Windows: Part 1 - Preparing the machine

Posted by David "Pigeonflight" Bain on November 10, 2016 03:23 AM
Windows does not ship with all the tools needed to install Plone for development. These are the steps needed to prepare your Windows machine for Plone 5.

Assumptions

I assume that you're using a Windows machine on which you have enough permissions to run commands as an administrator. That's it!

What you will need to install

I recommend that you install the following to run Plone:
  • Git for Windows
  • Python 2.7
  • Visual C++ for Python 2.7
  • Pywin32
  • NodeJS
If you don't have a preferred text editor gedit is a simple editor for beginners.

The Steps

Step 1 - Download and install Git for Windows

IMPORTANT, Install Git for Windows First, it adds some context tools to Windows which you will use later.
Download and install git for windows from https://git-for-windows.github.io.

Step 2 - Download and install Python 2.7 from https://www.python.org/downloads/windows/

The latest version at the time of writing was Python 2.7.12. Basically it's a matter of clicking "next, next, next" EXCEPT on the "Customize" dialog. Look for "Add python.exe to Path" and make sure it is enabled (it is disabled by default).






Apart from one adjustment it is basically "next, next, next" to install



























.                                                                                                                                                             .

Step 3 - Download and install Visual C++ for Python 2.7 

Download from https://www.microsoft.com/en-us/download/details.aspx?id=44266

Make sure it is downloaded to your "Downloads" folder.

Right click on your Downloads folder and from the context menu select Git Bash Here.

save image

In the resulting console type the following and hit the enter key:

msiexec /i VCForPython27.msi ALLUSERS=1

This launches the Windows installer with administrator privileges. Click "Ok" to proceed.

save image


Step 4 - Install Pywin32

Make sure you download the latest build (220 at the time of writting) and the one for Python 2.7.
save image

Step 5 - Install NodeJS


Download NodeJS from https://nodejs.org/en/download/ and make sure to select the recommended version LTS.

save image

Step 6 - Install Gedit (optional)

You can skip this step if you already have a text editor, otherwise download and install gedit https://wiki.gnome.org/Apps/Gedit#Download

Why this approach?

  • Visual C++ for Python 2.7 results in faster modules which means that Plone will run faster than if you had used an equivalent compiler like GCC+.
  • It is more common in the Windows world to point and click rather than run commands on the command line, I tried my best to minimize interactions with the command line. The approach should feel more natural for Windows users, especially more casual users.


Letsencrypt, Apache2, Plone and SSL

Posted by David "Pigeonflight" Bain on November 02, 2016 01:26 PM
These are notes for my future self. I'm mostly using nginx now, but I have an Apache server here and there. I also have a post on configuring letsencrypt SSL with nginx.

Update ( Nov 9, 2016): added more information on preparing the /var/www/letsencrypt directory and rearranged assumptions into a numbered list.

Assumptions

My assumptions are as follows:

  1. This is a Plone site which uses a proxypass style rewriterule.
  2.  The site is located at the root of your Zope application server and it is called "Plone" so localhost:8080/Plone
  3. You're using letsencrypt with certbot to generate SSL certificates.
  4.  Your .well-known folder (used by letsencrypt) will be located at /var/www/letsencrypt.
Before you start create the /var/www/letsencrypt directory


The following command works on Debian/Ubuntu type servers:

sudo mkdir -p /var/www/letsencrypt
chown www-data:www-data  /var/www/letsencrypt
If you're on RedHat or CentOs you'll want to change the owner (chown) to 'apache' or 'nobody'.

The implementation

With these things in place I found that I needed to precede my standard Plone rewrite rules with a rewrite rule to serve the contents of the letsencrypt .well-known folder. In the examples below my site is running on port 8080, this may be different for you.

Add this so that you an successfully request an SSL certificate via letsencrypt over http.

RewriteRule ^/\.well-known/(.*) /var/www/letsencrypt/.well-known/$1 [L]
RewriteRule ^/(.*) \       http://localhost:8080/VirtualHostBase/http/{HTTP_HOST}:80/Plone/VirtualHostRoot/$1 [L,P]

Add this AFTER you have a working SSL certificate installed and you're already serving stuff over https (see below)
RewriteRule ^/\.well-known/(.*) /var/www/letsencrypt/.well-known/$1 [L]
RewriteRule ^/(.*) \       http://localhost:8080/VirtualHostBase/https/{HTTP_HOST}:443/Plone/VirtualHostRoot/$1 [L,P]


Installing a certificate

Assuming you've done everything above, you can install a certificate from letsencrypt with the following instructions:

Step 1 - Install Certbot


The part of the documentation that I read was silent about where to put the certbot-auto script. I decided to install certbot-auto in /usr/local/sbin, this means that it is in the system path and can be run as a command by itself (which feels nicer than needing to be in the folder when running the script).
cd /usr/local/sbin/
sudo wget https://dl.eff.org/certbot-auto
sudo chmod a+x certbot-auto

Step 2 - Request a certificate against the /var/www/letsencrypt 

Now you can easily request a certificate.

Note the use of --webroot in the command below, this ensures that the challenge information is added to the /var/www/letsencrypt folder. Also, I precede the command with sudo because installation of the actual certificates requires admin privileges.
sudo certbot-auto certonly --webroot -w /var/www/letsencrypt -d myproject.example.com
Expected response
If everything was done properly you'll get a message like this:

IMPORTANT NOTES:
 - Congratulations! Your certificate and chain have been saved at
   /etc/letsencrypt/live/myproject.example.com/fullchain.pem.
   Your cert will expire on 2016-11-25. To obtain a new or tweaked
   version of this certificate in the future, simply run certbot-auto
   again. To non-interactively renew *all* of your certificates, run
   "certbot-auto renew"

Step 3 - Configuring Auto-renewal of certificates

Once setup properly the auto renewal steps that I took were near identical to the documentation.
I first tested to see that an auto renewal would work without issue:

certbot-auto renew --dry-run

Once the dry run was succesfull I added a renewal command as a cronjob using the crontab -e command:

PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
@monthly certbot-auto renew --quiet --no-self-upgrade

Additional notes

I've read places that say that mod_alias always get's precedence over mod_rewrite, so I tried to achieve this using mod_alias initially. That didn't work for me so I settled on this approach.

Characteristics of a sustainable buildout

Posted by David "Pigeonflight" Bain on October 24, 2016 01:12 PM
July 27, 2017 - Updated the section called "Additional Background" to include reference to the Plone Intranet project. Also swapped out the blockquoted code snippet for a github gist instead.

Buildout is a software build system used to manage development and deployment setups, especially in Python. When done well, Buildout makes everything very repeatable. Widely used in Plone projects but not exclusive to such projects, I've used buildout with Pyramid, Tryton and even for Sphinx based documentation projects. I've also seen buildouts on github for Django, Flask and Odoo based projects. 

What I expect of a proper build system

  • Easy to switch between development and production
  • Easy management of packages and package versions
  • Easy to share with other developers
  • A workflow as close to what developers expect

Here's a breakdown of how we do our buildouts to ensure that these goals are met.

The anatomy of a sustainable buildout

There are a few things that I add to my buildout to help to keep things sane. The profiles and templates folder and a requirements.txt file. I discuss their usage below.

Profiles folder

The profiles folder holds the configuration files used by the buildout. Generally the ones that we link to directly are dev.cfg and prod.cfg. These then link to the supporting configuration profiles.


Templates folder

Templates are stored in the templates folder, these templates are used to dynamically generate configuration settings. Some of them include variables which are configured in the .cfg files found in the profiles folder.


requirements.txt to define build tools

I recently added the requirements.txt file to make the workflow closer to a more typical Python development workflow, for example most Flask developers expect such a file. Since Buildout is your build tool, we define it as a dependency in the requirements.txt so that a user can easily install it.

Getting started is a matter of running the well known "pip install -r requirements.txt" command. This installs the buildout command.

buildout.cfg is not stored by git

With this approach the buildout.cfg file is not stored in the repository, so it is added to the .gitignore file. The process of kick starting things requires that a user copies the buildout template from the templates folder into the root of their buildout.

Bootstrapping

Here's a quick example with a real project, the Python Jamaica website. I've added comments to describe each step of the process. I only assume that you are familiar with virtualenv and pip.
...
...
One gotcha to look out for, after bootstrapping a local command bin/buidout is used to run the actual build (not to be confused with venv/bin/buildout).

Thanks to Maik Derstappen for pointing me towards "buildout bootstrap" which replaces the older approach of using a special bootstrap.py file.

Day to day usage

Once the buildout is installed here are some day to day tasks that a developer might find themselves doing.

Launching an instance

During development a standalone instance can be launched with the command:

bin/instance fg

This launches the reference site on port 8080.

Switching between development and production mode

Switching between development and production is as simple as changing a line in the buildout.cfg file.
Other available profiles are commented out.

[buildout]
extends =
    profiles/dev.cfg
#   profiles/prod.cfg
#   profiles/prodtest.cfg

Package management

The most common package management tasks include adding packages, removing packages, pinning the versions of packages. The buildout is configured to read the setup.py file. The big deal here is the settings associated with install_requires. Just look for that in the setup.py file and add the packages that are dependencies. (This is a standard python packaging convention learn more about install_requires).
Here's what it looks like in my buildout.

Additional Background


This is not original, while I've tweaked and hopefully improved things, I lifted the idea of a "profiles" folder from Redturtle https://github.com/RedTurtle/deployments.buildout.plone.
I've seen similar approaches implemented by others, for example Jarn https://github.com/Jarn/buildout calls their profiles folder "cfgs", Starzel https://github.com/starzel/buildout calls the profiles folder "linkto" and in the Plone Intranet project they place their .cfg files in the very "*nixily" named "buildout.d" folder. I like the name "cfgs" it is most descriptive so I may adopt this naming approach in the future.



Building Boats

Posted by Eric Steele on August 26, 2016 02:47 AM

I recently read a quote attributed to Antoine de Saint-Exupéry:

“If you want to build a ship, don’t drum up the men and women to gather wood, divide the work, and give orders. Instead, teach them to yearn for the vast and endless sea.”

The managing of open source projects is often described as “cat herding”, but I’m hard pressed to think of a single instance where standing behind and attempting to goad contributors into moving towards a specific destination has ever worked. The best work we’ve done has come from storytelling, from saying “beyond the horizon is a thing and it is wonderful and will you take us there?”

Quote Investigator believes the Saint-Exupéry quote is really a modernization of a statement from his “Citadelle”, and while certainly not as succinct, this original version feels far more appropriate:

“One will weave the canvas; another will fell a tree by the light of his ax. Yet another will forge nails, and there will be others who observe the stars to learn how to navigate. And yet all will be as one. Building a boat isn’t about weaving canvas, forging nails, or reading the sky. It’s about giving a shared taste for the sea, by the light of which you will see nothing contradictory but rather a community of love.”

Or maybe the cat metaphor works if you just use a laser pointer.

Barcelona 2016 sprint update

Posted by Paul Roeland on May 19, 2016 01:06 PM
image

This week, a group of 15 people is gathering in lovely Barcelona to work, experiment and play with new concepts for our favorite CMS, Plone

And we’re not the only ones, a few countries further north a group of people are doing another sprint, in Berlin! But I’ll let the Berlin people do their own reporting. 

We divided up in three teams, delving into the front-end, restapi and back-end (more or less), with lots of interaction going on between the teams.

Since my strengths aren’t exactly diving into the deep inward workings of Plone and underlying technologies, I had the nice job to try to summarize where the work is going for now, in terms that hopefully anybody with a keen interest in the community can understand. 

Do note that in describing some of the work in terms that even I can understand, I may have grossly oversimplified or misrepresented some things. So, if your reaction is “huh?”, it’s probably wise to think “oh, polyester has gotten it all wrong”  and ask accordingly, before putting on your angry hat and take to da interwebz…. 

REST api

Probably the easiest to describe, as it is already quite well documented and used in production, is plone.restapi. It has clear goals and design ideas, and saw a lot of progress already this week.

Endpoints (that’s functionality to all folks new to the jargon: things you can get information from, or create content, or change workflow state or permissions) are being added as we speak. And some of the the tougher issues with CORS and other security-relevant topics are being tackled.

One recurring theme on this is that one of the key strengths of Plone, real traversal, is not something that others do very well, or even reckon with. As an example, the current version of OpenAPI (formerly known as Swagger), a formal description language for API’s which would be great to use as a documenting and discovery tool, wants to know all endpoints in advance. That’s all very fine and dandy if your site basically looks like index.php?incomprehensiblemumbojumbo, but ours are better behaved. In short, we need to parametrize the path in the URI, and do no know in advance how they will look or how many there will be. And that’s a problem for the tooling right now, although they are aware of it.

On the plus side, the way Plone does real traversal makes it a really, really good fit for a proper REST interface. So, that will be the way we’re moving forward.

Status: A beta version of plone.rest (the underlying HTTP verbs) should come out this week, and the actual plone.restapi will see a proper alpha release with many new endpoints and improved documentation.

Polyester Crystal Ball Assessment: expect this to be useful already in the very near future, and absolutely essential in the slightly longer run. The documentation-fu runs strongly in this one, too. 

PloneClient

At the same time, a very talented bunch of people is hacking away at a prototype for a full, modern client based purely on said REST api.

To my slight disappointment, the Great JS Framework Wars were not decided by pillow-fight, but by actual reasoned discussion. And that means that this client is being written in Angular2. Of course, remember, anybody can always implement a client in their preferred framework-du-jour, but for this prototype this decision stands.

so, after a few days of intense discussions, frantic typing and good food, what is already working as ng2 components?

  • breadcrumbs
  • navigation
  • administrative interface (aka ‘the toolbar’)
  • search (yep, it works, and fast)
  • dynamic components ( ‘tiles, also behaving with portlet functionality, rendered as Angular components’ to lay-people like me)
  • there will still be a concept of left, right, footer and header slots, 
  • Mosaic will be implemented, but for now stick to having it on the ‘content’ slot only, and not deal with inheritance.
  • and it all looks comfortingly familiar, with Barceloneta-style theming

Of course there is still a long list of work in progress:

  • routing (well, our brand, with full traversal) *sucks* in Angular2 (at least in RC1, there is hope…), as they do not fully grasp the power of this idea. See the recurring theme here? But Eric Bréhault has a patch to make it work.
  • json-based form generation. Feed it the same json-schema based schemes as delivered by plone.restapi, and you can have your edit and add forms generated. There’s still questions of validation: some can be done client-side, but some only server-side. But it’s a very promising route (eh, no pun intented)
  • adaptability: you will be able to override any HTML or CSS template used in PloneClient. Call it “jbot for Angular”, if you will.
  • Through The Web Theming editor.
  • Javascript for overrides of what comes with Angular, or for unrelated add-ons, can be added using Webpack. Yep, new technology, but hey it works!
  • and there’s work done to get a registry to declare dynamic components. I’d almost call it ‘zcml for Angular’. That’s probably not the scientific term, but helps me understand.

all in all, a pretty impressive list, and already enough to give you an understanding that such a one-page client is not only possible, but could be pretty cool, and fun to use both for end users and integrators.

Polyester Crystal Ball Assessment: well, color me impressed. It will take work, and we may run into some issues. But such a client seems eminently possible, and I’m pretty much convinced that the needs and wants of ‘casual’ integrators, themers and tinkerers will be met. I say: bring it on!

PloneServer

The team whose work was hardest to grasp for me was the group working on future & experimental backends. The ideas behind it are clear enough:

  • create a headless CMS backend
  • with modular services for users/groups, searching and indexing that may be better filled with best-of-breed tools (hi there, elasticsearch and friends)
  • of course working on Python 3
  • able to use async technologies, websockets and the like

yet the devil is in the details, and un-tangling the many tangled layers of Zope, CMF and more that now form our mille-feuille of a stack is no easy task. 

At the same time it is also crucial that we as a community start experimenting, and testing some of it in real world scenarios.

So, experimenting there was. And do note: none of this is final, we’re definitely in the “let’s try some crazy stuff and see how far we get “ stage here…
Basically we took the top layer (dexterity) and the bottom layer (ZTK) and ripped out everything in between, and see how far that would get us before adding layers back.

Some results so far:

  • dexterity works with it, as do most of the dependencies for it. All on Python 3.5. Work continues to get more dependencies going.
  • you can already register a contenttype, create it, view it, and get the json representation of it, sharing format with what plone.restapi gives you.
  • the server uses asyncio. In very unscientific terms, “aiohttp is the new medusa”
  • a new plone.server could replace Zope2. It would use the actively maintained Zope Toolkit, which includes zopesecurity, the component architecture of Zope3, DublinCore, schemas and low-level security.
  • workflow is still an open question, although there are candidates that should be looked at
  • the registry packages have already been ported to Python3
  • it would be possible to have a compatible plone.api working on Plone5, a future Plone6 (with a cleaned-up Zope) and this further-in-the-future vision, let’s call it Plone7 for now.

the surprising part of this (and remember: this was meant to be experimental) is that quite a bit of the porting to Python3 can already go back into mainstream Plone.

And of course that it shows there is an active interest, and developing ideas, in growing the next generation of Plone. All while keeping up with our proud heritage of allowing far-reaching customization and modularity. So if you need to plug in another search system or another source of user/group  data, that will be possible.

Polyester Crystal Ball Assessment: expect this to be at least two years away for any simple mortal like me. Also expect lots of changes and lessons learnt. But do be very excited about the experiments going on, which will grow into real-life solutions being vetted with real-world sites, and getting us a clear path into the future. Oh, and part of the Python3 porting is usable far earlier than I had expected.

I never promised you a rose garden…

As you would expect, all groups also encountered complex problems.

Security is always hard. In a world with discoverable API’s, and back-ends having to deal with potentially malicious (or just sloppily programmed, which might lead to the same results) front-ends this becomes ever more important, on every level. Remember: every new web technology leads to a new security acronym. Want websockets? Learn about CSWSH… 

Luckily this is very much in everybody’s mind here, and security is a core key ingredient and not an afterthought on what people are developing.

Traversal still remains as powerful an idea as when Jim Fulton created Zope in 1998. It’s how the web should work. Yet many of the new tools and techniques that we are now incorporating do not deal with it very well. On the other hand, it’s what sets us apart, and we may have to adapt the tools to do the right thing.

Untrusted Code (a.k.a. Restricted Python) is both pretty hard to deal with, from a security standpoint, yet also a reality for any kind of serious universal CMS with sophisticated users. The balance here is a fine one.

The JavaScript ecosystem still remains very much in flux.
If you ever thought “buildout” could be a bit of a diva, just wait until you meet the Nuclear Powered Mushroom. It throws tantrums like a three-year-old on a sugar rush.
And there have been 13 days since the last grunt-gulp-bower-webpack-rollup replacement…


FAQ / Panic Attack

I’m sure a lot of you will have many questions. As did I. 

So I asked them ;-)

  • OMG THEY KILLED KENNY Through The Web
    eh, no they didn’t, I’m glad to report. The ability for integrators and site admins to customize just about every aspect is firmly on the radar, and can be maintained even using things like Angular.
  • YOU GUYS DECIDE EVERYTHING BEHIND MY BACK
    eh, no, not really, All of this is firmly in line with the roadmap and ‘2020′ discussions that are broad community discussions. Part of that is experimenting, to  base decisions on actual learned experiences and not guesswork.
  • I WANT MY OLD WAYS BACK
    hmmm. Yep, there you have a point. No, the <blink> tag is not coming back. And neither is the old, old way of doing javascript.
    It’s the web, and it’s 2016.
    What we do need to do, is make sure that we do a better job of documenting the new ways of doing things that will come as we move forward. But yes, learning new techniques is part of the job description…

wait… there’s more!

The sprint is not even over. And there will be many more sprints and discussions, both online and in real life. But let me say that this was one good way of giving all those future discussions a much more solid foundation of prototypes, experiments and performance statistics. 

Time to get involved!

This particular experience was brought to you by the following people:

Ramon Navarro Bosch, Víctor Fernández de Alba, Timo Stollenwerk, Eric Bréhault, Asko Soukka, Nathan Van Gheem,  Sam Schwartz, Lukas Graf, Thomas Buchberger, Eric Steele, Berta Capdevila Cano, Rob Gietema, Aleix Llusa Serrá, Albert Casado and Paul Roeland, with liberal helpings of sunshine, culture, cuisine and assorted friends & family who where visiting Barcelona…

Plone and films, the “hero” edition

Posted by Paul Roeland on March 30, 2016 11:20 AM
image

So, another year, and another film festival site to be built. For the Roze Filmdagen, the Amsterdam LGBTQ Film Festival, I create a new website every year. This year was the ‘superhero’ edition.

Of course, I wanted to use shiny new Plone 5, with the latest tech and features. So, how does that work in comparison to previous years?

  • Creating a theme is almost embarrassingly easy these days. I followed the training docs and basically created a variety on Barceloneta. Using bobtemplates gives you much freedom, and it’s a joy to use LESS. 
  • One of the big challenges is how to present a grand total of 136 screenings in a way that is easy to navigate, filter and slice. I used the fabulous collective.isotope to show all movies in the programme so you can sort them by day, theme, sort of movie and other ways. That works also really well on mobile. Which, by the way, is rather vital to us. A staggering 71% of our site visitors are on mobile devices…
  • Mosaic. Oh, mosaic. How I love thee. We really need a proper release soon. I was using it from git directly, but that is not something for the inexperienced integrator. But Mosaic makes editing complex pages a real joy.

It is also worth noting that one of my long-standing pet peeves, namely the insane way of formatting dates, can be completely addressed by using Patternslib, more specifically pat-moment. PAT-MOMENT ALL THE THINGS!!!! Finally, as an integrator, I have full say on how a date and time should be shown, and can make it say human-friendly time announcements as well. Love it. 

My main take-aways:

  • I’m needing far less add-ons than previous. Add an image to an event-like content type? Use a behaviour, done! And with Diazo and z3c.jbot, I can easily fix up templates the way I want. 
  • I actually love the resource registry. Adding javascript always was a hit-and-miss thing for me, as I’m an integrator and not a developer. Using bundles it becomes predictable. I know the docs on it could be improved (and they have been, since then), but really it helps to let go of the old patterns (no pun intented) and behaviours (oh this is not going well, now is it…) and embrace the new.
  • If you’re going mobile-first, as you should, be aware. Safari on iOS is fast becoming the new Internet Explorer. And the Iphone 4 is the modern equivalent of the Windows XP computer. Dear Apple, if you are not allowing alternative browsers on your platform, could you please get your shit together and make sure Safari speaks some standards? Like, now?

All in all, for my purpose, Plone 5 passed the test with flying colours. OK, so it’s not a huge site. But it was completed, on budget (well, the budget is zero so that’s easy), in one weekend. Yay!

Most of all, visitors (all 9.500 people actually coming in to watch a movie, and the web visitors from abroad) were rather pleased. 

So, is Plone a superhero? Well, that’s pushing it. But it sure made my job easier and more pleasant this year, and proves it scales quite well to small/medium tasks. And I should mention quite a few people in the ploniverse that are my personal heroes for making it happen. So thanks Nathan, various Erics, Ramon, Asko, Maurits, Philip and so many many more. Sorry I can’t mention you all, but you know who you are…

Plus, any site I can update with latest news while wearing 12 inch heels passes my ergonomic tests. Well, the shoes were not very ergonomic, but you get my drift… 

image

Gloss - Build a dynamic site by assigning content areas to your static HTML theme

Posted by David "Pigeonflight" Bain on March 07, 2016 12:37 PM
What if you could make a static HTML page into a living breathing dynamic site simply by "tagging" sections of your page as dynamic? Gloss aims to be just that, simply "tag" or "assign" sections of your static page with special gl- css classes and it will magically transform into a dynamic site. Currently we built Gloss as an extension of the Plone CMS and it has changed the way we look at the design/prototype/build workflow.

Here's a short video explaining Gloss.



For more information about Gloss visit the documentation page at http://the-gloss-project.readthedocs.org


Using Requirejs to load Jquery UI from a CDN

Posted by David "Pigeonflight" Bain on February 12, 2016 08:47 AM
This post discusses how to use Require.js to load an external library.

One big benefit of Require.js is that it allows a developer to reliably load javascript modules without introducing dependency related conflicts. I needed to include Jquery UI into Plone 5 (which now manages the loading of javascript modules and dependencies using Require.js). If you're curious you can read more about use of Require.js in Plone.

In Plone 4.x you basically use the plain old javascript approach (with a bit of jquery magic) to load and run your scripts. Loading and using the Jquery UI datepicker might look like this:
<script src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
<script>
 $(document).ready(function(){
    $(function() {
    $( ".my-calendar-box" ).datepicker(
        { dateFormat: "dd/mm/yy" }
        );
  });
   
 });
</script>

With the introduction of Require.js in Plone 5 the code above would now look something like this:

<script>
require.config({
    "paths": {
      "jquery-ui": "//cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min"
    }
});
require([ "jquery", "jquery-ui" ], function( $ ) {
       $(".my-calendar-box").datepicker(
        {
            dateFormat: "dd/mm/yy"
        }
        );
});
</script>

Note that when we define the path to "jquery-ui" the ".js" is removed from the end of the path. We can now call our newly defined "jquery-ui" module by using a require() call.
Plone 5 ships with some common modules such as jquery so we only need to  require "jquery".

If you want to get a list of all the javascript modules that Require.js has already loaded, run the following command on the javascript console of your Require.js powered app:
require.s.contexts._.defined

It is more common to put all your require.js related code in a separate ".js" file and then load that file. I have notes on doing something like that with SemanticUI.

From Zero to Plone - Towards faster on-boarding

Posted by David "Pigeonflight" Bain on January 21, 2016 03:51 PM
About 4 months ago we took on a new developer and I started by explaining that it takes about 3 months to become confident with Plone. Being a confident developer he took this as a challenge, assuming that he would be over the learning curve within 3 weeks.

After 4 months plus of working with us I asked him to give me his feelings about my 3 month timeline. This was his response (with a few additions from me):

"I think I'm comfortable with it. However, it [depends on] the type of task you've given me... I might be uncomfortable with [doing a migration]. It's like giving a recently graduated doctor the task of performing a heart surgery as his first task at the hospital..."

So he's comfortable with some tasks but there are others that will require more experience.

I've actively been experimenting with ways of making Plone easier for at least 3 years (and less actively for longer than that). In that period I've come up with the idea of Plone Drills, created a Diazo Snippets Library and Chrome Plugin, worked out fast cloud based installation of Plone, done work on a Plone Newbie Developer Toolkit (Plone 4 only), contributed to Alex Clark's Plock Plone Installer project and spent a lot of time on a theming approach for Plone which "extends" Diazo called Gloss. I also created a short video series related to using Gloss with Webflow.

I'm still haunted by this problem space and the general idea of on-boarding web developers. It's led me to my latest side project, the aim being to provide a faster on-boarding experience for new Plone developers. I've been calling it a book but that might be a poor description since it will most likely involve more than just a text.

BTW... If you are interested in the fastest way to get going with Plone then I'd encourage you to sign up for my upcoming book/project/thing. You should see the option to sign up somewhere on this page.

Semantic UI + Plone + RequireJS (just a gist)

Posted by David "Pigeonflight" Bain on December 14, 2015 03:47 PM
I wanted a way to include a jquery plugin in a Plone 5 add-on that I'm working on, but I really wanted to find the simplest way, without using bundles and registering resources with Plone's Genericsetup mechanism.
I was able to pull it off with standard page templates and static resources and it ended up being very close to the way it would be done without all the additional framework related code.

Perhaps I will go into more detail about this approach at a later date. But, following the principle of release early, release often, I'm posting a gist of what I've been doing.

Here's a screenshot of a page that's using the ratings component provided by SemanticUI (a jquery plugin).



I've posted the code with some explanatory notes as a github gist available here: https://gist.github.com/pigeonflight/69313231ad8c8a38082f

Hopefully it will save someone lots of time.

Building a Self Hosted CMS Site using Webflow and Plone (Video Series)

Posted by David "Pigeonflight" Bain on November 26, 2015 02:13 PM
One of my personal goals is to make it easier for persons to get started with web development technologies. I teach web programming at my local university, I blog about my preferred CMS (Plone). For front-end development I now point designers at Webflow. In line with that I've recently created a video series that shows how to use Plone as your CMS and Webflow for theme development.


Last month I spent 10 full days (and some nights) building out the initial videos which demonstrate the process of integrating Plone with Webflow.  I noticed a few days ago that there was additional money in my Paypal account, apparently as a result of a sale. I haven't exactly been over the top with my promotion and marketing since the launch, so it was an encouraging event.  While I did blog about it at medium.com, I never posted anything here on my personal blog. So this is my "official" blog announcement.

The video series focuses on using Plone 5 with Webflow.  Each video walks you through what you need to know in order to take advantage of Webflow for the look and feel of your site and Plone as a robust, self hosted CMS platform. The idea was to release new videos that will complete the series as I go, if you purchase today you lock into all the new videos for today's purchase price.
The topics covered so far:
  • Introduction
  • Installing Plone Sandbox
  • The Webflow Steps
  • Organize- Structuring your theme
  • What is Gloss?
  • Gloss Marker Classes
  • Marking your theme - Hands on Linking
Learn more on the "Webflow meet Plone" page.

I fell off a bit, I planned to add more videos to the series (for which I must apologize) I can safely promise the next video in the first week of December and more to come after that.

Taking Inspiration from the Webflow CMS (yes this is about Plone)

Posted by David "Pigeonflight" Bain on October 12, 2015 04:54 PM
Webflow just released their CMS and it's slick. There are lessons for Plone and other CMS communities here. In case you didn't know who Webflow's target audience is you might want to watch this video.


I love this promotional video. Especially when he says that Webflow creates "Clean compliant HTML and CSS that I will NEVER EVER look at". That's the point, Webflow aims to free designers from depending on coders.

In achieving this goal the Webflow.com team does one thing very well, user interface (UI) and user experience (UX) design (maybe that's two things). The screen below is an example of how they manage dynamic data.


I've labelled what I think are the key aspects that drive this interface, (1) A clear link to an introductory tutorial especially important for first timers, but out of the way enough that regular users can just skip over it, (2) at the top of the next panel is the instruction to "Create Collection" this is effectively the "save" button, if you want to just accept the defaults, click this and you're done. (3) Some ready made "Collection Templates"  with predefined fields, you can select one of these and then further customize it to your liking. (4) "CMS Preview", a preview of the form, as it will be experienced by an editor of the site.

Collections & Collection templates... where have I seen this before?

The interface isn't just about being clean or slick, there is very purposeful choice of language. While many other platforms have gone with the idea of content types, they've made the underpinning concept "Collections", the whole focus is on creating collections of data such as recipes, events or blog posts and then displaying the individual items "Collection templates" or "Dynamic Lists".

In this paradigm what you might call a content type in a CMS like Plone or Drupal is now referred to as a "Collection template", which makes much more sense in the context of the the Webflow universe.

The interface also flows logically based on the idea of defining a "Collection" then a corresponding "Collection Template". Add to this logical flow very obvious visual cues and you have the makings of a beautiful interface.

Upon further reflection I realized that I had seen this somewhere before. In database programs like Filemaker Pro and Access. What Webflow has done is place the design firmly in the forefront. So a "Collection" is analogous to a database table, the "Collection templates" are associated with underlying forms which allow a user to add new records, finally custom display of the data is controlled visually through the same "Collection Templates" to make it display things the way we want. To top it off, an otherwise ordinary static page can also be made dynamic by embedding a "Dynamic List" which is effectively a feed from the table (uhm) collection.

Designer Friendly

It's clear that they've put a lot of thought into making it designer friendly.

I think the use of the term "Collection Template" instead of "Content Type" is a stroke of genius. It fits nicely into the visual designer paradigm and emphasizes the visual display of the content. Of course you'll need to define the fields of your content but that action is towards a specific end, templates are things that a designer interacts with all the time, by qualifying the name as a "Collection Template" there is no confusion with the other kinds of templates used in Webflow.

If you want to see where this really shines take a look at this video that explores Webflow Dynamic Lists:


After interacting with the Webflow system and then going back to Plone's dexterity content type editor I think there's room for UX improvement. The truth is Plone's Dexterity approach is far more capable and extensible but isn't as friendly for the visually oriented. The Webflow CMS wins in one important category, the ability to link a custom design process with real world dynamic content in a visual and easy way.

So now we have a really nice bicycle

The Webflow CMS is now a very slick bicycle, lightweight and fun to use. By contrast, your average CMS is more like an ugly car or helicopter, very capable but far less fun to use. Complexity is often a result of additional features and what we're witnessing with Webflow vs other CMSes is a slicker less complex ( though less feature rich) system when compared to older more capable but less slick CMSes. From the perspective of the Plone CMS I'd say we have a helicopter, not as slick as the Webflow bicycle but more powerful. Calling Plone an ugly helicopter is not meant to discourage the Plone team, but the fact is, while a lot of improvement has happened, there's a lot of UX work that will need to happen to bring the Plone experience on par with the Webflow experience, but we certainly have the tools make it happen. One thing I'm keeping my eyes on is the the newly emerging Mosaic drag and drop layout editor. Here's a video of Mosaic in action:


So why don't I just use Webflow by itself? For really small projects I may, but there are some limitations to committing to a bicycle, even a slick one. I consider Plone to be far more powerful and it has a mature ecosystem of add-ons, I can implement custom authentication for example to integrate it as an intranet solution or use it for file management, just to name a few things.

I suspect that this won't matter much for Webflow's core audience (the visual designers who want to ditch the coders), they will definitely adopt the new Webflow CMS.

As for me, my workflow is a mixture of Webflow for developing the design and interactions to generate clean compliant HTML and CSS. I then make my static Webflow site dynamic with Plone. This has worked beautifully for me over the past 2 and half years. Next on my agenda is to refining our tools and processes to make it even simpler for the visual designers that work with us to prepare layouts that work seamlessly with Plone.

Installing Plone 5 on Cloud9 IDE

Posted by David "Pigeonflight" Bain on September 28, 2015 10:15 PM
March 21, 2016 - updated the commands to ensure that all dependencies are installed before running the custom script (thanks to CodinCat for comment below)

Plone 5 was released today. Here's how to quickly try it out on Cloud9 IDE.
I'll assume you have already signed up with Cloud9 IDE.

Step 1 - Create a new Workspace

On the Cloud9 IDE dashboard select Create a new workspace

Use the default settings as a Starting Point

Then click Create workspace.

Step 2 - Enter the installer command in the terminal

1. in the terminal type (or cut and paste) the following commands:
sudo apt-get update
sudo apt-get install python-dev python-virtualenv libssl-dev libxml2-dev -y
sudo apt-get install  libxslt1-dev libbz2-dev python-tk python-gdbm -y
2. On Ubuntu 14.04 and c9.io you'll need to install a newer version of Python.
wget https://www.python.org/ftp/python/2.7.14/Python-2.7.14.tar.xz
tar xf Python-2.7.14.tar.xz
cd Python-2.7.14/
./configure && make && sudo make install 
3. Finally install plone 
wget -qO- goo.gl/HBzmFw | bash

You will see output similar to this:

Step 3 - Launching Plone 5

After successful installation (takes about 5 minutes) run the following command:
cd zinstance
bin/instance fg
Once it has started successfully you'll see the following message on the terminal:
INFO Zope Ready to handle requests
At that point select Preview > View Running Application.




IMPORTANT: You'll need to get the adminPassword, it is located under the 'zinstance' folder see the screenshot below.


Once it's running, click on the "pop out" button



This will lead you to the Plone installer (it will look a little weird, because of an issue with proxying the site via https). Click on Create a new Plone site and following the instructions.

Once you're successful you'll see a running Plone 5 site:

Things to Know

Here are a few things to know about Plone.
  1. Plone runs on an application server called Zope 
  2. You can actually run multiple copies of Plone on one Zope application server

Next Steps


  1. Enable caching "Admin" > "Site setup" > "Advanced" > "Caching". Plone will go much faster.
  2. Browse around the Plone 5 docs

Install Plone 5 Release Candidate on Cloud9 IDE

Posted by David "Pigeonflight" Bain on September 10, 2015 01:28 AM
These are quick instructions for installing Plone 5 RC1 RC2 RC3 on Cloud9 IDE. This walks you through the process of installing Plone on Cloud9 IDE. We assume you have already signed up with Cloud9 IDE.

Step 1 - Create a new Workspace

On the Cloud9 IDE dashboard select Create a new workspace

Use the default settings as a Starting Point

Then click Create workspace.

Step 2 - Enter the installer command in the terminal

in the terminal type the following:

wget -qO- goo.gl/HBzmFw | bash

You will see output similar to this:

Step 3 - Launching Plone 5

After successful installation (takes about 5 minutes) run the following command:
cd zinstance
bin/instance fg
Once it has started successfully you'll see the following message on the terminal:
INFO Zope Ready to handle requests
At that point select Preview > View Running Application.




IMPORTANT: You'll need to get the adminPassword, it is located under the 'zinstance' folder see the screenshot below.


Once it's running, click on the "pop out" button



This will lead you to the Plone installer (it will look a little weird, because of an issue with proxying the site via https). Click on Create a new Plone site and following the instructions.

Once you're successful you'll see a running Plone 5 site:

Things to Know

Here are a few things to know about Plone.
  1. Plone runs on an application server called Zope 
  2. You can actually run multiple copies of Plone on one Zope application server

Next Steps

This quick cloud based installation is a great way to try out some of the new things in Plone 5. Plone 5 is still being polished so it will have rough edges. Try changing the look of your site by following these notes from Asko Soukka on customizing Plone 5's default theme.

If you get this working, please leave a comment. If you try and have issues leave a comment.

Plone Development - There's a lot of information in those ZCML files

Posted by David "Pigeonflight" Bain on September 10, 2015 12:59 AM
Reading ZCML files will open up a world of understanding to you as a Plone developer. A ZCML file is basically a roadmap that explains how the pieces fit together.

If you're interested in how a Plone package works find the configure.zcml and it will lead you from there.

A Fancy but Simple Example - Collective.Multimail

The collective.multimail add-on is described as follows "Allows you to use more than one mailhost. Email is filtered by rules which determine which mailhost to send a particular email to."

It takes advantage of an additional add-on called "collective.monkeypatcher" to extend/patch the behaviour of the "mailHost" email utility provided by Plone.
Read it for yourself and see if it makes sense.

Line 5 an additional namespace is registered called "monkey".
Line 23-29 the utility is used to "patche" the original "Products.MailHost.MailHost.MailBase" > "send" with its own "patch.send".

. . You can view the file in context at: https://github.com/collective/collective.multimail/blob/master/src/collective/multimail/configure.zcml

This examples shows the power of ZCML and also how it is possible to quickly understand how a the parts of a system work together by simply reading the ZCML file. Stay tuned, there's more to say about this ZCML thing.

Final Notes

Just to wrap things up, there really is nothing about ZCML that makes it a Python technology. It stands for the Zope Configuration Markup Language and it is used for (gasp) configuring things (in fact motivated programmers have developed component style implementations in other languages such as Ruby.).

Removing rogue members from your Plone site

Posted by David "Pigeonflight" Bain on August 09, 2015 01:13 PM
I recently had one of my Plone sites get hit by a "join form attack". Basically a spam bot which started adding new members to my site (we don't use a captcha at the moment). I ended up with far more members in the site than members of the organization. I started deleting them manually using the Zope Management Interface > acl_users > source_users, but that became tedious quickly. So I wrote a command-line script to do the job for me.

In my case the spambot wasn't super smart, all the usernames created by the bot started with capital letters. All my real users had usernames with common letters. This made it easy to filter out the bad guys.

Here's my script in a nutshell:
.
.

I used the special --object-path option to indicate the location of my Plone site, relative to the root of the Zope application server.

My final command looked something like this:

bin/instance_debug --object-path='pathto/sitein/zodb/plone' run member_cleanup.py > members_cleanup_report.txt

The resulting output went to a members_cleanup_report.txt.

Many thanks to the plone.api and plone.docs teams, being able to make use of plone.api.user made it 20 times easier to write the script.

A note about transactions

Before my script would run successfully I had to add a transaction.commit() line, it seems commandline scripts require this.

Parting thoughts

There's a lot more that can be added to the script to make it smarter. For example for certain kinds of sites you could filter based on whether the user has created any content or perhaps it might be based on log in patterns, if they have never logged in or only logged in once.

I'm weighing the pros and cons of having a captcha. At the moment members can't do much except change their portrait pictures and profiles, but I know that some spammers use the portrait for hosting "bad" images, so captchas may have to be introduced.

References

The resources I used included the following references:

http://docs.plone.org/external/plone.api/docs/api/user.html
http://docs.plone.org/develop/plone/misc/commandline.html#scripting-context
https://pypi.python.org/pypi/plone.recipe.zope2instance

Install Plone 5 Beta 4 on Cloud9 IDE in 5 minutes

Posted by David "Pigeonflight" Bain on August 04, 2015 09:28 PM
(update August 27, 2015:  The script now installs Plone 5 Beta 4)
These are quick instructions for installing Plone 5 Beta 4 on Cloud9 IDE, they supercede my post on installing Plone 5 Beta 2. This walks you through the process of installing Plone on Cloud9 IDE as it is no longer possible to do this on the free tiers of Codio. We assume you have already signed up with Cloud9 IDE.

Step 1 - Create a new Workspace

On the Cloud9 IDE dashboard select Create a new workspace

Use the default settings as a Starting Point

Then click Create workspace.

Step 2 - Enter the installer command in the terminal

in the terminal type the following:

wget -qO- goo.gl/5FMjBC | bash

You will see output similar to this:

Step 3 - Launching Plone 5

After successful installation (takes about 5 minutes) run the following command:
cd zinstance
bin/instance fg
Once it has started successfully you'll see the following message on the terminal:
INFO Zope Ready to handle requests
At that point select Preview > View Running Application.




IMPORTANT: You'll need to get the adminPassword, it is located under the 'zinstance' folder see the screenshot below.


Once it's running, click on the "pop out" button



This will lead you to the Plone installer (it will look a little weird, because of an issue with proxying the site via https). Click on Create a new Plone site and following the instructions.

Once you're successful you'll see a running Plone 5 site:

Things to Know

Here are a few things to know about Plone.
  1. Plone runs on an application server called Zope 
  2. You can actually run multiple copies of Plone on one Zope application server

Next Steps

This quick cloud based installation is a great way to try out some of the new things in Plone 5. Plone 5 is still being polished so it will have rough edges. Try changing the look of your site by following these notes from Asko Soukka on customizing Plone 5's default theme.

If you get this working, please leave a comment. If you try and have issues leave a comment.

5 minute Plone 4 install on Cloud9 IDE

Posted by David "Pigeonflight" Bain on July 31, 2015 12:33 PM
Update (Feb 19, 2016): Plone 5 is the latest version and I've done a blog post on how to get Plone 5  running on Cloud 9 IDE.

This is an overview of getting Plone 4 (4.3.6 at the time of writing) up and running in 5 minutes or less on Cloud9 IDE. The aim of this is to make it easy, especially for students, to try out Plone, and more importantly Plone development for zero dollars. My previously recommended cloud based options (Nitrous and Codio) no longer offer a viable free tier.

Step 0 - Get a Cloud9 IDE account

You will need to get an account with Cloud9 IDE, so go and sign up over there and then come back here.

Step 1 - Start a new Custom Box

Not much to say here.  You can accept all the defaults to and then click "Create Workspace".

Step 2 - Run the Plone installer script

In the terminal paste the following command and press enter to begin the installation:
curl -L https://goo.gl/Enjwms | bash

You will see output similar to this:


Step 3 - Launch the server

Run the following commands to start Plone as a foreground process.
cd $HOME/workspace/zinstance
bin/instance fg
To stop plone use Ctrl + C.

Step 4 - Setup Plone

You will know that Plone is running when you see the following message in the terminal.
 "Zope Ready to handle requests" ([3] in the screenshot below). 

You can view the default administrator credentials, username and password under 'workspace' >  'zinstance' in a file called adminPassword.txt ([2] in the screenshot below). To go to your live server select 'Preview' > 'Preview Running Application'  ([1] in the screenshot below). 



You will see the Zope server ready to create your first Plone site.  Start by clicking the little icon to pop it out into a new window.


You can now create a new Plone site, you will be prompted for your Admin credentials (we discussed the adminpassword.txt above)
Zope server, ready to create a Plone Site
Click create Plone site and enter your credentials.

Important things of note

Cloud9 IDE provides a proxy that listens on port 8080, this is the default port for Plone if you change the port later on you will not be able to access the site using the Preview link.

This is for the purpose of development NOT PRODUCTION USE. For developing your new Plone based site you can work right here.

Help, my updated posts keep bubbling to the top of the Planet

Posted by David "Pigeonflight" Bain on July 03, 2015 04:11 AM
I kept noticing that whenever I updated certain posts they would end up at the top of the Planet Plone RSS feed aggregator. I haven't dug too deeply into the issue, but it seems to be a mixture of the way the Planet is configured and the way default blog feeds are presented by Blogger. Thankfully, the default Blogger feed format can be easily changed.

Previously the feed I used for Planet Plone looked something like this:
http://pigeonflight.blogspot.com/feeds/posts/default/-/plone
Which resulted in a feed enclosed between feed tags like this:

     <feed xmlns='http://www.w3.org/2005/Atom'...

My new URL now looks like this:
http://pigeonflight.blogspot.com/feeds/posts/default/-/plone?alt=rss
The new approach (ie. appending ?alt=rss) resulted in a feed with an rss tag like this:

    <rss xmlns:atom="http://www.w3.org/2005/Atom"...

I did not delve into what other things get changed by using '?alt=rss', but the most important outcome is that the "Planet" (Planet Plone) is now safe from the occasional updates and revisions to my blog posts.

Tokyo symposium, a very Plone event

Posted by Paul Roeland on June 22, 2015 10:46 AM

Last week, I had the pleasure to participate in the first Plone symposium held in Asia. 

It started already on Friday, when we (Eric Steele, Alexander Loechel, Sven Strack and me) were invited into the CMScom offices by the organizers, Takeshi Yamamoto and Manabu Terada. 

There, we met other people, like Masami Terada (whom I first met at the Bristol conference) and were treated to some great cakes. All the while having an inspired conversation on the Japanese Plone community, Pycon JP and Pycon APAC.

Later, at a rather nice restaurant, we were joined by more people, including Tres Seaver and several of the other speakers and staff of the Symposium.

The following morning we headed for Ochanomizu University, who had not only supplied the meeting space, but thoughtfully also some cute turtles and a sleepy red cat to enhance the breaks.

The Symposium itself was astounding, especially when you consider it was the first time it was held. With 67 people participating from as far away as Osaka and beyond and a wide range of talks, both in Japanese and English, there was something to be found for everyone.

Personal highlights:

  • meeting the energetic Chiaki Ishida. Apart from effortlessly chairing the high-quality panel on Plone in higher education, she has been instrumental in using and promoting Plone as Learning Management System at her university and beyond. She also works with professor Toru Miura, whose talk on using Plone for improving his lecturing programme impressed with a nice mix of experience and evidence.
  • Max Nakane, a developer who is dependent on assistive technology, gave a great speech on why accessibility matters and where the accessibility of Plone and other systems stand, and what should be improved. Not only that, the next day I had the chance to work directly with him on the Sprint, and identify issues still open for Plone 5.
  • Tres gave what he described as “the least technical talk I ever held”. Yet still, after it, I finally understand where bobo_traverse comes from… I shudder to think what happens if I see more of his technical talks ;-)
    With some good storytelling, it emphasized the community values of our tribes.

That was also the feeling that ran through the day. Not only in lovely details like hand-made Plone cookies but mostly in the talks and in the hallway conversations, this is a community aimed at helping each other. Nice touch also to include talks on other Python frameworks and technologies.

After Lightning talks (always fun, even in a foreign language!) most of us headed for the afterparty at a nearby Izakaya. Where that curious phenomenon happened again: people trying to tell you that their English is not so good, and then conversing with you in super good English…

It was fun to meet such a diverse group of people, and see that the “put a bunch of Plone people in a room and good conversations happen” principle is universally applicable.

Next day was Sprinting day. Despite knowing that sprinting is not yet as popular as it should be within the Japanese community, a pretty nice number turned up, and we all set out on our various tasks.

As said before, I mostly worked with Max Nagane on accessibility issues. The good news: Plone 5 will be a massive step in the right direction. But obviously, there is still room for improvement. If you want to help, join the Anniversary sprint in Arnhem/NL when you can, or just start working on the relatively small list in the metaticket.

The next day unfortunately it was time already to fly back, feeling a bit sad to leave but very happy to have met the vibrant, kind and knowledgeable Plone Japan community. Of whom I hope to see many again in the future, both inside and outside Japan.

And who knows, apparently “Tokyo 2020″ is a thing now ;-) 

Quick fix for Plone 4.3.x template that’s not mobile-friendly

Posted by Paul Roeland on March 28, 2015 12:21 PM

If you’re running a Plone 4.3.x (and earlier) site, you might have found Google Webmaster tools complaining about mobile friendliness. On inspection, most of that comes from one single template, image_view_fullscreen.pt 

That’s the one that displays images in their original format when clicked upon, like News images. Many sites will have their own lightbox or jquery popup anyway, but the googlebot still finds the original link.

It takes three lines to fix this. There’s a pull request already, https://github.com/plone/Products.CMFPlone/pull/407 (UPDATE: merged already, thanks Nathan) but if you’re a site administrator you can also change this one in the ZMI. (It’s under ‘portal_skins’, ‘plone-content’, from there you can customize). 

Of course, if you have a theme-product it’s better to override in there, but if you’re not that advanced, you can just use the ‘custom’ folder. I won’t tell ;-)

You do want to address this, as Google will deduct karma points for mobile users.

Another film festival, another site

Posted by Paul Roeland on March 06, 2015 03:14 PM

It’s been a while since I last wrote on how to create a Plone site for my film festival, the Roze Filmdagen, and the Internet has moved on.

So, in today’s responsive times, this is what I did, given the obvious limitations of 

  • zero budget
  • limited time
  • lots of content

Of course I started out with Plone, and then added some stuff using add-ons. The ones that are my best-loved friends are:

collective.cover, for easy composite pages. Lovely, works out of the box.

sc.social.like because, well, social media.

eea.facetednavigation to create a way people can quickly sort through the programme and find their favorite genre.

redturtle.imagedevent as the basic ‘screening’ event. 

ftw.slider to make nice sliders. It’s the cleanest, least intrusive one in my book.

And then a bunch of behind-the-scenes things to make it nicer to work with, like wildcard.foldercontents and quintagroup.dropdownmenu. Oh, and collective.ptg.contentflow for an awesome ’pictorial history’ effect.

So, how to do the pretty-making bits?

Well, a bit of lending and grabbing here and there. You can find most of it in the theme package. One of the key things to get right was reconciling collective.cover with the bits of bootstrap I was using (not the whole, but a custom small subset of  bootstrap). Luckily, there is this gist with the correct Diazo rules

Then, you want icons. So fontawesome to the rescue. And some googlefonts to spice it up.

The Good, The Bad and the Ugly

So, what’s the experience in total for someone like me, who is not particularly skilled in the art of css?

Overall: good. The site is clean, was filled up with all content rapidly, and gets positive feedback from the users. Things like Diazo make it super easy to do little things like move the sc.social.like buttons from the top to the bottom, without harming viewletmanagers.

Bad: I know I shouldn’t, but some things are just easier to do using the ZMI. Yes, I use portal-viewlet-customizations and the 'custom’ folder to insert little things like <i fancyschmansy-icon-class></i>. So sue me.

Really ugly: the handling of dates still is a mess. Setting a date format is insanely frustrating: one place for archetypes, one for dexterity, and neither works completely, or without idiotic assumptions that my time format should match my language code. No, it doesn’t and no it shouldn’t.

And somehow, somewhere, somebody thought it was a great idea to embellish every date/time with an annoying little link that shows the time in GMT format. Just so that every screenreader user out there is told: not only do you have a visual impairment, we will go out of our way to break the flow of navigation for you because you probably don’t know which time zone you’re in… Because we’re engineers, and want to be pedantic. Or so. 

Which leads to painful constructs like 

<span tal:replace=“python:toLocalizedTime(context.start())”>
                                   Start Date Time</span><br />
                                   <span metal:define-macro=“startdatesame-field-view”
                                     tal:define=“kss_class python:getKssClasses('startDate’,
                                                 templateId=templateId, macro='startdatesame-field-view’);”
                                     id=“parent-fieldname-startDate”
                                     tal:attributes=“class string:$kss_class dtstart;
                                                     title python:context.start().ISO8601()”
                                     >
                                   <span tal:replace=“python:toLocalizedTime(context.start(), time_only=1)”>Start Time</span>
                               </span><br />

Really?


Gotchas

One skeleton in the closet: run Google Webmaster tools on your site, and you will find that it gets very sad, and more than a little upset, about all those semi-automated links to “image_view_fullscreen”. Even if you’re not actually using them, because you catch them with a nice lightboxy one. But the googlebot still sees them. And complains (very rightly so!) about a complete lack of Viewport declarations or any sign that the web has moved on since 1992.

This needs fixing, since it will affect your site ranking for mobile users.

Oh, and one other thing. Really, having just a single favicon.ico is soooo 2011. What you normally do is get a 256 size PNG, and run imagemagick on it. Or, for the command-line-challenged, use a web service. But really, we have all the tools already in Plone. This is something the system should handle itself, as a nice gesture. Because we can.

But hey, let’s end positive: site delivered, at no cost, and quite well usable on tablets and phones. Hurray for Plone! Now all I need to do is find the right outfit for the Opening Night…

Stroopwafels & cake driven documentation for Plone

Posted by Paul Roeland on February 09, 2014 05:24 PM

This weekend (7-9 feb 2014) the Stroopwafel sprint was held in Amsterdam. The idea behind it was to have a ‘meta-sprint’, to organize, strategize and plan for the future of Plone documentation.

It turned out to grow beyond our initial expectations, and much work was done by the participants.

image

Cake-driven documentation was taken to new heights…

You’ll hear much more about the results in the coming months, and in the run-up to Plone 5. But some of the highlights were:

  • we have a plan for consolidating all documentation in one place. That includes docs targeted at the various audiences (end-users, themers, site admins, deployers, developers). We’ve killed many post-it notes and colored dots in the process, but now have a mindmap and a plan. Huge thanks go out to Sisi Nutt, for guiding us, and keeping us all on track.
  • we have a plan for versioning the documentation for the different versions of Plone. This is especially important as Plone5 will bring changes to the user interface. We will be able to have the documentation ready for the version of Plone that users are on.
  • we have a clean separation between the actual documentation and the technical aspects (buildouts, testing frameworks) to make it all look good.
  • we have the infrastructure in place, and working, to create multi-lingual versions of the documentation. Translators will be able to work with Transifex, to make translating much easier (Thanks, Giacomo Spettoli!) and we will even have automated screenshots in the correct language (Thanks, Asko Soukka!)
  • we’ve worked on selecting a correct license for all documentation (Creative Commons 4.0 by-attribution) to maximize the re-use of documentation.
  • we’ve identified gaps in the documentation, and a hit-list of wrong, out-of-date, and misleading info that will be taken down, corrected or re-routed.

All in all, a very productive weekend, and more than enough to do before the next Documentation sprint in Munich, Germany. 

Yes, you read that right: two documentation sprints in a row! 

We have our eyes set on major improvements for Plone 5, not only the software but also the documentation. 

And, as ever, it’s all made possible by the great Plone community. Ten people from six countries worked hard, but also had immense fun doing this.

thanks to all participants, to the people that helped us remotely, and to the Plone Foundation for supporting sprints like this.

Plone 5

Posted by Eric Steele on June 14, 2013 10:05 PM

So, as you’ve likely noticed, we spent a lot time of talking about Plone 5 during the recent Plone Symposium Midwest. I think we’ve reached the point where can really start prioritizing concepts for a major release. Obviously, any changes need to go through the Framework Team for final approval, but I’ve got a bully pulpit and I’m not afraid to use it.

Here’s how I’d like to see development focused over the near term:

 Plone 5 ships with Dexterity as its default content type story.

  • Dexterity versions of plone.app.event and plone.app.collection
  • A better set of widgets (plone.app.widgets)
  • Products.Archetypes, Products.ATContentTypes, archetypes.schemaextender remain available as add-ons for older content
  • Full multilingual story available (plone.app.multilingual)

Plone 5’s UI gets an extensive overhaul.

  • Diazo becomes the default theming story
  • Fewer CSS files makes finding and overriding easier
  • No more !important in its CSS
  • Editing interface is separated from content for easier styling (plone.app.toolbar)
  • Accessible: WCAG- and ATAG-compliant
  • Deco.gs is replaced with a more commonly-used grid system, responsive
  • New folder contents UI with filtering and batch operations
  • Improved, tested widgets
  • TinyMCE gets upgraded to version 4.0, with a simplified integration making it easier for us to stay up-to-date

Plone 5 ships with an empty portal_skins.

  • Exists for add-ons
  • Most content moved to browser views, z3c.form
  • Login rewritten to use views, events. Simple, but pluggable for more complex use cases
  • Pay attention to proper XSRF protection for our most common functionality


Plone 5 has amazing test coverage.

  • Migrating scripts from portal_skins to browser views allows more unit testing
  • New JavaScript practices mean more unit tests for our interactive stuff

Plone 5 is faster.

  • Chameleon reduces rendering times by 30%
  • Date formatting is handled on the client side


Plone 5 is easier to learn.

  • plone.api covers most common development tasks.
  • Plone 5 eats its own dog food and sets an example for:
    • Views over skins
    • z3c.form
    • Dexterity
    • Diazo
  • JavaScript integration/development requires less knowledge of Plone
  • Theming requires less knowledge of Plone, less fighting with the default setup

And most importantly…
Plone 5 is achievable within the next 12 months.

There are, I’m sure, 30 other features that are in some stage of not-doneness, and while I’d like to see us do everything, we need to find some kind of scope. I think the above featureset gives us a nice range of features, a not-too-painful upgrade, and gives everyone plenty to do over the next year.

We’ve already begun approaching Plone companies to get buy in to the effort, asking for time, money or organizational support. Six Feet Up has pledged 5 hours per week of their QA team’s time to test our work. Netsight is organizing a sprint to rework the login. AMP is pledging 5 hours a week toward deprecating portal_skins. Wildcard is taking on the folder contents revamp. If your group has a particular need, now is the time to make it happen.

In addition, we have plans to use the general community excitement that comes along with a major release to build some momentum in our non-code teams. If we can move this forward, I think Plone 5 will be a big step up for both Plone the software and Plone the community.

Please, Plone developers, refrain from <dt>

Posted by Paul Roeland on June 14, 2013 12:13 AM

Hi people, 

last week an absolutely fabulous gathering happened: Plone Symposium Midwest, in Oshkosh, Wisconsin, USA.

Much happened there, which you will read about in various other places. Especially,  we also did some good work on accessibility. I’ll post much more on this in the coming weeks; stay posted. 

One thing I want to stress today to the Plone community: we have been using the HTML tags of <dt> and <dd> for a lot of stuff. Most notably portlets. 

This is wrong. Let me repeat this: this is wrong. You should only be using <dt> and consorts if it is actually semantically correct. That means: you can use it if it is actually a definition list. You should not be using this for display purposes. Like, really not. No. Just don’t. Bunnies and kittens will die in vain when you do this. We love bunnies and kittens, and they should thrive. Trust me on this one.

image

We will change the whole portlet templates in the future. As many people are basing their own templates off of the standard ones, we won’t do this in the Plone 4.x series, so we won’t break your stuff unexpectedly, but we will do it in the future.

So please. If you want to future-proof your portlets: use something else. Use a header tag for the header, and use <ul> <li> for the content. Tack classes onto it so the design people can make it beautiful.

Just don’t use <dt> and friends, unless your portlet is actually, semantically, really, seriously, and I mean this,  an explanation of a term.

If you’re using it just to tack some CSS onto it, change your ways. Please, pretty please, with whipped cream on top. It will make our compliance with accessibility rules around the globe much easier.

Thank you.

Paul

Communications

Posted by Eric Steele on June 13, 2013 07:43 PM
“Every step is a first step if its a step in the right direction.”
- Terry Pratchett, “I Shall Wear Midnight”

I tend to be…measured in what I say. In the best case, that means that it takes me far longer than it should to communicate things. In the worst, it means that things just sit in my drafts folder.

Discussions during last week’s Plone Symposium Midwest point to many great things happening in the next 12 months. For me, the greatest is the rebooting of Plone’s communications team. Since last September, Rose Pruyne has been writing some fantastic articles for plone.org about community members doing great things with Plone. Now, she and a team of writers and editors will be conducting interviews with team leaders, developers, and anyone working to make Plone even better.

We recognize that we’ve been pretty lax about letting everyone know what’s going on, and this is our first step in fixing that.

PLOG 2013: a very human side of Plone

Posted by Paul Roeland on April 16, 2013 09:41 AM

Much has been blogged about Plone Open Garden already; the food, the hotel, the location and the great organizing by Abstract can’t be praised enough.

What most struck me, though, was that it was also such a great experience on the human, not coding, side of things. With a manageable number of people present, you could really get to know each and every one (plus, in various cases, their loved ones, both tall & tiny… #goplonegoplone). 

This was reflected in the sprinting as well; no sooner had two highly interesting talks on social and workspaces finished, or the authors got together to see if they could combine their work to make for some truly interactive intranet-behaviors.

The pattern (no pun intented) continued: people were not just developing their own pet projects, but talking to each other to get stuff moving. One example: After @datakurre had proven he will soon bring about the Robocalypse, when Plone will become self-aware and start to talk to unsuspecting users, he also worked on a proof-of-concept to integrate accessibility testing.
A few days later, we’re still clearing up some licensing issues, but we will very soon have basic a11y testing into the Plone automated testing stack. This is a huge win, especially with things moving forward so fast in the UI department.

Pool Driven Development also was a keeper. Write documentation, or be thrown in a rather chilly pool. Works a treat!

Other highlights for me were a special session with ‘rookies’. A great, hands-on way to ask where new people get stuck, help get them un-stuck on the spot, and engage them in improving the experience for other newcomers. This definitely should be repeated at other Plone events.

As should be the 'strategic discussion’. It was late at night, it was unstructured, but with 10+ people present with a wealth of Plone experience it was also very valuable. This one deserves a separate write-up, which I will try to do a bit later.

Hidden gem: Netsights’ plugin for Single Sign on, cunningly named windowsauthplugin. Now of course, this is just a little white lie; there is nothing Windows-specific about it, and it will work just as well if you have a Kerberized NFS-4 setup. But let’s not tell the Windows people that the working part of their AD setups is based on tested Unix technology, now shall we…
In any case, this means we can do more than ever to save the world, and countless unhappy users, from the hell that is Sharepoint and bring them some Plone goodness.

Much more went on, but these were the highlights for me. Oh, and that Negroni in the harbour of Sorrento, obviously.

So, next year again? You bet!

Plone: The Second Decade

Posted by Eric Steele on September 09, 2012 07:21 PM

Plone is facing an increasing number of external stressors. The economy is sinking whole companies. People who had previously relied on Plone as a software application platform have begun to opt for Pyramid instead. Mozilla lures away disenchanted developers. Names once common on mailing lists and change logs aren’t seen so much anymore. In the last 3 years, we’ve lost a lot of people that have been central to Plone’s success. Understandably, there’s been a good deal of angst over this and it’s something we absolutely cannot ignore.

So here’s the thing…

1). People move on. Worrying about or trying to win those people back is a waste of time and effort.

This sort of turnover, or “generational relay”, is nothing new to OSS projects. The “half-life” of a Debian developer is estimated to be about 7.5 years; to hope for more for Plone is a fool’s game. And we’re awesome people; though they may no longer be actively contributing to the project, those who have departed have often happily remained our friends, advisors, and advocates.

2). We have the same amount of talent as (if not more than) ever, but it’s spread out over more people. This is a good thing.

According to Oholo’s tracking, the number of active core contributors has increased by 15% over the previous 12 month period. What losses we’ve seen have been replaced by a larger number of new contributors.

3). In fact, I think the Plone community has dramatically increased in diversity – abilities, geographic, and otherwise, we’re just doing a bad job of recognizing and utilizing it.

The three regional Plone conferences this year have had over 500 attendees combined, yet we still use the annual worldwide conference as our measure for community interest. At Plone Symposium South America, 18 people signed their Plone Contributor Agreements, six of whom had made their first contributions to Plone by the end of the week. Over the past year, we’ve averaged one major sprint each month, and those have been spread across nine different countries.

I received an email from a man who has been working with Plone since its earliest days. Two weeks ago he made his first contribution the the codebase. I am thrilled to have him join us, but I have to wonder why it took us all so long to call on him to help.

We have Python and JavaScript developers, designers, marketers, writers, sysadmins, organizers, leaders, all waiting at the periphery for someone to invite them in and show them around.

4). These are good problems to have, because we absolutely can fix them.

We’re still doing great things. Plone is outstanding software, and is getting better with each release. We’ve got a good handle on the directions the product will take in the future.

But the problem is this: We’ve coasted on the idea that our community of contributors is so strong and have ignored the fact that it needs to be actively nurtured to remain so. We all need to feel ownership and responsibility for Plone again. We need to stand up to cheer and point out when somebody does something awesome. We need to make sure people who have an interest in contributing can quickly find a way to do so. We need to give people the information and resources they need to make the most of their contributions. We need to promote people who have shown drive and leadership into roles where they can be most effective.

So, here in year eleven of the project, what is the future of Plone? It’s you, it’s us, it’s saying “thank you” to everyone who got us through the first ten years, and it’s saying “We’ll take it from here”.

"You see, Open Source is all about the people. Really, on almost any project you would want to be a..."

Posted by Eric Steele on September 09, 2012 07:11 PM
“You see, Open Source is all about the people. Really, on almost any project you would want to be a part of, the code comes second. People are what distinguish a project that is a joy to work on from one that is a chore; people are what make the difference between a project that is flourishing and one that languishes in the bitbucket. Sure, you will only stay up all night coding on a project if it is solving a problem you think is important; but unless you have people with whom you can collaborate, discuss, design, and develop, you are probably going to lose interest or get stuck before too long.”

- Nóoirín Plunkett, Open Advice: People are Everything

A recipe for a nonprofit Plone site

Posted by Paul Roeland on August 31, 2012 07:13 PM

Since a bunch of people asked, here’s a description of the process leading to our new http://schonekleren.nl website. (Yes, the website is in Dutch, our curious grunting language, but it’s applicable to more…)

We started out with an old, crappy, user-hostile website. It was based on Joomla, customized to death, not upgradeable, and even posting a simple news item cost half an hour.

The choice for Plone was an easy one, as our intranet runs on it, and we have experience with it.

Getting old content out

transmogrifier to the rescue! We had about 1100 old articles, which we needed to save, if only to condense them into overviews. 

Now beware, transmogrifier is not for the faint-of-heart. It’s a powertool, with fast-moving sharp blades. You don’t need much knowledge of Plone, but a lot of generic sysadmin knowledge to make it work, and usually some dabbling in SQL. I’m a sysadmin so managed fine, but most nonprofits don’t have one. If you can, outsource this to your local friendly service provider.

Plone products used

The new site runs Plone 4.2, and the following add-ons. Quite a lot, but most of them are sort of necessary…

  • diazo. In our case, coupled with diazotheme.bootstrap. Yep, that’s twitter’s bootstrap, which does all kinds of dark css magic to keep it responsive and mostly working on IE. I don’t know a lot about CSS, so gladly tagged along with current best practice. It also leverages webcouturier.dropdownmenu
  • the usuals: PloneFormGen, collective.quickupload, wc.pageturner, collective.embedly to take the pain out of embedding media, and various fun portlets. Oh, and Doormat, obviously.
  • collective.easyslider. Great fun, and just needs some extra CSS which even I can provide to do fancy overlays for the front page.
  • ContentWellPortlets. Yes, Deco is just round the corner, but we needed a solution right now. And it does uninstall cleanly, so when Deco is around we can move on.
  • collective.megaphone for petitions.
  • pcommerce for our little webshop. For a small shop, this is all you need.
  • the brilliant eea.* set of products. eea.tags for sane tags, eea.facetednavigation for a nice interface to loads of docs.
  • icing on the cake: unweb.iptc to automagically extract tags from photos, collective.routes to do cool stuff with URL’s.

Pet peeves remaining:

  • Having to use collective.contentleadimage in this day and age is just a shame. It works, and works great. It is also needed. Try explaining to editors that NewsItems can have an image that shows up in content listings, but Pages can’t. You can’t and you shouldn’t have to.
    But there are inconsistencies with setting image sizes with the regular NewsItem. And customizing the NewsItem views is a royal pain in the lower backside.
    Really, ContentLeadImage functionality should so go into core. Like yesterday.
  • There is some confusion between new and old style Collections. Not all add-ons can use the new ones, and having both enabled confuses the editors. So down to the old ones for now. Hoping this will pass with time.

Big wins:

  • happy editors. Like, very happy editors. They now can update the site completely without technical assistance. This is a big win. A huge win. It means we can get back to our job, which is improving the lives of underpaid garment workers around the world. Not struggling with a CMS.
  • happy supporters. They like our site. A lot.

So, all in all, a succesful project, run on a budget of (ahum) 0 euros. 

Would I recommend this to other nonprofits? 

Well, first fight for more budget. You’ll get it done sooner, and better, with your local trusted Plone service provider. Doing the import of old content is definitely something you’re better off outsourcing.

But if push comes to shove, and you’re faced with the choice of having to stick with inferior CMS’s or move to Plone, it can be done on a budget.

Make sure your webteam collects all the happy reactions from users and editors, and use that as ammo to get more budget next year. Then you can hire more professional help, and get to do the fun stuff yourself. Like save the world. And the cheerleader (M/F).

I've finally done it...

Posted by Paul Roeland on June 21, 2012 05:03 PM

An improvement on the Long Island Ice Tea.

It tastes of grapefruit soda. Obviously, it contains neither grapefruit nor soda.

I call this the Polyester Pushover.
1 part vodka
1 part tequila
1 part white rum
1 part triple sec
1 part gin
1 part lemon juice
2/3 part Aperol
1/3 part Limoncello
Shake with ice, fill flute with icecubes, pour to half, top up with champagne.
Think of me in your final moment of bliss

Open source urbanism

Posted by Paul Roeland on May 21, 2012 02:12 PM
Open source urbanism:

Interesting read on how the cultural shift of social media can influence how our cities are shaped by the people living there

Plone for a film festival

Posted by Paul Roeland on March 02, 2012 10:37 AM

I help organize the Roze Filmdagen, the Amsterdam Gay & Lesbian Film Festival. 

For the website, we (obviously) use Plone, since I’m quite comfortable with that. And, sometimes, when you’ve struggled with more difficult Plone inner workings, it can be a refreshing experience to relive why this is such a great piece of software. Yes, it can be tricky if you try to do complicated stuff with it. It’s a powertool, so it can hurt your fingers. But my oh my, is it quick to get the job done!

Setting up the site was a joy, and gave us many things for free: an automatic Ical-compatible feed of all screenings for people with smartphones; the ability to view the program in many ways using tags and topics; this way, visitors can easily find the kind of films that they are interested in in the mass of 110 different screenings.

For those interested: the site runs on Plone 4.1.3, with the following add-ons:

  • layout based on v2.theme (rather modified)
  • Products.Doormat (modified to serve as navigation, rather than ‘doormat’
  • Products.PloneFormGen
  • collective.contentLeadImage
  • collective.plonetruegallery
  • collective.portlet.banners
  • fourdigits.portlet.twitter
  • collective.portlet.relateditems

and some extras to make life easier for the editors, like collective,quickupload.

It runs on a modest server, with nginx as webserver and varnish as proxy, and can easily cope with a few thousand visitors a day. 

All in all, a pleasant experience, and running nicely. Thank you Plone!