Questions tagged [7]

Version tags should be used 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
2answers
22 views

How do I give access to only specific roles to buy at my store?

I have a platform with roles for moderators, editors, teachers and students. Only student roles should be able to buy courses and the other roles should not be able to buy courses or see any of the ...
0
votes
0answers
12 views

How can we show up active filter values in exposed filters?

I have a requirement to show up selected filter values from views exposed filter. For ex: When I select OptionA from filter-1(select list) and OptionB from filter-2(select list), Results will get ...
0
votes
0answers
21 views

Automated Testing using CodeShip and Cypress

We are trying to figure out the best way to incorporate CI/CD with our End-to-End cypress tests for our Drupal project which contains a lot of custom code, but are finding it a little difficult given ...
0
votes
1answer
29 views

How to hide body field in a view only on certain content types

I have a search result view of different content types, and i want to show the body field (trimmed) on some content types, but show no body on other content types. Since they all share the same body ...
0
votes
0answers
10 views

How to migrate Contributed Module Configuration from one environment to another one?

I have 5 different Development servers and there is one configuration related to contributed module called External links, now I am trying to create feature for that config so that I can easily roll ...
0
votes
0answers
18 views

How do I set granularity to an END date value used as sort criteria?

I have a Date field with start and end dates (mm-dd-yy). I need to build a View listing nodes grouped by end date year and sorted first by descending end date year and second by ascending title. ...
0
votes
0answers
9 views

AJAX altered Entityform edit form not rebuilt 2nd time

Background I have an Entityform (using module with 7.x-2.0-rc4) with two select dropdowns, and I'm trying to alter it such that the second dropdown filters based on the first using AJAX. Current ...
0
votes
0answers
7 views

Ajax submit comments by pressing enter

I am using the Ajax comments module and display suite. https://www.drupal.org/project/ajax_comments When pressing submit button the comment form gets submitted via ajax as it is supposed to. When I ...
0
votes
0answers
12 views

How to separate the user profile picture upload from the base form in Pages?

I have enabled the user_edit form in Page Manager and added my account fields but the username, password, time zone, language and picture settings always stay in the base form. How can I separate ...
0
votes
1answer
58 views

The email doesn't have the DKIM signature it would get from mail()

My web host (HostGator shared server) normally signs outbound emails with DKIM. When I send emails from Drupal 7.69 (and Webform 7.x-4.22 for compatibility with CiviCRM), however, there's no DKIM. ...
0
votes
1answer
43 views

How do I add the “onload” attribute to a script tag?

I need to add the onload event in jquery script tag as advagg does. I have done a bit of research, and I found that they are actually invoking hook_element_info_alter() and thereby add their ...
0
votes
0answers
13 views

Are there any solutions that integrates custom mysql datetime field with views?

