June 28, 2012 - Comments Off on Drupal 7 Commerce Coupons: Unlimited redemptions

Drupal 7 Commerce Coupons: Unlimited redemptions

The Commerce module and its add-ons are very powerful. The coupon module has recently undergone a major rewrite and its one we're using for one of our sites. In this post we'll talk about making a modification to one of the coupon rules to allow for unlimited coupon redemptions if you enter '0' (zero) in the Number of uses field when editing a coupon.

In Workflow > Rules edit the rule Coupon Validation: Check the number of redemptions.
Add an AND condition
Then, add a Data Comparison condition
For the data to compare choose: coupon:commerce-coupon-number-of-uses
Choose the equals operator, and 0 as the value.
Next, we want to negate this condition. See the post on Drupal Rule(s)! for an explanation of this option.
Lastly, save the new condition and drag it and the Entity has field condition under the And operator.

Coupon conditions

Coupon conditions

That's it. Now you can redeem a coupon as many times as you want.

Drupal's well thought-out and structured framework allows for changes to functionality to be done at a high level instead of always needing to dig into code and/or write Tarzan-like, custom PHP. This in turn, saves other developers and designers a lot of time. Thanks Drupal!

Links:

Published by: chazcheadle in The Programming Mechanism
Tags: , ,

June 26, 2012 - Comments Off on Drush de Jour: Painless database backups for your Drupal site

Drush de Jour: Painless database backups for your Drupal site

Proceed directly to drush.
Do not pass Go.
Do not enter your site name.

When you first set up your Drupal site- install drush, the command line shell for Drupal. With drush, you can backup your db, create users, reset passwords, re-index search, start/stop migration, check logs, etc. etc. etc.

From the root of your Drupal install: (e.g., /var/www/<sitename>).

% drush archive-backup --destination=sitebackup.sql

That's it. Your entire drupal database is written to a file.

% drush sql-dump > sitebackup.sql

This method uses drush's Mysql command line interface to do a mysqldump of the site database

And if you want to be stubborn and not install drush:

mysqldump -u -p <sitedatabase> > sitebackup.sql

Links

The Drush de Jour brings you the latest and possibly greatest bits of drush wisdom we use for developing and maintaining our Drupal sites.

Published by: chazcheadle in The Programming Mechanism
Tags: , ,

June 25, 2012 - Comments Off on Mouths of Marrow

Mouths of Marrow

 Fitness Tips To Help You See Impressive Results

MARCH 23, 2020

Being fit has many physical and mental benefits for your health. However, many people may not understand what it fully requires to fully reach their goals. Follow these 5 fitness tips to help you see impressive results. Read more about profit singularity ultra edition.

1. Stay Consistent

Consistency will lead you on the road to success the quickest. It doesn’t matter what your goals are. If you have consistency and develop a routine that you know that you can rely on, it will lead to you reaching your goals quicker.

For example, if you want to lose weight, you should be consistent in your cardio exercise regimen. This consistency cannot just stop at your physical exercise, though. This consistency has to extend into another important part of your routine, which is your diet.

2. Watch Your Diet

Maintain a good diet to reach your fitness goals.

Many people only focus on the gym and exercise component of attaining fitness goals. As mentioned before, your diet is one of the most important parts of your fitness regimen, but having a great diet, regardless of your fitness goals, will impact whether or not you are successful in your goals as much or more than actual exercise. This is because your body will reflect what you eat and your diet can either progress your goals further or set you back.

It may be helpful for you to keep a log of what you eat and determine which foods you need to eliminate and which foods you need to add. In addition, you also want to be mindful of when you are eating, because it can also affect your performance in the gym.

For those who are bodybuilding or looking to build muscle, it’s recommended to incorporate some kind of carbohydrates before a workout session, and then have a protein-heavy meal once you are finished to speed up the recovery process. Protein shakes are a popular commodity in this regard. However, different protein powders can have different vitamins, minerals, and ingredients that can be more effective for men or women.

