Questions tagged [7]

Version tag to tag issues specifically related to Drupal 7.x. Please note that version tags should be used only for questions that apply to a version only, not to merely say what version a site is using.

Filter by
Sorted by
Tagged with
1
vote
1answer
52 views

How to hide user picture based on the value of a field in their profile

This last bug is the only thing between be and launching this site. Please help! I have a field called publish photo? that is a checkbox in the user's profile. For users with this box unchecked, I ...
1
vote
1answer
123 views

How can I set a default node owner for anonymous nodes on the node edit form?

This question is refining the poorly asked Is there any easy way to set the default author for a node being edited to the current author if it is currently anonymous? The site I'm working on has a ...
0
votes
1answer
329 views

content type field not printing

In drupal 7, I defined a field for a custom content type and am trying to display its value via page.tpl.php. Nothing is appearing in the rendered page. Here's the relevant piece of page.tpl.php. ...
5
votes
10answers
7k views

Drush CC all returning “No Drupal site found, only 'drush' cache was cleared”

I've tried other solutions, but none of them are specific to my setup. I just started using the new Linux subsystem featured in the recent Windows 10 update. I'm using WAMP x64 v3.0.6, and have ...
0
votes
1answer
339 views

An ajax jump menu using Drupal views?

I've got a Drupal view that contains a jumplist of items filtered by taxonomy (which is pulled from the current page URL). The problem is that I need this jumplist to work without a page reload (so ...
0
votes
1answer
409 views

Internal server error on node save

I'm getting internal server error on node save. In db log messages there is no such error regarding this issue. In apache error log I have these messages mod_fcgid: read data timeout in 40 seconds, ...
0
votes
1answer
375 views

How to embed and play on same page like popup?

I'm learning web development with Drupal 7. I can embed youtube video using CKEditor on a node. I like to play embedded video looks like on YIFY and IMDB as popup/overlay. It means when I click on ...
0
votes
1answer
340 views

How to add onBlur attribute to ZIP code field in Address Field

In order to control the input format in the ZIP code field in the dynamic address fields provided by the Address Field module (I use it in Drupal Commerce) I need to add the attributes onKeyUp and ...
0
votes
4answers
374 views

Theme image broken link

I am recreating an existing website and part of the process is enabling a theme from the same existing site on my new version. The theme is called microsite and has an image located in /microsite/...
0
votes
1answer
664 views

How to use drupal_add_library with a module?

I'm new to Drupal and don't really understand how to set up drupal_add_library. I've made a simple module that links out to a .js file. However, this .js file depends on a couple of generic functions....
1
vote
1answer
399 views

Get the breadcrumbs for a specific node other than the current

I have a list of nodes created by a view. Those nodes tend to have titles that are mostly the same, but since they are in a rather logical hierarchy defined by the menu I'd like to output the ...
2
votes
1answer
563 views

How to implement Drupal ajax API on non links and not form submit

There are many examples how to make ajax form submits and also many examples how to make drupal ajax links. But how to attach ajax click events for example on <button> or <div> elements?
1
vote
2answers
444 views

Change page URL structure based on node field value

I'm using Pathauto to produce nice URLs for my Drupal 7 site, and have run into the need to edit the URLs based on a node field value. Specifically, when the content is archived on my website, the ...
2
votes
1answer
1k views

How to set a validation error via ajax?

I am using the formapi to create a form. On one of my fields I have an #ajax call. When the field is changed I call the function. I recreate the form and then replace the whole form on the page. This ...
0
votes
1answer
17 views

Override a file from the parent theme

Adding in the child theme a CSS file with the same name as the parent theme CSS file overrides the parent file. It doesn't seem to work JavaScript files. How can I override a JavaScript file loaded ...
0
votes
2answers
411 views

Collapsed and collapsible Field Sets in Admin

I have created a fieldset (which groups a field collection). Because it has a few nested levels and many fields, I want it to be shown collapsed. I am trying this code but it does not work. The id is ...
0
votes
1answer
15 views