I created my own table with a mysql datetime field via hook_schema. The code that defined the field is here 'timestamp' => [ 'description' => 'The timestamp value when the recipient ...
0
votes
1answer
19 views

Why do all product display nodes with same referenced product (SKU) appear in 1 order view

Each time an order is added to cart, the admin/commerce/orders/11/view, for example, shows all product display nodes ever created on the site for that SKU. I suspect that this is not the normal ...
0
votes
1answer
100 views

How to limit form submission per user per day and week?

The goal is very straightforward. I need a form to limit each user to 1 submission per day and 3 per week. What I found: Webform: The "Form settings" in webform has the "Per user submission limit" ...
1
vote
0answers
31 views

How to trigger a rule whenever users update their picture

Using Drupal 7 and the Rules module I need to trigger a rule whenever users update their user-picture. I tried using the event "After updating an existing user account" which does trigger the rule, ...
1
vote
2answers
36 views

How can I fetch the Inviter in Rules

How can I fetch the Inviter of a user in Rules? I'm using Drupal 7 and the invite-by-email module (part of the invite module https://www.drupal.org/project/invite), to allow users to invite others. ...
0
votes
0answers
11 views

How to automate click the “ Click to Calculate Shipping ” button upon filling up the Delivery Information

I've been struggling for days finding for the right answers . I want to achieve a function that when a user fill up the billing / delivery information , the " click to calculate " button will be auto ...
1
vote
1answer
18 views

Why do D7 form builders have a $form parameter?

In Drupal 7, the first parameter of a form builder function is $form. When implementing a form builder function, one has the option of either adding stuff to this existing array and returning it, or ...
0
votes
1answer
30 views

How can I change the 'type' of Drupal script tags from text/javascript to text/plain?

I could use some assistance in figuring out a way to change script tags for a Drupal 7 site to be "text/plain" instead of "text/javascript" And additional attribute(s). I can tell already that ...
0
votes
1answer
34 views

How to set in my own module dependency on a composer package?

I have some of my own modules written on Drupal 7 that use composer packages. These composer packages are downloaded with the module Composer Manager. How can I set explicitly the dependency on a ...
-1
votes
2answers
30 views

Print machine name in script

I want to include a tracking script in my Drupal website and inside the script I want to include things like, title of page, description etc. In other words, I need to include the machine names inside ...
0
votes
1answer
18 views

In node add, how to upload file using image from clipboard

How can I paste image from clipboard and save into image_field ?
0
votes
0answers
13 views

how cache a view, that has a field that is calculated with php code [duplicate]

//source code from simple_hierarchical select node count module function shs_node_count_term_get_node_count function count_term_get_node_count($term, $count_children = true ) { $og_group_ref = ...
0
votes
1answer
36 views

how cache a view that has a field that is calculated on the fly

in a view, one field has the following computed value, which takes a lot of time to return results from the database: <?php $term = taxonomy_term_load($data->tid); print ...
0
votes
0answers
20 views

How do I authenticate Angular 8?

I have a site with Drupal 7 backend and Angular 8 front end. I use services on Drupal 7, as we I try to access to these services with postman that is possible. First I get a token and then by that ...
0
votes
1answer
30 views

Alter form after submit

I'm creating module to use similiar words to get better search result. I have API which will returns top X similiar words for entered word. What I want to achieve is this workflow: User enter some ...
-1
votes
1answer
61 views

Curl response into variable

Similar to Problem with cURL I have an api response which is returned at numerals only If I break the code with a print_r($rate); which is where I point the curl response to an ajax error shows the ...
0
votes
1answer
29 views

Basic page template

I am using Drupal 7 to create a page and a custom template for that page. I created a page from Content >> Add Content >> Page. In my theme /template folder I have created a file called page--my-...
0
votes
0answers
70 views

How to set different root folder access for different roles in elFinder

I'm using drupal 7.69 and elFinder 2.1.46. A private page is showing elFinder browsing window with 2 root folders root1 |-dir1 |-dir2 root2 |-dir3 |-dir4 I am trying to setup 2 roles: ...
0
votes
0answers
76 views

Issue with Access PHP array in display module

I am passing few parameters via ajax to custom module (fgs_api.module) and in returns getting JSON data ($results->data). I want to use/get that variable ($results->data) in node--xyz.tpl.php ...
0
votes
1answer
15 views

Extend the Scheduler module forms

Hi i'm trying to extend scheduler module forms. The one i need is included as fieldset in node as extra field refer to image /** * Implements hook_form_node_type_form_alter(). */ function ...
0
votes
1answer
21 views

Show the title of the node from an entity reference

i have a content type, which has in it a field which is of type Entity Reference. I now have created a view, where i need to aggregate on the sum of records based on this field. But my problem is that ...
0
votes
0answers
13 views

Can we make Superfish Top Menu not clickable but upon hover shows sub-menus?

I'm new to Drupal 7 and working on a website which is customized built using alpha theme. So far I'm good in understanding the working of it and creating content from the front end. For the main menu, ...
0
votes
0answers
18 views

How to fix malfunctioning “Other” option for textbox display on webform?

I'm having an issue with a textbox display on a webform. Whenever I click the the Other option the box doesn't appear. But when it's unchecked, it appears. option error gif link The solution I've ...
1
vote
1answer
47 views

How to call custom javascript function defined in js file from .module file

I have some custom menu defined for which in the page callback function I want to execute some javascript function defined in some js file which is included in .info file. The alert and console.log ...
0
votes
0answers
23 views

Rewrite field ampersand converts to &amp;

I have an URL field that I'm outputting in my Services Views endpoint and everything works perfectly until I add a query string. The aim is to add UTM parameters to my URL through the rewrite field. ...
0
votes
0answers
10 views

Facet api active facet description

I'm using search api and facet api to create a faceted search. The facets are taxonomy terms in the sidebar. What I need to create is a block that shows the description of the taxonomy term in ...
0
votes
1answer
13 views

Why are non-required fields still showing up in my node_edit template using Page Manager

I am stumped. Certain fields are NOT required and yet they still show up if I add the base form to a node_edit variant in Page Manager (Node add/edit form).
0
votes
0answers
10 views

How to stop a custom form from being submitted twice simultaneously

We have an issue with a custom form's validation/submit steps being processed twice, resulting in unexpected behavior. This form creates an object with some unique fields, therefore, when the second ...
0
votes
0answers
15 views

Using lock_acquire for Drush batch operation

I am trying to improve a batch function so that it uses lock_acquire(), in order to prevent users from trying to run a large batch if it is already running. To do this, I try getting the lock in the ...
0
votes
1answer
35 views

Delete confirmation as popup

I have a view containing saved user webform drafts set up in a table format. I have given permission to the authenticated user to delete own submissions. When clicking the delete link located on the ...
0
votes
0answers
25 views

Commerce copy billing to shipping

I have a Drupal 7 webshop with commerce, and using the commerce_customer contrib module to handle adresses. I have enabled the "Enable profile copying on this checkout pane" and copying field data ...
0
votes
0answers
18 views

commerce_kickstart-7.x-2.64-core.tar.gz does not contain any .info files

Unable to update to commerce kickstart 7.x-2.64 using drupal update. I get the following error message: "commerce_kickstart-7.x-2.64-core.tar.gz does not contain any .info files" I have updated ...
0
votes
0answers
28 views

Can't run database update script, webforms not display webform tab

We are running Drupal 7.69 under PHP 7.3.13 on Bluehost. Not sure what happened, but when I try to browse to update.php to perform database updates, I get the prompts as expected to update the ...
0
votes
1answer
32 views

Can I turn a regular content type into a Commerce product display?

I have an existing working site with lots of content. I've come to the realisation that I could actually sell this content. So is there a way to turn my existing content type into a product display ...
0
votes
0answers
17 views

I cannot uninstall the Coder module

I am using Drupal 7. I go to the Modules page and Coder, Coder Review, and Coder Upgrade are all disabled. But if I click on the "Uninstall" tab, Coder is not listed. How do I remove this module ...
0
votes
0answers
11 views

Show all content referenced by another content, regardless of language

I have a "Movie" content type. It can be translated in 3 languages (fr/de/it). I also have an "Event" content type. It cannot be translated. It has a field that can reference a Movie (reference field)....
0
votes
0answers
12 views

How to flag a node and take the values from a node in a block and set these in fields of the flagged node

I am creating a calendar view showing the available sessions of a Teacher (role). Each session has a global flag named "Book Session". A Student (role) can have multiple courses but only one needs to ...
0
votes
0answers
28 views

After login I get blank admin pages

I have a D7 site up and running and working fine. Today I logged in to update some content, but I saw that the admin pages just show the system messages about necessary module updates and that's it. I ...
2
votes
1answer
52 views

Emoji works in a site but not in the other site on the same host

I am trying to enable emojis following Multi-byte UTF-8 support in Drupal 7. I have added the following to the settings.php file. 'charset' => 'utf8mb4', 'collation' => 'utf8mb4_general_ci'...