NobleQuotes.com is a website that provides a collection of famous quotations from popular personalities. The features of this website are:
- Users can read quotes from famous authors.
- Quotes can be browsed by authors and topics.
- Users can collect the quotes they like.
- Users can rate the quotes, top rated quotes are shown first.
Other features of this site include:
- Good User Experience (thanks to Drupal)
- Clean and Responsive Design
- The website works well on all devices
- No annoying Advertisements
Performance is crucial for providing a great user experience. If the site is slow or balky, even great functionality won’t keep the site visitor engaged.
You have launched a commerce site. Congratulations ! You're awesome ! But what do you do next ?
In this blog post, I will go through a topic that will help you learn how people use your system. Even though I focus on eCommerce, the same principles apply to any other website.
Below, you can find an extract from the Wundertalk segment that I recently did and it explains the matter at hand. As the title says, it's 11mins long.
Also, the presentation is attached ( in PDF format) so you can freely enjoy the code displayed above.
Happy tracking !
When you're building a Drupal website it is important to organize your code. Each developer or company has it's own way of organizing modules structure. In this blog post I will show the way I organize my code and directory structure.
PreviousNext: Drupal South Presentation: Everything you wanted to know about Drupal 8 but were too afraid to ask
On Saturday morning at DrupalSouth, Kim Pepper and I presented Everything you wanted to know about Drupal 8 but were too afraid to ask.
We've been asked to present it again online for Jam's Drupal Camp but in the meantime, here's the slides
In my recent appearance on the DrupalEasy podcast I mentioned that I was aiming to have Metatag 1.0 ready by the end of February. Next week is the end of February and, being honest, I haven't really touched it since releasing 1.0-beta9 on Drupal's birthday, January 19th last. I felt it best to explain where my contrib efforts have been lately and explain why I'm not making my goal.Tags:
This week (fortnight) saw the release of Drupal 8 alpha 9. Each release brings us that little bit closer to a beta. Some of the highlights from this fortnight include:
- Remove all Simpletest overrides and rely on native multi-site functionality instead - issue 2171683. With this, each test run creates its own site inside sites/simpletest - eg sites/simpletest/13455678 - with its own settings.php and some apache files for security sake. This means that our testing is running in a real site, instead of a psuedo site with overloaded globals and various other workarounds.
And speaking of change records, just a reminder to check your patches for API changes and be sure to write your change record, these are now required before the issue is committed.Where's Drupal 8 at in terms of release?
Each week, we check with core maintainers and contributors for the "extra critical" criticals that are blocking other work. These issues are often tough problems with a long history. If you're familiar with the problem space of one of these issues and have the time to dig in, help drive it forward by reviewing, improving, and testing its patch, and by making sure the issue's summary is up to date and any API changes are documented with a draft change record.
- #2198429: Remove deleted fields concept blocks critical work on dependency management and configuration synchronization. If you have expertise on the configurable field system, the configuration system, the batch API, or large deployments and data deletions in general, please weigh in on this issue.
- #2114707: Allow per-bundle overrides of field definitions This is a current key blocker for entity API work, and needs review.
- Anything that helps us unblock testbot testing on php 5.4 -- see this issue list of php-fpm issues.
- If you use PostgreSQL, please help with #2157455: [Meta] Make Drupal 8 work with PostgreSQL. These issues are critical to make Drupal 8 shippable for postgres, and they block adding automated test coverage on postgres that will help prevent further regressions.
- #1938068: [Meta] Convert UnitTestBase to PHPUnit. These issues are a great chance to familiarize yourself with PHPUnit and make Drupal 8's test suite cleaner and faster. Help with reviews on the child issues!
- We REALLY need documentation help for the Block API.
- As always, if you're new to contributing to core, check out Core contribution mentoring hours. Twice per week, you can log into IRC and helpful Drupal core mentors will get you set up with answers to any of your questions, plus provide some useful issues to work on.
The best of git log --since=2014-02-09 --pretty=oneline (159 commits in total):
- Issue #2171683 by sun, tstoeckler, larowlan: Remove all Simpletest overrides and rely on native multi-site functionality instead.
- Issue #2147153 by dawehner, alexpott, Xano: Replace the last instance of $_GET/$_POST; Create a special exception listener / exception controller which allows to use POST requests - brings us closer to complete use of the Symfony Request instead of Super globals.
- Issue #2188595 by alexpott, jibran: Create a ConfigManager to be able to remove config.inc - one less inc file..
- Issue #2190643 by Berdir, amateescu, Xano, yched: Serializing the container is a very very bad idea, let's prevent it?.
- Issue #2176065 by EclipseGc: Introduce a composer.json for Drupal\Component\Utility. Drupal being a good PHP Citizen.
- Issue #2028025 by David Hernández, Berdir, larowlan, ceng, YesCT, a_thakur: Expand CommentInterface to provide methods - provides a much better DX
- Issue #2193521 by sun, alexpott: Simpletest suffixes are not guaranteed to be unique. Finally, all those annoying "base table or view not found" random testbot failures will go away.
You can also always check the Change records for Drupal core for the full list of Drupal 8 API changes from Drupal 7.Drupal 8 Around the Interwebs
Blog posts about Drupal 8 and how much it's going to rock your face.
- Lets get frozen by Ian Thomas on the future of our legacy apis.
- A nice Drupalize.me podcast on setting up Restful views in Drupal 8
- A summary of what Drupal 8 holds for CiviCrm integration from The CiviCrm blog
- A call to action to help us modernize testbot, relates to Drupal 8 because we need a modern testbot to enable php 5.4
- A great piece on creating a Drupal 8 theme by Appnovation Technologies
- DrupalEasy podcast 123: It's got Berdir. YesCT and alexpott talk with the DrupalEasy folks about how they're funding their work on Drupal 8 through the community.
- Feb. 28 - Mar 2: Two events happening simultaneously, DrupalCamp Phoenix and DrupalCamp London have some nice Drupal 8 session proposals, including CMI, multilingual, and more!
- March 8-9:Florida Drupal camp is aiming to shine a spotlight on Drupal 8. Including several sessions on Drupal 8 and a Drupal 8 code sprint, should be lots of fun in a sunny location.
- Mar. 24 - 30: Drupal Developer Days Szeged is going to be the Drupal 8 event of the next months, with a full week of sprinting awesomeness and lots of D8 content. See Five good reasons to register for Drupal Dev Days Szeged now by Gábor Hojtsy for more details.
- Mar. 28 - 30: If you'd like to collaborate with DevDays Szeged sprinters, but are looking for something in the western hemisphere, check out MidCamp. MidCamp is March 28-30, and there may also be a pre-sprint March 26-27. Contact ZenDoodles for more information.
Do you follow Drupal Planet with devotion, or keep a close eye on the Drupal event calendar, or git pull origin 8.x every morning without fail before your coffee? We're looking for more contributors to help compile these posts. You could either take a few hours once every six weeks or so to put together a whole post, or help with one section more regularly. Contact xjm if you'd like to help communicate all the interesting happenings in Drupal 8!
For Toadcast 21 we interview the man, the legend, Jonathan Jordan. For our 21st we did what any good podcast would do, we celebrated with a drinking game. Hear all the great questions and answers by listening!
Drupal once again has a one-two punch presence at SCALE, the Southern California Linux Expo, this year at the Hilton LAX with both a Drupal booth and a Droplabs booth. The expo floor, which is packed with thousands of conference-goers and dozens of exhibitors with interests in all things open source, opens tomorrow, Saturday, February 22nd, and is open until end of day on Sunday, February 23rd.
Droplabs is also a SCALE media sponsor of the expo this year and will have a session on Friday, February 21st about its open source business model and how Droplabs grew to become the world's Top Drupal Location, as recognized by Drupical last year.
If you want to learn more and talk shop about Drupal, head over to the Drupal booth on either Saturday or Sunday and talk with the awesome volunteers there. While you're there, be sure to sign up for GLADCamp, the Greater Los Angeles Drupal Camp, a free conference for All Things Drupal that's fast approaching on March 7th, 8th & 9th, in Pasadena, California!
If you're looking for a meetup venue for Drupal and other open source topics, head over to the Droplabs booth to learn how you can have your event hosted for free. You can also ask Droplabs about how to get unlimited access to the Drupal video learning sites that Droplabs has site licenses for (BuildAModule, OSTraining and Drupalize.me).
Both booths need help with volunteers and those volunteers may be able to attend the expo for free. Check with the booth managers for more information. For Droplabs, get in touch at https://droplabs.net/contact and for the Drupal booth, see https://groups.drupal.org/node/401543
See you at SCALE!Tags: SCALEPlanet Drupal
The reason DrupalCon is such an amazing event is the people. When you gather a large group of people together, it creates an awesome energy. Unfortunately, it also creates an impact on the environment.
We are heading towards the first Drupal 8 beta and there are several opportunities to help fix your pet peeves, help round out the Drupal 8 Multilingual features and just explore what is there and find and reproduce bugs if you are not that deep into development even. The following events host sprints where well known names of some of the Drupal 8 Multilingual team will be present. Meet and join us there to help get Drupal 8 to release sooner!
While developing Drupal websites, I have been faced with the problem of adding custom contextual links to different elements like: taxonomy terms displayed as rendered entities, blocks created with Ctools plugins, custom blocks and other.
Contextual links are links attached to elements such as nodes, blocks, views displays and others. When you hover on a specific region, a gear image appears. Upon clicking it, the image shows the list of contextual links. You can see an example below.
Some modules provide contextual links that allow users to edit views, nodes, taxonomies and other elements, but there are situations when contextual links need to be created in a custom implementation.
Add a Custom Contextual Link to the Taxonomy Term View
In my case, I have a view that shows Taxonomy terms from the Service Category vocabulary as Rendered entities, without fields.
For each term, a contextual link should be added to the page where the term information can be edited, and the link would allow privileged users access to that page. This task can be accomplished using template_preprocess_taxonomy_term() to edit variables that will be used in the template file (taxonomy-term.tpl.php or taxonomy-term--service_category.tpl.php) and hook_contextual_links_view_alter(). In the preprocess function, the contextual link element can be added in the $title_suffix array.
In hook_contextual_links_view_alter() are the altered contextual links elements before they are rendered. In this case, a new link is added.
An important thing is that a class should be added for the region wrapper that includes contextual links. This class is contextual-links-region, and it makes it possible to show the contextual links region when you hover on the gear icon.
As a result, the taxonomy term entities will be displayed with a contextual link that will allow users that have administer taxonomy permission to access the term edit page.
Custom Contextual Links as Render Elements
Contextual links can be added to elements like blocks using a renderable array. For example:
Theme function in the example is used to add a template where the wrapper with the contextual-links-region class will be added:
And the content of the template file:
Finally, the result will be a block in which content is wrapped with a contextual link region. Clicking on the gear icon will display the link to the vocabulary edit page.
You can find more info here: https://drupal.org/documentation/modules/contextual . Please post any comments below. And make sure to subscribe to our mailing list to receive our blog feed.
Tags: DrupalDevelopmentcontextual linksCheck this option to include this post in Planet Drupal aggregator: planetTopics: Tech & Development
Today, the web is not just about publishing content anymore. As the web evolves from content management to digital experience management, it's about understanding visitors' interests and preferences, and figuring out how to deliver them an optimal personalized experience. Many organizations are exploring ways to more effectively create and deliver valuable content to site visitors to increase traffic, conversions and revenue. Great content is still gold, but delivering the right content to the right user at the right moment in the right format is platinum.
Today's personalization tools aren't great and put marketers at a disadvantage. This is why I'm excited to announce that we're rolling out Acquia Lift, a solution
that equips the site owners with powerful website testing and content targeting tools to optimize content for each visitor. Acquia Lift learns about a visitor's interests and, based on these insights, uses machine learning algorithms to automate the delivery of personalized content. Marketers and site builders can test content, for example using A/B or multivariate testing, and even add rules about the types of user profiles that get specific content. There is implicit learning that takes place as well that continuously helps Acquia Lift provide increasingly more appropriate content to individuals. Attributes of the user, such as location, and even what the current weather is, can be taken into account in providing the right content. Check out this short Acquia Lift video if you want to learn more or see Acquia Lift in action:
As I talked and wrote about earlier, I believe personalization and contextualization will be a critical building block of the future of the web, and I'm excited to help make that a reality.
Features play a significant role in any major Drupal 6 or 7 project. The organization of features is often overlooked, but becomes important as a project grows. Agreeing on an effective organization strategy avoids headaches and reduces merge conflicts. After experiencing just about every strategy on projects of all sizes, we’d love to share what works best for us.Why is feature organization significant?
The Features project page defines a feature as a collection of reusable components. After all, a feature is a module. A majority of features, however, are only created to get configuration into code. This is understandable, but it remains important to build each feature with a modular approach. It doesn’t matter if there is any intention to reuse them on another project.
What does the opposite approach look like? One feature for each category of component: a Content Types feature, a Views feature, a Strongarm feature, and so on. A developer can update every feature after each round of development and commit their work. Life is good.
This approach becomes a problem as more developers join a project. Each developer can be working on a separate section of the site, but they all must push their Views and Content Types to the same features. Nasty merge conflicts surface. Spider webs of interdependency between features form. A few always report as Overridden no matter how many times they’re updated. Not to mention, the Content Types feature is now huge and that page takes five minutes to load before anything can be added to it.
There has to be a better way.Creating modular features: how and why?
This may create a larger number of smaller modules, but the tradeoff in maintainability is worth it. Dodging merge conflicts and unmanageable interdependencies is a huge benefit. So is the next developer knowing where to find the preprocess function that alters the Article’s teaser view mode. More on that later.One size never fits all
What if more than one feature uses a single image style, view, or bit of custom code? Don’t just pick one feature to add it in. Don’t copy and paste the custom code across both. Instead, try creating a separate, shared feature and list it as a dependency by those that use it.
Some components just don’t belong in the modular features we’ve described above. Menus, menu items, user roles, permissions (debatable), and text/date formats are good examples. Creating one or more site-wide features for these elements can prevent a lot of confusion. Custom code used by most features belongs here as well.
We also like creating a custom Developer feature to store all development-related configuration. All modules that are never enabled on production get listed as a dependency on the Developer feature. This includes modules like Views UI, Fields UI, and Devel. A development environment is ready to go after enabling one module and production stays lean.A feature is just another custom module
This is less important, but a debatable topic is where to keep features within the modules folder structure. A common approach is to have three directories: contrib, custom, and features. We tend to combine the latter two. A custom module can become a feature with one line of code and with so much custom code in our features, we see little reason to separate them.
Another quick lesson to learn is to add a prefix to all feature names. Find initials or a short version of your site’s name and add it to the module’s machine (xyz_news) and readable (XYZ News) names. This will avoid conflicts with any contrib modules that have the same name.
Finally, no approach will be successful without developers paying attention when updating features. Features is usually aware of what shouldn’t get added, but it isn’t unusual for something to sneak in where it doesn’t belong. To combat this when staging commits, we use a git GUI like Tower or git add -p when working from the command line. This requires deciphering features code, but blind commits can unwind any organization in seconds.Features: A necessary evil
Drupal 8’s configuration management system will replace the need to export configuration with Features. Until then, Features is a necessary evil and staying organized can help developers stay sane. The organization strategy and other ideas we’ve shared value modularity and avoid merge conflicts. We were fortunate to learn many of these ideas while working with the wonderful folks at Lullabot. We’d love to hear about strategies you’ve found success with or any ideas to improve ours!
Measuring return on investment (ROI) for business expenses is important. Understandably, most people want to understand the ROI of something before they make the investment. Calculating the value of attending DrupalCon is pretty simple when you think about it in terms of the informative sessions, training opportunities and business relationships gained and nurtured.
My name is Leigh Carver (leighc), and I’m the new Content Writer for the Drupal Association. It’s going to be my job to help make sure our communications are consistent, interesting and valuable, and to help populate Drupal.org and our social media channels with informative content that helps Drupalers at every point in their Drupal journey.
Back in July last year, the Drupal 8 API froze. Except it didn’t. It couldn’t – Drupal 8 wasn’t anywhere near ready enough. We still had thousands of lines of code that needed bringing up to the new standards and parts of the new API that still needed to be completed. To me, what the code freeze really meant was: stop breaking things, stop adding new features, and start concentrating on getting Drupal 8 ready to ship.
As we approach the first beta, core’s need for this backwards-compatibility code is reducing, as seen by the recent removal of variable_get() and friends. But we’re also moving closer to the point where the API needs to be properly frozen, so that contrib modules don’t get caught out by functions suddenly disappearing. Some functions were marked @deprecated, but there was confusion about whether these functions would be shipped with Drupal 8.What are we’re doing now?
Issue #2187735 has recently been committed, which should clear up much of the confusion about @deprecated: the documentation for these functions will now typically say “@deprecated in Drupal 8.x-dev, will be removed before Drupal 8.0.”
If you’re using any of these functions in your Drupal 8 code, then now is the time to update them. Ideally your code will be object-orientated and most of these function calls can be replaced with method calls on the relevant services, see Services and dependency injection in Drupal 8. If that’s too much work, then there’s often a method on the global \Drupal class that you can use as a drop-in replacement (but without the benefits of OO).How can I help?
Anyone developing with Drupal 8 should keep an eye out for procedural functions being called when reviewing patches – most of these functions now have OO replacements, often via the \Drupal class. If you’re using an IDE it may highlight deprecated functions, for example by striking a line through the function name.
If you’re already a core developer, please have a look over the APIs that are documented as @deprecated. Are any missing? Please file new issues using the issue tag @deprecated, or we may be forced into shipping with them. Have we marked any APIs “will be removed before Drupal 8.0″ that we actually want to ship with? Please open an issue and explain why.
If you’re interested in getting into core development, there are lots of issues to update core from the old APIs to the new, some of which are great first issues. These will usually have the @deprecated issue tag, and the issue title will often start “Remove” or “Replace”. Come along to a core mentoring session on irc or see if there’s a meet up happening near you soon.
If you’re happier developing in contrib, there’ll be a lot of work needed to upgrade contrib modules to use the new APIs. If you use any modules that already have a Drupal 8 version, check to see if they are using any of the deprecated API. If they are, open an issue and/or submit a patch, ideally before the API gets removed.
Whether you are just moving to Drupal or upgrading to a new version of Drupal, if you are starting with an existing website, you are facing the same problem: Your migration timeline. It will take you significant effort to move everything you have to the new system and you cannot play catch-up all the time. That’s why many people are opting for continuous migration. What does that mean? Run the migration project in parallel to your existing website effort and migrate gradually, page by page and URL by URL.
Alex Pott (alexpott), Cathy Theys (YesCT), and Jozef Toth (mogdesign) join Ted Bowman and Mike Anello to solve all of the Drupal’s community funding problems - or at least to dream about a solution. Alex is one of the Drupal 8 core committers and has successfully used Gittip and other means to be able to raise enough money to work on Drupal 8 full-time. Cathy has successfully found multiple sponsors to support her work in the community (mainly on Drupal 8) and Jozef is co-founder of Drupalfund, a web site where Drupal developers can post projects and request sponsors (think Kickstarter for Drupal). As if that wasn’t enough, we also have picks of the week (including a pick-of-the-week cage match between Ted and Mike) and our 5 (more like 11) questions.
Going to SxSw? Check out my earlier post about my Advanced Drupal Development workshop.
Also check out a few other Drupal offerings while you're there.
And don't forget Acquia's list of SxSw events which also includes a couple parties!Day Time Session Presenter(s) Friday 11:00 - 1:30 Scaling at Twitter with Drupal & Thrift Arnaud Meunier
Saturday 11:00 - 12:00 The Hacker & The Hustler: Coding a Great Company Dries Buytaert
Tom Erickson Sunday 3:30 - 6:00 Advanced Drupal Development DougVann Drupal Planet