Alter Add to Cart form POST data provided by #action

I am going to be phasing out Drupal Commerce on our website in favor of a new custom built application that is hosted at another URL. Without completely rebuilding everything I am trying to override ...
0
votes
2answers
486 views

set min - max values drupal date_popup timepicker

Is it possible to set the minimum and maximum values of the timepicker in a date_popup field? I use this code for the field, but something like 'minTime' is not working. $form['fetch_date'] = array(...
1
vote
1answer
350 views

How to send a vote using Advance Poll and Services Voting Api?

I need to expose a poll to a mobile app. After doing some research I found out that I could receive the votes, through a web service, using the services_votingapi module, and the go-to poll to use was ...
0
votes
0answers
35 views

Remove duplicate records from view result with pager

My project is setup in Drupal 7 and i am using search API for display my custom search result. Actually i want to show search result based on two content types content so i have configure the search ...
0
votes
1answer
404 views

Combine hook_search_execute

I have hook for user_search_execute and node_search_execute for both user and nodes but i want to merge both into mymoduel_search_execute but only node_search_execute uses index not ...
0
votes
1answer
346 views

User must click Back button twice after adding item in cart

I have added Drupal Commerce in an existing D7 site and I use the existing product nodes, in which I have added the Add to cart form. Everything looks nice and works fine, except for one thing. When a ...
1
vote
1answer
366 views

Strip overlay context from File field

I have a basic File field set up to allow my users to attach files to nodes. However, the File field widget in the node edit form displays files as a link to the file, and the URL contains #overlay-...
1
vote
1answer
532 views

Sending email notifications to webform submissions

I am trying to create a rule that will send an email to a list of webform submissions, notifying them when new content is created. So far, here's what I have: Event: after saving new content of type [...
0
votes
2answers
52 views

Create a Corresponding Entity Reference preset programmatically

I'm using the CER module in Drupal 7. Is there a way to create a preset programmatically?
1
vote
2answers
41 views

Override a function in a contrib module

My company received a maintenance contract for a website developed in Drupal 7. The Drupal 7 website uses the Quiz contrib module, ver. 7.x-4.0-rc10. The module is used to implement a feature where ...
0
votes
1answer
414 views

Ajax Form Not Working in some Some Regions

I created an ajax based contact form in my module.Then I made a block view for the form. I tried putting that block to several regions. When I put the block to 'Sidebar Second' the form works as ...
0
votes
1answer
14 views

How to create programmatically multiple URL alias of same taxonomy term?

I have category cars and I want to create its URL alias according to the region like if the user location is Australia than URL will mysite/australia/cars similar if the user location is USA than URL ...
0
votes
1answer
386 views

How can I query and order nodes with multiple date field values within a specific range?

I'm trying to get nodes that have date fields (multiple instances in some cases) and display them sorted ascending by start time for a given date. For illustrative purposes, here are some events and ...
0
votes
1answer
389 views

Errors when Taxonomy is chosen in node's Term Reference field

I have created a vocabulary called "Recipes" with several terms underneath (Appetizers, Dinner, etc). I also have a content type called "Recipe" with a Term Reference field for the Recipes vocabulary. ...
3
votes
1answer
390 views

Some fields are not sorting properly in view

I'm trying to create a directory list in view. But some of the fields are not properly sorting. See the below image for my view configuration. And the output of the view. Update: Style setting ...
-6
votes
0answers
112 views

Installed module not working

I have a website hosted in Pantheon and I am trying to install the Security Kit module to the live website. I tried installing it on DEV (dev.website.com) environment, and then moved the code to ...
0
votes
1answer
400 views

Node is not created, but nid is returned

I have this code in my module. $node = new stdClass(); $node->title = "YOUR TITLE"; $node->type = "page"; node_object_prepare($node); $node->language = 'it'; $node->uid = 1; ...
0
votes
1answer
611 views

How to unblock IPs in bulk?

I use the Drupal Core IP blocking feature (/admin/config/people/ip-blocking) to block IP addresses during spam attacks. However, as most of these will be dynamic ones owned by legitimate users a day ...
0
votes
1answer
381 views

How do I add a more/less link in block?

How do I add a more/less link to drop-down and roll up a block? I have a custom search block with a lot of field items and as such, the block is so long. I want to be able to add a more link to drop ...
0
votes
1answer
944 views

Display date picker not inline in Drupal 7 Forms API

I have installed Date Picker Module and it works fine. Below is the code: $form['date'] = array( '#title' => t('Select your birthdate'), '#type' => 'datepicker', '#date_format' =&...
1
vote
0answers
29 views

Help me write a Rule condition and action to remove discount line item and to add payment

I am trying to write a rule for an existing order. Order has a zero total due to (Commerce) discount, e.g.: Widget $3.00 Discount -$3.00 For the condition, I'd like to check if a specific discount is ...
1
vote
1answer
4k views

hook_preprocess_html in my module

I am having a content type with fields select list, js, css, and body. In the select box it list a number of templates to apply on the current node. I have these custom templates in the templates ...
0
votes
1answer
418 views

Unknown engine type outputformat

Hello I've just updated Drupal (to version 7.53) and now in Drush when I try launch the commands: "drush @theflyingeye.org up" (to update my website) or "drush @theflyingeye.org cc" (to clean chache) ...
1
vote
1answer
366 views

Help with Theme Function

I can't get the theme() function to work. Cleared cache too. If I rename the function to: theme('wow_template', $output') it works but anything other doesn't. function wow_page() { $cloud = '...
1
vote
2answers
446 views

Views date filter by year - only one select list for the year

I have a content type "news" and a views page to list the news. The views contains a exposed filter (category and year). How can I realize the select list "Year" with the follwing options as exposed ...
0
votes
1answer
579 views

Add popup within the ckeditor dialog box?

Here is the scenario. I had added a custom plugin in ckeditor. The plugin provide a button on the editor menu and when we click on that button ckeditor dialog box opens up with a text field and and a ...
2
votes
1answer
331 views

Correct way to extended Field Settings

I'm doing something that works fine but I get the feeling there is a better way. I have managed to extend the field settings in the field's manage page to add two new checkboxes. The checkboxes in ...
0
votes
1answer
409 views

Taxonomy Term showing strange text

Having taxonamy term issues - as glossary terms showing with text below the text saying "There is currently no content classified with this term." does anyone know how to remove or hide the ...
4
votes
5answers
17k views

Render custom block by block name

I have created a custom block in the Drupal CMS. Say it is called "test_block". Is there a way to render this block in a template file using the name of the block? Thanks,
0
votes
1answer
378 views

Facebook Album fetcher

I am using facebook album fetcher module. It shows an error message An unknown error occurred while trying to fetch the album (empty reply). Can anyone tell me how to resolve this issue.
2
votes
1answer
415 views

Custom template for each profile2 profile type edit form

I am working on a Drupal 7 site and for a few days now, I've been struggling with this problem: I am trying to create a custom template for the edit profile form, but there are more profile types. I ...
0
votes
2answers
437 views

How to process a multiple values field (comma separated) in a Rules Action?

I am using modules "SMS Framework",Clickatell for sending message and I have configured all the settings which was required. I have also created a rule where node (Article) be saved and send a message....
1
vote
1answer
415 views

How to hide the (-) sign from facet filter block?

I am displaying faceted blocks and current search block on the search page. When I select a filter from any faceted block, it appears in the current search block and also in that faceted block with ...
0
votes
0answers
28 views

CKEditor doesn't work after updating

I've updated a drupal website to the latest 7.x version, and CKEditor stopped working. I had it originally getting //cdn.ckeditor.com/4.5.4/full-all, I've updated to //cdn.ckeditor.com/4.13.0/full but ...