Ladies can check out a variety of protein powders to see what’s available for their needs. There tend to be more protein powders available for men that already have the extra minerals and vitamins included to help them get gains. So when guys are searching for the best protein powder, it’s better to decide if they’re trying to get lean or gain weight.

3. Have Realistic Expectations

Having the right mindset is imperative to achieve the fitness goals of any kind, and it starts by having realistic expectations. If you don’t like what you see in the mirror, then you have to work hard to see a change. However, if you are looking to shed some pounds and reduce your waistline, you can’t expect it to be done within a week.

Realistic expectations directly correlate with being consistent. Gaining weight means you will need to take the time to increase the amount of food in your diet and the number of weight-bearing activities that you engage in.

Losing weight will take a gradual amount of time with you engaging in vigorous cardio and making healthy choices. Your body cannot adapt to the changes that you plan to make overnight.

Published by: benchirlin in The Internal Mechanism
Tags: , ,

June 21, 2012 - Comments Off on Drupal Rule(s)!

Drupal Rule(s)!

 Fitness Tips To Help You See Impressive Results

MARCH 23, 2020

Being fit has many physical and mental benefits for your health. However, many people may not understand what it fully requires to fully reach their goals. Follow these 5 fitness tips to help you see impressive results. Check these profit singularity reviews.

1. Stay Consistent

Consistency will lead you on the road to success the quickest. It doesn’t matter what your goals are. If you have consistency and develop a routine that you know that you can rely on, it will lead to you reaching your goals quicker.

For example, if you want to lose weight, you should be consistent in your cardio exercise regimen. This consistency cannot just stop at your physical exercise, though. This consistency has to extend into another important part of your routine, which is your diet.

2. Watch Your Diet

Maintain a good diet to reach your fitness goals.

Many people only focus on the gym and exercise component of attaining fitness goals. As mentioned before, your diet is one of the most important parts of your fitness regimen, but having a great diet, regardless of your fitness goals, will impact whether or not you are successful in your goals as much or more than actual exercise. This is because your body will reflect what you eat and your diet can either progress your goals further or set you back.

It may be helpful for you to keep a log of what you eat and determine which foods you need to eliminate and which foods you need to add. In addition, you also want to be mindful of when you are eating, because it can also affect your performance in the gym.

For those who are bodybuilding or looking to build muscle, it’s recommended to incorporate some kind of carbohydrates before a workout session, and then have a protein-heavy meal once you are finished to speed up the recovery process. Protein shakes are a popular commodity in this regard. However, different protein powders can have different vitamins, minerals, and ingredients that can be more effective for men or women.

Ladies can check out a variety of protein powders to see what’s available for their needs. There tend to be more protein powders available for men that already have the extra minerals and vitamins included to help them get gains. So when guys are searching for the best protein powder, it’s better to decide if they’re trying to get lean or gain weight.

3. Have Realistic Expectations

Having the right mindset is imperative to achieve the fitness goals of any kind, and it starts by having realistic expectations. If you don’t like what you see in the mirror, then you have to work hard to see a change. However, if you are looking to shed some pounds and reduce your waistline, you can’t expect it to be done within a week.

Realistic expectations directly correlate with being consistent. Gaining weight means you will need to take the time to increase the amount of food in your diet and the number of weight-bearing activities that you engage in.

Losing weight will take a gradual amount of time with you engaging in vigorous cardio and making healthy choices. Your body cannot adapt to the changes that you plan to make overnight.

Published by: chazcheadle in The Programming Mechanism
Tags: , , ,

June 20, 2012 - Comments Off on Google Tech Talk: Continuous Integration

Google Tech Talk: Continuous Integration

Fitness Tips To Help You See Impressive Results

MARCH 23, 2020

Being fit has many physical and mental benefits for your health. However, many people may not understand what it fully requires to fully reach their goals. Follow these 5 fitness tips to help you see impressive results. Check these Testoprime reviews.

1. Stay Consistent

