When changing weight of element in array, it is not enough to just change weight, #sorted must be set to FALSE so elements are resorted.
$variables['form']['element']['#weight'] = -10;
$variables['form']['element']['#sorted'] = FALSE;
When changing weight of element in array, it is not enough to just change weight, #sorted must be set to FALSE so elements are resorted.
$variables['form']['element']['#weight'] = -10;
$variables['form']['element']['#sorted'] = FALSE;
Took time to find out this one. To set title or label for a fivestar form field you need to add
'#title' => t('Your rate'), to your code, so it should go like.
Use Mailchimp's RSS-Driven Campaign as it is refered to here. So make a view outputting RSS and use that.
http://kb.mailchimp.com/campaigns/rss-in-campaigns/create-an-rss-driven…
You can preprocess nodes and fields with hook_preprocess_field hook_preprocess_node, but when it comes to beans, you need to use different approach, hook_preprocess_bean doesn't exists. So to do this, you need to use this
I was building a view for RestWS to output JSONon data, to have date show for specific date range you need to pass filter range. To do that you need to pass filter as two dates, with separator beeing "--" e.x. 2015-06-24--2015-06-28
Or in full link it would be
This one was not easy. Changing product display, which is node is possible in different ways, but then you have a field_product_reference, which outputs buy button and attributes buttons. So you moved around price in your node template, body/description etc, but you want to separate attributes changing widget and buy. You just can't.
Using drush on mac with mamp gave me some problems with default setup. I didnt set
DRUSH_PHP variable anywhere so default php was used, also with that no php.ini setting was set and in my drush status I got empty "Drush configuration" variable. So to set this up, I needed to add this to either .profile or to .bash_profile (depends of load order, later goes first if you have it)
What I needed is to preprocess this whole group of data, that consist add to cart button and attributes fields. "Add to cart form" is basically the one that consists attributes and add to cart button. To do that the only way to make it work with AJAX is with form alter. So change the forms data in
This will give you a nice array of all the data.
$request = drupal_http_request('https://maps.googleapis.com/maps/api/geocode/json?address=1600+Amphitheatre+Parkway,+Mountain+View,+CA');
$out = drupal_json_decode($request->data);
Using EVA field added to Order entity I needed to use order created date as starting range and ending range for dates.
UI by default doesn't offer this in views, so some preprocessing was done. You could fetch date from argument or as I did directly from