In-depth insights on content, code, and creativity
A couple of months ago we made the decision to stop using mysql-mmm on one of our client sites. We had been burned by a couple of incidents where automatic failover had caused more problems than we had imagined it would solve. Data ended up being written to the wrong server a few times, causing a bit of a nightmare to merge the forked database after the fact. Although we had other concerns about mysql-mmm, a major factor in our decision was our assessment that in our specific case of assigning MySQL master-slave IP addresses, human-triggered manual failover was essentially as good as automatic failover, and carried much less unexpected risks.
On Thursday, October 25 at 9am PT / 12pm ET, the eZ Publish Americas community will be hosting two presentations: an introduction to eZ Publish 5 and Symfony; and a comparison between eZ Publish and Drupal. This is the second episode of a regular presentation series, and one of several initiatives of the community.
There a few cases when you want to trigger a re-index parts of your site; for example, you might make an existing attribute searchable or you might change some index boosting settings. However, default eZ Publish indexing tools only allow you to re-index the entire site. This is not particularly efficient if you have a very large site and/or if you're just trying to test a small change in your development environment. Here are a couple of tools that you can use to re-index specific parts of a site.
The object relations datatype is one of the most powerful datatypes in eZ Publish. In some cases, it is useful to associate data not to either of the objects involved in the relation, but to the relation itself. For example, you might want to mark a person as an author on one book, a contributor on another book, and an editor on another book, all while maintaining only one record for that author. Mugo has created an extension to add cross-reference data to object relations.
Many weather sites offer embeddable widgets to display weather forecasts on your website. However, if you want to customize the look of the widget, your options are usually quite limited. Weather Underground far surpasses the rest of the options by providing a JSON-based API so that you can use their data to build and style your own widgets.
Recently, eZ Systems announced that the next major version of eZ Publish will use the Symfony framework. Having heard good things about Symfony as a modern, robust web framework, I am pretty excited at the announcement, and have already dived in to the new eZ Publish 5 code.
Image aliases are used in eZ Publish to define image sizes and other image variations. As an example, this allows for the editor to upload an image once and have it automatically formatted for a thumbnail display, a full size display, and more. By default, image alias files are automatically created whenever they are displayed in a template. However, you might have other use cases whereby you need to generate image alias files outside of the default scenario (for example, for an external site or feed).
Varnish Cache is a powerful website caching system that dramatically increases your site's performance. It does so by sitting in front of your Apache, PHP, content management system, and database stack in order to cache your web pages and serve repeat requests. This saves the back-end stack from consuming unnecessary resources to generate the same pages over and over again. Mugo Web has implemented Varnish in front of eZ Publish for several client websites. Although every client has different needs, we've come up with an outline of tips and considerations that are common across most implementations.
One of our clients recently needed to apply a custom frame / border to all images in a certain section of an eZ Publish site. One way to do this is to edit each image in Photoshop or GIMP, but this can be a time-intensive, manual process. Another is to use CSS, but this again takes time and is also more limited. A flexible and automated way to do this is to configure ImageMagick filters in an eZ Publish image alias. The required style would then be applied to all relevant images.
There are many variations to social media strategies to suit particular client sites and goals. Some implementation details, on the other hand, are universally applicable. One such detail is a Twitter feature whereby a user is prompted to follow your Twitter account whenever they share your content.
Sitemaps are an important element of search engine optimization (SEO), in order to provide search engines an accurate outline of what content exists on your site. One of our client sites recently outgrew Google's sitemap URL limit. Instead of removing content from the sitemap, we implemented a simple solution of using a sitemap index to reference multiple sitemap files.
One of our favourite projects, The 49th Shelf, aggregates a lot of data from a diversity of sources. Naturally, there is a range of quality; but even more than that: different sources often refer to the same physical object in different ways. Specifically, a person who writes several books can be referred to in a variety of ways:
There are some heuristics to resolve most of these cases, but there are always seem to be some that defy the code and require a manual fix.
This process has to be performed on the production site, so we want to minimize the amount of time that the data is inconsistent and we don't want to run untested code.
Approval workflows of various types are required across the web. Whether for legal review, cross-channel media review, or purely editorial review, approval workflows are essential to define and support content publication. Based on our experience with clients in many industries, Mugo Web has developed an eZ Market extension eZ Collaboration Workflow to be a complete workflow solution.
For many media sites, news changes fast, and the timely updating of content is key. Landing pages are the main information funnel, and it is important for editors to be able to update the content shown on landing pages as easily as possible. Where relevant, content should also update itself. The Rasmussen Reports Election 2012 page is one such example, where we've empowered editors to make content and layout changes in a graphical user interface, without having to contact a web developer. In this article, we will show you how various areas of the Election 2012 page are updated using the eZ Flow extension for eZ Publish.
Mugo has a tool that we use internally to help with the main aspects of a developer's life: development, debugging and maintenance. The tool is called "eep", short for "Ease eZ Publish". It's a command line tool which provides many functions and allows for accomplishing tasks quickly by integrating with tools like awk, grep and xargs for powerful one-liners and supports rapid development of powerful bash scripts by leveraging eep as a library of eZ Publish specific operations.
By default, 2 instances of eZ Find can not run at the same IP address because eZ Find and Solr communicate with each other via an IP port. This becomes an issue if you happen to run a staging instance on the same server as a production instance, or on your local dev machine where there are many sites running.
A nice solution makes use of the symlinking trick for managing platform-specific versions of settings files I recently documented.
A common feature need on eZ Publish installations is to have more specific validation on Text Line attributes: if you want to force a field to be in a valid postal code format for example, you have to write a specific datatype for it, or you have to override a template to perform client-side validation only. The Mugo Validated String extension provides a framework around a "Text line (validated)" datatype, where the validation method can be selected via a dropdown list, and developers can quickly create new validation types with a few lines of code. In this post, we explain the extension, as well as how we ported the feature to be used with eZ Survey via the Mugo Survey Addons extension.
Since the beginning of 2012, for one of our clients with a big news website, we recognized a drastic increase in website traffic without an accompanying increase in ad impressions. Under normal conditions, an increase in traffic would be a positive sign; however, in this case it was caused by end user software that turned normal web users into aggressive web crawlers. This essentially created an accidental but consistent distributed DoS (denial of service) attack.
Here, we explain how we identified the cause and mitigated its effects.
Recently, we built a map interface for The 49th Shelf's Read Local: The 100-Mile Book Diet website project using the Google Maps API. The website is an online book community focused on Canadian books. Users can visit the map section to find Canadian books by geographic location, and they can also pin books on the map, selecting locations that are meaningful to the books in some way.
Allowing anybody to participate in the evolution of the Read Local map means that we have to pay particular attention to the "Add a Book" user experience. If the user experience is intuitive and pleasant, people will be much more willing (and able) to pin a book and help make the map more useful and fun. On the other hand, a confusing interface can hamper the accuracy of the pin data (in the case where books are pinned in the wrong location) and turn people off from participating.
Here's a look at two main considerations regarding user interface design and optimization in the "Add a Book" workflow.
In almost every project we have a small number of settings files that have important differences on the production host versus development or staging hosts. This problem is made serious when the settings are in your version control system.
The resolution is trivial: Create a version of each file for each context that needs to be customized, eg site.ini.append.php_PRODUCTION, put this in SVN, and create a symlink with the name that eZ Publish is looking for.
Extensibility in eZ Publish is key, down to its object edit interface. This post explains a couple of the lesser documented edit features that you can extend: using browse mode in a custom datatype, and using a custom edit handler to add an edit action.
If you've ever had a hard time finding certain content objects in your eZ Publish installation, just because browsing was a pain, then this extension is for you! The Mugo Content Class Manager helps you look through all content objects using the content class of the objects, not their location in the content tree.
This means that if you need to look through, say, the latest 10 articles on your eZ Publish system regardless of their location, you can easily do that using the new Mugo Content Class Manager. Do you need to find a blog post with a specific title and you`re not sure which folder it`s in ? Just list all blog posts and sort them by name in the Mugo Content Class Manager. This blog post talks about the Mugo Content Class Manager extension and how you can install it and use it on your eZ Publish system.
A common task in website search engine optimization is to set up Google Webmaster Tools and go through its HTML suggestions. Many of the suggestions center around duplicate content -- pages at different URLs but that have the same HTML title, meta description, body content, and more. This post summarizes a couple of common duplicate content scenarios within an eZ Publish site, and how to solve them.
Many hosting companies will take care of file system and database backups for you. We have a few clients where we have file system backups configured, but database backups have to be handled manually, since the database is "live data". Often we can just configure a cronjob that runs mysqldump so that a database snapshot is stored to a file and thus regularly backed up when the file system backup is run. However, sometimes you have a perfect storm where mysqldump is too heavy for the server (causing severe slowdowns or even crashing some services), even if run in the least intensive way (such as with the --quick flag) and at a low traffic time: partially due to lack of system resources and a large database.