Consistency will lead you on the road to success the quickest. It doesn’t matter what your goals are. If you have consistency and develop a routine that you know that you can rely on, it will lead to you reaching your goals quicker.

For example, if you want to lose weight, you should be consistent in your cardio exercise regimen. This consistency cannot just stop at your physical exercise, though. This consistency has to extend into another important part of your routine, which is your diet.

2. Watch Your Diet

Maintain a good diet to reach your fitness goals.

Many people only focus on the gym and exercise component of attaining fitness goals. As mentioned before, your diet is one of the most important parts of your fitness regimen, but having a great diet, regardless of your fitness goals, will impact whether or not you are successful in your goals as much or more than actual exercise. This is because your body will reflect what you eat and your diet can either progress your goals further or set you back.

It may be helpful for you to keep a log of what you eat and determine which foods you need to eliminate and which foods you need to add. In addition, you also want to be mindful of when you are eating, because it can also affect your performance in the gym.

For those who are bodybuilding or looking to build muscle, it’s recommended to incorporate some kind of carbohydrates before a workout session, and then have a protein-heavy meal once you are finished to speed up the recovery process. Protein shakes are a popular commodity in this regard. However, different protein powders can have different vitamins, minerals, and ingredients that can be more effective for men or women.

Ladies can check out a variety of protein powders to see what’s available for their needs. There tend to be more protein powders available for men that already have the extra minerals and vitamins included to help them get gains. So when guys are searching for the best protein powder, it’s better to decide if they’re trying to get lean or gain weight. Visit https://washingtoncitypaper.com/article/565430/prodentim-reviews-new-report-on-this-chewable-candy-for-healthy-gums/.

3. Have Realistic Expectations

Having the right mindset is imperative to achieve the fitness goals of any kind, and it starts by having realistic expectations. If you don’t like what you see in the mirror, then you have to work hard to see a change. However, if you are looking to shed some pounds and reduce your waistline, you can’t expect it to be done within a week.

Realistic expectations directly correlate with being consistent. Gaining weight means you will need to take the time to increase the amount of food in your diet and the number of weight-bearing activities that you engage in.

Losing weight will take a gradual amount of time with you engaging in vigorous cardio and making healthy choices. Your body cannot adapt to the changes that you plan to make overnight.

June 20, 2012 - Comments Off on Below The Surface: The Linked Mechanism –  Benefits Of Word Of Mouth Marketing To Businesses

Below The Surface: The Linked Mechanism –  Benefits Of Word Of Mouth Marketing To Businesses

Competition is fierce in the modern world, being successful nowadays requires a great strategy and making the most out of opportunities when they present themselves. Word of mouth marketing is an area many businesses forget about or don’t take seriously. Word of mouth is essentially free advertising or promotion of a brand or their products. Marketing tactics and best practices (that can be seen in ful.io site) can trigger positive word of mouth for businesses. Here are 5 benefits of word of mouth marketing to businesses. This is the best customer service experience.

5 Benefits Of Word Of Mouth Marketing To Businesses

1: Sales

In today’s connected digital world, a single recommendation can have a far greater impact than anything else which a business might do to increase their sales. 83% of people are more interested in buying a product or service when they’ve gotten a verbal recommendation from their friend or family member.

2: Costs Nothing

Word of mouth is free, you don’t pay people in conversations who discuss their experiences with your company with others. In comparison to paid advertising and promotion where you could spend hundreds or even thousands of euros to run a campaign in print, on the radio, on television or social media.

3: Credibility

One of the strongest benefits of word of mouth is its credibility. Hearing about something positive about a company or product from a friend or family member carries more impact and importance to you rather than hearing it from the company itself. Word of mouth acts as proof and lets people know your business is credible to do business with.

4: Long-Term Value

People who purchase products or services based on a referral tend to stick with your company longer than people who find your business by other means. This is because they trust your business and are loyal. Happy customers will direct their friends and family to you over time making the value and growth of the first referral huge.

5: Builds Your Brand

