Programming
Programming items
-
-
Improving ‘time to first load’ and generating critical CSS for Drupal and WordPress sites
This document is a work in progress…. One thing that we want to fix is ‘time to first load’. As you probably know, people are recommending to put as little in the way of initial loading as possible, and zero external requests. This means no blocking JS in head, and as little CSS as possible, […]
Read more » -
Searching for large files on your server
Here’s a command that will check the root / folder recursively for files greater than or equal to 1GB and sort the list. cd / ; du -h | grep ‘^[0-9]\+\.\?[0-9]\?G’ 2>/dev/null | sort -nrk 1 Thanks to Phil from WiredTree for sharing that info, I’m just putting it down here so I can remember […]
Read more » -
Redirect rules to change underscore to hyphen
Unfortunately Apache redirect only allows for 9 placeholders, so that’s the maximum amount of undercore changes that this code allows. We are using this mainly within WordPress sites, so here is the entire wp htaccess file, so you know where to position the code. # BEGIN WordPress RewriteEngine On RewriteBase / # BEGIN underscore to […]
Read more » -
Show all Draft Posts Plugin for WordPress MU
This plugin will show the draft posts created in all your WPMU blogs. To activate, just download the PHP file and put it in your wp-content/mu-plugins folder. The file can be downloaded here…. To view all posts, click on ‘Site Admin’ and then on the ‘Posts for moderation’ submenu. To do: make ‘view’ and ‘edit’ […]
Read more » -
Archetypes and ATContentTypes, part 2: Templates and customization slots
We will now look at how these schemas are called by the edit templates, and point out slots and hooks which Archetypes have left for customization. Let us return to our Image type: selecting this type in portal_types and looking at properties will show that atct_edit is the default editing form, as it is for […]
Read more » -
Archetypes and ATContentTypes, part 1: The Archetype Schema
All the default types in Plone – file, image, folder – are part of the ATContentTypes product, and are examples of archetypes. Archetypes were integrated into Plone 2.1, and allow you to create content types easily by providing a range of readymade tools so you can generate edit forms without using any HTML. An example […]
Read more » -
More unearthed tips….
Again from my email clear out, I have found a few more tips, this time suggested by Priyadarshan….. Drag and drop item reordering in Plone 2.5 You can just reorder the order items have in a folder just by dragging and dropping them around. This is of course of great usefulness, since the order in […]
Read more » -
Lisp and dinosaurs
I really like Philip Greenspun’s contributions to the developer’s community and Internet world at large. His posts are usually witty and have about them a sharp vision that is quite rare to find. Here is a post I liked about LISP. It is not really concerning Plone, but I think it concerns us as seekers […]
Read more »
