Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [7]

Version tags should be used only for questions that apply to a version only, not to merely say what version a site is using.

0
votes
1answer
36 views

Alter The User Login Form Into Multi Steps

I want to alter my default user login form into multi step. therefore I have wrote a code which I'm pasting below. but this code is not working, whenever I click on "Next" button it will return on the ...
0
votes
1answer
16 views

Theme Suggestions for User Page

I want to create a separate html.tpl.php for user pages and user edit pages like html--user.tpl.php and html--user--edit.tpl.php. For nodes I have added: if (isset($node) && $node->nid) {...
0
votes
2answers
32 views

Form #states visible for numeric values

The form has two radio buttons like follows.The "design" radio field should be visible only when user selects 'Ten' or 'hundred' from the "price" field. If user choose 'other' it should not be ...
0
votes
0answers
16 views

How to embed a login or register form inside a page content body

First of all I am new to drupal. I am looking for a solution where I can include a login or register form in the body of a page with admin-editable page content/markup flowing before and after it. ...
0
votes
1answer
21 views

Is db_set_active a global or local setting?

I need to run a new query on another database. I configured the settings.php $databases = array ( 'default' => array ( 'default' => array ( 'database' =...
0
votes
0answers
21 views

Make the title field an external URL

I have a view in Drupal 7 that has a title field and a URL field. The latter contains external URLs. I'm trying to configure it where the title links to the external URL once the user clicks on the ...
1
vote
2answers
21 views

Workbench Moderation: Published data overriding draft data on draft view

Moderation's draft content not showing on the front end. When a node has both a published and a draft, the data from the published overrides the draft data on the front end when viewing the draft. ...
0
votes
0answers
46 views

PHPExcel - How to have “save as” dialog for export instead of saving on host?

I have installed PHPExcel module to be able to export data from my site. Everything is working ok, using the code given in the example page. The file is generated correctly but only on my host. I ...
5
votes
2answers
159 views

Using modules “not covered by Drupal’s security advisory policy”

I would like to use a Drupal 7 module that is "not covered by Drupal’s security advisory policy", specifically the Conditional Fields module. It would allow me to do exactly what I need. It looks ...
0
votes
0answers
20 views

Twitter timeline only includes tweets of user that were made after account was renamed

We had to rename the handle of a twitter account. The twitter timeline view now only shows tweets with the new handle. I guess its because of the screen_name join This is the view sql statement in ...
0
votes
1answer
28 views

Deleting translate interface strings programmatically or using drush

I need to delete some translated strings added using t() function, I've about 17000 string to delete is there a way to delete it using a SQL query or drush command? in which table those strings are ...
1
vote
2answers
30 views

Show different fields on node edit and node view depending on the sub-type of the node

I have a specific node type that I want to show/hide different fields in the page layout for both the node form and when viewing the node. For various reasons I don't want to have to create a new/...
0
votes
1answer
43 views

How can I see the clean query of a view?

I created a test view. It displays data of a content type 'Anagrafiche (name for internal use: contatti)'. The view has the following fields (sorry for the interface language): Contenuto: Immagine (...
2
votes
1answer
62 views

How to add an extra field in file upload widget?

I know that it is possible to enable a description field in the core file upload widget for Drupal 7. However, I want to add an extra description field like the one already present. For this I've ...
1
vote
2answers
31 views

How to prevent Profile2 fields from loading on user registration?

I have a profile2 Profile that's named Driver. This profile has a Term reference to a vocabulary named Cities that contains over 30.000 terms. I made a custom user-register.tpl.php by declaring it in ...
0
votes
2answers
28 views

Views image field

I'm trying to add inline styling to my Drupal image using the image field under view. No matter what method I try, nothing is working. I've run out of options. Any help? Below are a few code ...
0
votes
0answers
22 views

how to append current path to a url?

On a multilingual site, in order to let users pick their favorite language, instead of the basic block provided by drupal, I would like to use the Bootstrap Button dropdown component so i put a block ...
1
vote
1answer
48 views

How to programmatically populate a country field

We are using the Countries module to provide country fields where editors can choose a country and it gets displayed in the frontend. Which works absolutely fine. But we want to fill that field ...
0
votes
0answers
38 views

Disable Bootstrap Tooltips for Individual Form

Is it possible to disable bootstrap tooltips for an individual form (all the components in the form)? I know I can do it in the Bootstrap settings, which will turn off tooltips for all forms, but I ...
0
votes
0answers
21 views

How to check Geocoder module is firing on User save?

I've been using Geocoder module, with Addressfield and Geofield modules, successfully on a site for months, but have now hit a strange problem. SETUP: The User entity contains a Geofield field ...
0
votes
0answers
20 views

Is there a way of deleting a file field without deleting the related file entities?

I'm working on a site that started uploading files via specific Fields appearing in Content Types, but has since moved to uploading them via admin/content/file/add for consistency. I'd like to delete ...
0
votes
1answer
25 views

Edit field in contentType B when creating or editing node of contentType A

I need to edit a field in contentType B when I create or edit nodes of contentType A. I know it's possible to use rules for this but I need to have more control so I want to do it in my own module. ...
0
votes
0answers
43 views

Performance Considerations When Setting the Cookie Expiration Date

Are there any performance considerations to take into account when setting a Drupal cookie to expire 10 or 20 years in the future? I know it's not possible to set a cookie to never expire as per the ...
0
votes
1answer
52 views

How to programmatically update a paragraph field

Trying to get certain paragraph field of certain node updated with new value with the following code: function my_module_node_update($node) { if ($node->nid == '111') { foreach ($node->...
0
votes
1answer
23 views

node API hook that can be used to alter fields before loaded by Views?

I need to use a node API hook to alter some node content before it's displayed, in Drupal 7. It just occurred to me though that if I used hook_node_view() it will not effect the output of a View ...
1
vote
2answers
40 views

How do I setup a proper 404 page?

At present, my Drupal 7 website’s "Page not found" is 301 redirected to a custom 404 page. However, I just checked the HTTP response code for a random URL and I noticed it 301 redirects to a custom "...
0
votes
1answer
38 views

Webform submission values with PHP

I am using webform 2 pdf module, where I am trying to set up a custom content to the pdf file. I would like to acces the webform submission data, but I have no idea how to do it. Basically I would ...
0
votes
0answers
15 views

Change date field; how to add timezone handling later

About date fields, this page https://www.drupal.org/node/767182 says If you start off without a time zone, but then realize that you need one at a later date [...] Perform the switch in the ...
0
votes
1answer
14 views

Attempt URL alias for spanish version of page - “The path */* is either invalid or you do not have access to it.”

Drupal 7.59. We have the page whatever.tld/thanks and whatever.tld/es/thanks. I'm trying to setup whatver.tlp/gracias as a URL alias for es/thanks and it says "The path 'es/thanks' is either invalid ...
0
votes
2answers
29 views

Available node language only English

I have a custom content type with "Set custom language as default for new content" and "Require language". Custom default language is Current language. Entity translation is defined with "Current ...
0
votes
1answer
41 views

My Ajax call for my submit button does not work?

I am building a form with the form builder but I can't even get my button to use its ajax function to callback. Instead of doing a normal ajax call on the page, it reloads the entire page. What am I ...
0
votes
1answer
65 views

Quiz Module persistance implementation details

In which part of the code is a new quiz stored in the database? What are the functions responsible for storing a new quiz in the database upon the submission of the form for creating a new quiz? I'm ...
1
vote
0answers
12 views

How do I get Crumbs to use the dynamic title from a view?

I have a view set up with a: Content: Has taxonomy term ID (with depth) When I preview I see the title... However in Crumbs when I go to the DEBUG tab for the view url: How do I get Crumbs to ...
0
votes
1answer
27 views

How can I toggle required field?

Using Drupal 7. I'm trying to toggle required field based on the click of a radio button. I already tried the proposed solution in this post but it did not work. Here is my code: $(context)...
0
votes
1answer
16 views

How to add a profile cover with a user field image in a view? [closed]

I am trying to add a cover image to user profiles in a block view, the image comes from a user profile field. The problem is that I need the path to that image because my neede code is like this: &...
0
votes
1answer
24 views

Memcache interfering with Simpletest

Adding some tests to an older Drupal 7 site and a few of the tests check for the presence or lack thereof of custom cache items. Having this in settings.php seems to interfere with Simpletest using ...
2
votes
2answers
94 views

Convert pot file to array

So, what I need to do is to convert the contents of a .pot file to a PHP array. I know there is _locale_import_read_po(), but when I tried using it with the following code, I got an error. $...
0
votes
1answer
33 views

Can forms be added to a page of quick tabs?

I want to create a page of quick tabs with some node editing pages, webforms and some admin pages as well regular static pages which just display information without any editing. Is that possible?
0
votes
1answer
37 views

Update image tags using entity metadata wrapper

I'm trying to bulk update image tags using entity_metadata_wrapper. I'm unable to see the image field when I use $emw->getPropertyInfo(). The bundle is called hub_page. The code I'm using is: $...
0
votes
0answers
21 views

how to fetch content result according to the terms Url alias name?

I have created the vocabulary with name blog category and created terms in the vocabulary like events,News,Category. For the Vocabulary terms name url alias generated in the form https://sitename....
0
votes
1answer
51 views

html.tpl.php for a View (machine_name)?

how can I assign my own html.tpl.php to a view (machine_name) via a preprocess-function (template.php) or a hook? If my view is called "foo_view_machine_name_bla", which contains 50 views-pages with ...
-1
votes
1answer
20 views

When does hook_menu run?

I need to edit the hook_menu function in my module. I need to add a new link to a menu, and edit the path for an existing link. Is this possible without creating a whole new module? The only ...
-2
votes
1answer
111 views

Private files and Nginx configuration

How to configure Drupal 7 to have private files folder. And also this configuration is secure within Nginx config.
0
votes
1answer
24 views

How to obtain the average of the number of a field according to the term of taxonomy?

I am using the default view Taxonomy term. I added a "number" field to my article content type. I would like to obtain the average of the fields of the nodes listed by term of taxonomy. For ...
0
votes
1answer
21 views

date_default_timezone_get() returns the wrong timezone

I have several Drupal 7 sites using the same installation in the same server. Two of those sites are returning "Europe/London" when running date_default_timezone_get(). This timezone is different from ...
-1
votes
1answer
28 views

Search result - 500 error

My Drupal 7 websites started to throw 500 error when I see the search result page. How to replicate: When I enter any keyword and hit search button then I see this URL "http://www.website.com/search/...
0
votes
1answer
19 views

Geofield Map marker NODE ID

I have on Drupal 7 a Geofield Map Views that show a list of "Source" content on a Google Map. I want to add on my marker on the map the information about the NID of the "Source" and I don't know how ...
0
votes
0answers
30 views

How to use replacement patterns as a CSS class for View?

I am trying to figure out how I can use a replacement pattern in the "Other > CSS Class" setting for a view. For example, I would like the View to contain a css class of classname-[nid] with the Node ...
0
votes
0answers
17 views

Bulk edit a user reference field inside a view

I've created a view and enabled bulk edit operations. The field I am interested in changing is of type User Reference. When I attempt to bulk edit the fields, everything works as I'd expect. However, ...
1
vote
1answer
33 views

Why do both Text- and Data comparison seem to not work in my Rules conditions?

I’m using Drupal 7.56, the Rules module 7.x-2.11, and CiviCRM 4.6.31. I've been using the Text comparison and Data comparison conditions. Using the Text comparison condition, the condition is always ...