Building your brand is vital in business, this is how you get bigger in size and increase profits. Word-of-mouth marketing helps generate talk about your brand and increases your sales which build your company’s brand. A strong brand image will influence your current and potential customers to positively respond to your products and services.

Is your business struggling to recruit? Whatever the size of your business and regardless of whether you have a human resources department or not, there are often many signs that might be telling you that you need to work with headhunters in Utah.

Word of mouth marketing can be a strong force in increasing sales for a business. It doesn’t matter how good your website is or how efficiently you run your business, if you don’t provide a quality customer experience then you won’t generate positive referrals and exposure. To see how we can help you grow your business online, visit us online today and book a consultation.

June 18, 2012 - Comments Off on Maniacal Motors

Maniacal Motors

Life is defined by movement. I remember being struck by how beautifully a molecule and solar system mimic each other in their respective orbital ballets. Yet whether fast or slow, large or small, movement, or lack thereof, can be incredibly inspiring. A large part of many artistic works is attempting to successfully capture a feeling of speed or lethargy which goes to show: movement is inspiring.

Racecar

Still mediums have always been the most interesting to me due to their static limitations. The successful illusion of motion within a single frame is astounding. Even such effects in moving mediums can be difficult to properly capture and impart.  Yet somehow Kyle Thompson not only accomplishes this trick but further twists it to a beautiful and surreal extreme.

