Forms are the primary method for obtaining and acting upon user input in Drupal.

learn more… | top users | synonyms (1)

0
votes
0answers
9 views

form from drupal 7 page not opening new page

I need to open a new page from a drupal page when it is an android , so I made a form like this <form target="_blank" name='myform' ...
0
votes
0answers
13 views

Exposed filters not working in form

I am having a strange problem. I have created a block type of view which has an exposed filter with it. I have embedded the view withing a form like this : $form['attached_content_holder'] = array( ...
0
votes
1answer
18 views

How do I build a form with embedded view results

I need to create a sign up form that also displays all of the submitted values above each value on the same page. I have searched for hours and cannot find anything that describes how to achieve ...
0
votes
0answers
10 views

How to prevent the comment form from redirecting?

I have a page with a View listing comments; the comment form is also in this View. After submitting through the comment form I get redirected to the actual comment, however I would like to stay on the ...
0
votes
1answer
32 views

A Multi-step Form to display Database Data at the End

I'm fairly new to Drupal but I'm building a site using Drupal 7. Most of the stuff is pretty standard Drupal things, but one of the things my stakeholders want is a tool that does the following (and ...
0
votes
0answers
9 views

Creating checklist form programatically

I need to create checklist form(s) comprising of a different sets of checks with different ways to enter an answer. The end user (who will prepare checklist) should not need to add fields to the ...
0
votes
2answers
28 views

Alter a field by select list in entity form

I have a problem with Ajax and some fields in my entity form. i have a select list in my form and when i change the selected option i wanna increment another field. To explain better, i can create ...
0
votes
1answer
56 views

Capitalize each word's first letter while entering node with javascript [closed]

I want to capitalize the first character of each word while entering node titles (and some other fields) with JavaScript. For example: First node title -> First Node Title second NODE tiTLe -> ...
0
votes
1answer
31 views

Getting all other checkboxes other than the one checked with jQuery [closed]

Based on my inability to use the FAPI #states property for toggling between two checkboxes (and to pre-empt any questions about why I'm not using radio buttons, it's because each checkbox option has ...
0
votes
0answers
6 views

commerce kickstart add to cart button missing after reset

We've been testing Kickstart 2. I hit the Reset function and re-installed without demo data. I enabled all options -except- the 'Allow Anonymous Users To Access Cart'. Using the default ...
-1
votes
0answers
19 views

append new form with ajax_command_append

My task is to add multiple forms to a page, with a simple select. Eg: user selects an option in select and based on the selection, i need to add new form to the page. I wanted to do this with ...
0
votes
0answers
17 views

Drupal Rooms - How to render the “Book This” form in a node reference full description?

I absolutely love this module, it works great and is exactly what I am looking for. I am hoping to extend the functionality so I can render the "Book this" form on a referenced node rather than the ...
0
votes
2answers
39 views

Adding a validation handler to the registration form

I have altered the registration form to change the thank you message and add the validation of some fields. function mymodule_form_alter(&$form, &$form_state, $form_id) { if ($form_id == ...
0
votes
0answers
44 views

Inserting custom social media icons to nav.bar ( tb-megamenu )

I have been playing around all day and have been trying to get my social media in my navigation bar to the far right for people to click on and be directed to my social media account. I am using tb ...
-1
votes
1answer
25 views

how to alter only one set of specific forms?

Consider I have 3 content type. The problem is that if I use form alter in a module , when I use: drupal_set_message(t($form_id), 'status', FALSE); in the mentioned hook, it shows me different set ...
0
votes
1answer
7 views

How to upload multiple files and predefine filetypes?

Does someone know how it is possible to upload multiple files with the dropbox client module for drupal 7? It would be nice if it could be integrated with plupload. Also i would like to know how i ...
-3
votes
1answer
34 views

hi I'M not getting the textfeild druing module development [closed]

$form['companydetails']['contact name']=array( '#type' => 'textfeild', '#title' => t('Contact name'), ); this is my code but I'm not getting textfeild infront f contactname attribute....im ...
0
votes
1answer
36 views

Using entity form display modes

I have created a custom form display mode my_mode for nodes and wish to display node form using this mode instead of default one at a custom page. How can I do it? ...
6
votes
2answers
357 views

How to check spelling of user typed text in a form textbox

I built a form which have a text field for take input from user. Now I want to implement a spell check module or something which can check spell when user type some word or sentence in the text ...
0
votes
2answers
45 views

How can I protect a disabled form from being submitted?

I need to protect URL alias from being submitted. I've tried setting #disabled, #access, unset(), and what not. It hides the form, but the user is still able to modify the form on the client-side ...
0
votes
3answers
36 views

How to print external html output in form_submit

I have written a form that accepts user's input and based upon the input queries an external site and extracts the html of the result page from the external site. Is there a way to print html inside ...
-2
votes
1answer
25 views

How can I add a captcha to this HTML form [closed]

I wanted to add a captcha box to this form. The past developer added this form as html within the content editor.. how can i integrate the captcha to this form? I'm relatively new to drupal and work ...
-1
votes
1answer
36 views

How to create dynamic multi column forms using native form module?

I am looking to find out how I can create a form which the definition of the form is coming from a REST API as a JSON object. The form can be 1 column, 2 columns or 10 columns. I have been able to do ...
0
votes
0answers
34 views

Using variable_get with select in a table [closed]

Sorry if this has been asked before - I've looked and I can't find anything specific. I'm making an admin form for Drupal 7 that will allow users of a SaaS CRM (Capsule) to integrate it with Drupal ...
0
votes
2answers
36 views

Move fields from additional settings to field_group on node edit forms

I try to move some settings, for example the comment or menu settings, from the "additional settings" to my own field group created with the Field Group module. As there is no way to access the ...
0
votes
1answer
23 views

Unable to print form submission result

The structure of my form is as follows: Form is built here function mymodule_member_search_form The form submission processing happens in the callback function ...
0
votes
0answers
16 views

Advanced hook_form_alter #required option

I have a form, build by content type with not required field. To this form i added additional submit button with custom submit function (using hook_form_alter). So the form looks like this ...
0
votes
1answer
9 views

Views form page with input fields

How can I make Views form page with such input fields? Such view can really help to change meanings of some node field all at once.
0
votes
0answers
13 views

Drupal Ajax Form and Output Toggle

I want to a a block with data, say DATA One DATA Two Edit Data When I click button Edit Data, It should replace data with form fields, i-e Field One and Field Two, with a submit button, after ...
1
vote
0answers
18 views

Updating multiple elements in Form Ajax Callback [duplicate]

The Form In a Drupal Form I have (amongst other elements): Two select lists: Retailers, Products. One Table select: Selected Products. Two buttons: Add, Remove The Functionality I want: The ...
2
votes
4answers
241 views

Populate multiselect options onchange of dropdown using AJAX

I have created a content type (Geological Locations) with 2 fields, Country and States. The Country field is a select box, and States field is a multiselect. So if i select a Country, the States ...
0
votes
1answer
56 views

Create custom form and store form data into database [closed]

I am start working with Drupal just some days ago. I am really a amateur in Drupal . I just want to know how can I create a form in Drupal with textbox or check-boxes and store the value of the form ...
0
votes
1answer
21 views

Remove order from Field Collection set in form

I am using the Field Collection and Field Collection Fieldset modules to group a set of elements in my form. But what i see in the form is an Order column for the fieldset items, which i would like to ...
0
votes
0answers
37 views

Display search result in a form

I am building a simple custom module to search a certain node type and displaying it in the same page as the form. It is like the search function. The problem is how to display the result below the ...
0
votes
0answers
35 views

Why do I have an infinite loop in the Inline Entity Form module?

I have an AJAX callback that is timing out due to an infinite loop in the Inline Entity Form module, specifically in the inline_entity_form_get_element() function. My single AJAX callback is calling ...
0
votes
0answers
13 views

How to add placeholder to all Drupal 7 text forms using Drupal API? [duplicate]

I'm trying to add the placeholders from field Description to all Drupal 7 text forms. Only in node page, not webforms etc. And even hide dubbed field Description. I want to use only Drupal API without ...
0
votes
4answers
83 views

How to add placeholder to all Drupal 7 text forms in node page?

I'm trying to add the placeholders from field description to all Drupal 7 text forms only in node page using Drupal API I've created a module that overrides hook_form_alter <?php function ...
0
votes
1answer
42 views

ajax modified form drop down doesn't save

I have used form_alter to add a ajax callback to an element to my form. When the user chooses an option, it creates dropdown options for the other field. However, while this works fine for changing ...
0
votes
1answer
46 views

Help text blocks show up randomly in node add/edit form with Drupal Bootstrap theme

I come to you this morning because I can't get rid of this display bug. I set a Help text for all my content-type's fields to guide my users in the node add/edit forms. However, these text blocks ...
1
vote
1answer
35 views

Show table contents in custom Form

I have a table named "Table1" in my Drupal, where I added fields by getting the inputs via form. The form is created by custom module. My next requirement was to again create another form, but this ...
0
votes
0answers
8 views

Avoid using go_to() in the submit function but return to a fragment of the page [duplicate]

I have a e-commerce site whose landing page lists available products. Now you can mix and match any of them - Am using checkboxes to let the user interact with the products. At the end of the form I ...
1
vote
0answers
58 views

Drupal 7 - how to add custom field token to webform default value?

I want to add node-field data into the web from block via tokes as with Webform 7.x-4.1 this should work. But tokens from custom fields are not available in a webform(block) ? [node:title] and ...
1
vote
2answers
23 views

Change content of email verification email based on gender provided by user

In my website when a user submits the registration form and email verification is sent to them. Is there a way to change the content of the verification email that is sent after the user submits the ...
0
votes
1answer
87 views

How to theme form elements in a custom field widget?

I'm creating a custom telephone field and I'm a bit confused at how to go about theming the widget. I have four elements in my implementation of hook_field_widget_form()... A dropdown for the ...
0
votes
0answers
23 views

How to override form_error in webform_validate_unique function provided by webform.components.inc

I have a Webform module provided form that will be used by anonymous users. I need to avoid duplicate submissions from the same user, but can't rely on cookies or IP address (multiple users at same ...
0
votes
1answer
26 views

Add markup before form output for user-login

I've created a template override for the user login form (user-login.tpl.php) and want to put some content before the form's elements (e.g, header text and copy). Anything you add in ...
0
votes
3answers
48 views

How to create a multi step form that can be saved/edited by multiple users?

I need some tips on how to implement a form with these specifications: Multi steps. for example the user completes section 1 then clicks next to go to section 2 and so on (can be tabs or anything ...
0
votes
1answer
26 views

Add Nested <ul> List into $form

I have something like this. How can I make $upload_items be a nested <ul> list under Upload examples Something like <ul> <li> Upload Ex </li> <ul> ...
0
votes
0answers
19 views

using views and unsaved fields

I have two numeric fields on a content type. I wanted to be able to show a mathematical calculation of these fields on the content add form in real time as they are being updated. If it was a node I ...
0
votes
0answers
10 views

Drupal form placeholder [duplicate]

I made a form using the custom module "homepage_userlogin". I want a placeholder in my form. The code of the custom module is: <?php function homepage_userlogin_form($form_state){ $form = ...