Websites in motion are the new thing apparently if you look at any recent design-centric site (see last week's website for example). The magic of HTML5 animation and video have made cross browser, flash-free, motion graphics on sites a stunning reality. The homepage for Impero based in London and Sydney is a striking example of this hot trend. Complimented by a stellar design, the site's bright colors undoubtedly leave a lasting memory in this visitor's mind.

But it's not just the web that is seeing captivating technological advances when it comes to motion. The rise of digital film and the subsequent falling cost of the equipment involved has helped fuel one of the most popular genres of web clip: slow motion. Granted, such cameras are still thousands of dollars, yet there's something infinitely interesting about seeing the invisible world of speedy things that's constantly happening all around us. The production company Marmalade lives for this world and leverages our fascination with it to create unique brand images for some big corporate players. The following behind the scenes and demo-reel  video shows off the level of talent involved in producing such work which looks so perfect I have, up to now, assumed it was computer generated.

http://www.youtube.com/watch?v=cKC6j7pW6T0

The Sketching Mechanism is a series of weekly posts, published on Mondays, containing the artistic musings of Mobile Designer/Developer Ben Chirlin during our Monday morning meeting at the NY Creative Bunker as well as his inspiring artistic finds of the week.

Published by: benchirlin in The Design Mechanism
Tags: , , , ,

June 14, 2012 - Comments Off on How to programmatically pass an argument to a view in a Quicktab

How to programmatically pass an argument to a view in a Quicktab

We are building a site in which we are using taxonomy term page templates to display some content. One of the requirements is to include a section at the bottom of the page with tabbed content which is related to the current term.
The page path will look like this: site.com/topics/topic-name. Where topic-name is a taxonomy term name. For this project, we're using the excellent Quicktabs module.

First we create the view which provides the Quicktabs content. The view will display content based on the taxonomy term being viewed, so we add a contextual filter ('arguments' in D6) based on the Term ID. Normally, the contextual filter will get its parameters from the URL, but we're using pathauto to make the URL look nice and so the taxonomy term name as represented in the path will not translate to an argument that the view can use.

Add contextual filter

Add contextual filter

At this point, the view won't work correctly, since it is expecting a term Id and the path arguments will be text. But that is ok, we're not done yet.

What we need is a way to pass the taxonomy term id to the view, but we must do so through the Quicktabs object.
Quicktabs is very cool, but as you can see in this screenshot, there is no way to pass the term id to the view with this form when the term is not in the URL.

Quicktabs settings

Quicktabs settings

As with the view we created earlier, we'll set this up and move on to the next step which will tie all of these parts together.

We created a taxonomy term template to theme the display of our terms, and that gives us access to the term id, $tid, and that is precisely what we need to feed to our view! In our term template file we print out the terms fields like we want and then at the bottom, we add a few lines of code that will send the term id to the view through the Quicktabs object and then render it.

Here's the code:

//Load the Quicktab instance and assign it to a variable we can manipulate
$qtabs = quicktabs_load('topic_tabs');
foreach($qtabs->tabs AS $item => $id) {
// Here we pass the $tid to the 'args' element of the each tab
$qtabs->tabs[$item]['args'] = $tid;
}
// Create a render array of the newly modified Quicktabs instance.
$quicktabs = quicktabs_build_quicktabs('topic_tabs', $overrides = array(), $other = array());
print render($quicktabs);

And here is the resulting themed and tid aware Quicktab:

Quicktabs with filtered view content

Quicktabs with filtered view content

Now, when we visit any term page, we will see the content and at the bottom will be the Quicktabs with the relevant content.
This can be extend in several ways. You can alter the tab titles, default active tab, the tab order, etc. all on the fly based on any number of variables.

References:

Published by: chazcheadle in The Programming Mechanism
Tags: , ,

June 13, 2012 - Comments Off on The MechCast 201: Podcasting Is A Job: The Return Of The Mechcast

The MechCast 201: Podcasting Is A Job: The Return Of The Mechcast

In this edition of the Mechcast, featuring Dave, Antonio, Ben, Chaz and surprise guest Michael, we discuss Mike Monteiro's Design Is A Job, the book we read as part of The Reading Mechanism, our new book club introduced not too long ago here. A lively conversation that touches on money, clients, expectations and real world vs book world situations. We conclude the podcast with a section we call Burst The Bubble, where we share things that we enjoy for you to discover.

Download the podcast (18M, 38 Minutes)

 

Podcast Links:

 

 

 

Published by: antonioortiz in The Mechcast
Tags:

June 11, 2012 - Comments Off on Managing of Media

Managing of Media

While we may be living in the information age, our increasing dependence of data also means an equally increasing dependence on interface. When I pause to think how much interface has evolved over my lifetime alone, it is truly mind boggling. I remember lying on the floor changing channels on the TV with my feet when our remote broke as a kid yet today I can control my computer from my couch with a touchscreen device. And as technology and art become more closely intertwined, the impact of interface on art and vice versa is inescapable making interface undeniably inspiring.

French design studio Zim and Zou celebrate our interface history with a joyful series of paper-craft facsimiles. While modern gadgets may be slick, it saddens me that today's kids will never know the (near) endless joy of pulling the tape out of a cassette and draping it about the room as impromptu confetti. Likewise the magic of an instant Polaroid will be lost on them as digital cameras make photos instantly viewable, no shaking necessary. Then again, they do have touch screens in their pockets so let's not pity them too much.

Polaroid

Yet not all interfaces have to be intuitive. There is something to be said for the joy of exploration and discovery through interaction. The studio Blacknegative creates just such an experience with their delightfully confusing website. Beyond the basic sliding page action, each individual page contains its own visual and interactive vocabulary unto itself making each a wonderful game of interactive discovery. Each click promises to reveal new tidbits making for a very engaging web experience. Add to this the superb use of HTML5 technologies like full page video and adaptive design and you get a riveting modern site.

blacknegative

Blacknegative manages to push how we perceive current interactive experiences while others are eagerly trying to define entirely new ones. This fascinating mini-documentary showcases new point cloud camera technology which combines traditional cameras with the affordable depth camera of the Microsoft Kinect. The interviewees address not only what makes the tool itself interesting, but how it is so unique that it requires a complete redefinition of the visual language in film. While I doubt such devices will take over Hollywood anytime soon, I can foresee their 3D ability becoming ever greater to the point of allowing true telepresence and other immersive virtual experiences.

The Sketching Mechanism is a series of weekly posts, published on Mondays, containing the artistic musings of Mobile Designer/Developer Ben Chirlin during our Monday morning meeting at the NY Creative Bunker as well as his inspiring artistic finds of the week.