CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Question on Webform
Pages: [1] 2

Author Topic: Question on Webform  (Read 1647 times)

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Question on Webform
May 13, 2012, 08:27:12 pm
this one may be really obvious...could someone advise pls...is there a way to search responses to created webforms in the advanced search of civi. We see the way to create an activity for the various form submissions, but how about if if you want to search by response to individual form data fields in the advanced search (ie, not just from the profile fields) Any thoughts? H

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Re: Question on Webform
May 13, 2012, 08:48:40 pm
to be a bit more specific :  is there a way to run searches in civi on the data elicited through whatever fields have been configured on the web form, for example, those "non civi (or profile)" fields that would display at /webform-results/table

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Question on Webform
May 13, 2012, 08:53:51 pm
not following (yet) - were the fields you are looking for created in civi and used in webform - or just created in webform? if the latter, then no.
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Re: Question on Webform
May 13, 2012, 09:17:08 pm
Peter, they would be created in the webform itself, in other words, you would have favorite color and be able to search responses, ie, everyone saying red, and pull up civi search results of all who answered accordingly. Although your response is making me think, you maybe could configure custom data fields (if you know the options for each answer) load them into a profile, load the profile with the webform and have the logged in user simply select those? Not sure if you could search by response that way tho...

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Question on Webform
May 13, 2012, 09:20:13 pm
i still don't quite follow as unsure where 'profile' fits in the scenario with webform

if you want to search data in civi you need the fields in civi not just in webform
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Re: Question on Webform
May 13, 2012, 09:43:42 pm
probably because I'm completely mislabeling it  :) I only mean the fields that load automatically from civicrm when you;re logged in, completing any web form, so i suppose not a profile just civi fields associated to that particular form. But I think you've answered it, which is they would have to be custom data values in civi that the user would select. For example if you want the user to tell you which county they live in, you would create the custom data set, load it as part of the civi fields associated with that webform (a better way to say it?) they they could tell us which county. From there search the responses and by activity types associated for the submission of that form maybe...just trying to avoid building a whole separate content node and hooking it into civi but sounds like that may end up being the way to go...thanks peter!

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Question on Webform
May 13, 2012, 09:49:48 pm
nope - if you want to know what country someone lives in then you use some of the Core Address fields including 'country' and then they fill it in and then you search in Adv Search for that data.
but i think we are still a way from understanding each other.

In civi there are core and custom fields.
Custom fields can be for Contact, or Participants, or Memberships, Activities etc

Some of those can be accessed via a Webform.

If you are collecting such data then you should be able to search for it via Advanced Search in CiviCRM
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Re: Question on Webform
May 13, 2012, 09:57:10 pm
Ok, we'll check those out in more detail ...thx! H

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Question on Webform
May 14, 2012, 01:19:05 pm
I second what Pete said: never create a custom field for something that's already in core (like country).
If you want your webform fields stored in civi and they don't tie to core fields you'll need to make custom fields. Profiles don't have anything to do with it (the webform is serving that role).
The two main choices are to create custom contact fields or activity fields. Contact fields are more or less permanently stored with the contact, so use that when appropriate (like height, weight, favorite color etc). Activity fields are stored with the activity and are better suited to when the data might be different each time the form is submitted - like "favorite color this week."
Try asking your question on the new CiviCRM help site.

Hardwick

  • I post frequently
  • ***
  • Posts: 124
  • Karma: 1
  • CiviCRM version: 4.0.5
Re: Question on Webform
May 14, 2012, 09:43:00 pm
Hey Coleman,

thanks for weighing in on this...yeah i see now what you and Peter mean about the activities and other types of custom data fields to deal with the kind of info we're trying to elicit. Its more of the latter (fave flavor) variety, not the core address fields we were curious about. the example I give above actually says "county," not country so if that was core it would be fantastic as we often find ourselves creating hundreds of custom data "multiple choice selections." it would be a godsend if that info (and things like township, arrondissement, etc.) were actually stored in the core by US State (and could load like "state"), but I'm guessing not...another huge help would be if, for that many fields, instead of having to create ten multiple choice selections then the next 90 one at a time, if we could somehow type in like a hundred at once (or each time), e.g. custom/group/field/option?reset=1&action=browse&gid=10&fid=190 - although, that probably goes beyond our discussion here.

Unfortunately it looks like the site in question is also throwing some sort of null error on the Drupal side when we try to save a webform (or any node) for the custom data types you mention; appears we need to do a php update before exploring as you recommend.

Its very tempting with webform module to try to use it in all these situations, however we find many times we are dealing with conceptual data entities whose attributes are complex enough to require numerous fields that relate to civi records and each other in ways that indicate drupal cck/views.

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Question on Webform
May 16, 2012, 01:16:43 pm
Actually, county is a core field, but it is not currently supported by webform. You could help fix this :)
Try asking your question on the new CiviCRM help site.

championofliberty

  • I’m new here
  • *
  • Posts: 6
  • Karma: 0
  • CiviCRM version: 4.2.8
  • CMS version: Drupal 7.20
  • MySQL version: 5.5.28-cll
  • PHP version: 5.3.18
Re: Question on Webform
March 17, 2013, 02:00:25 pm
+1 for county webform integration.

I am pretty novice at programming, but how would one go about helping to implement this?

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Question on Webform
March 17, 2013, 08:32:04 pm
Here's how: http://drupalcode.org/project/webform_civicrm.git/commitdiff/0b45b8b?hp=33e79e3a583d8b8c3773e573db90a9b14f1e6dba
I've committed this code so county field will now be available to webforms :)
Try asking your question on the new CiviCRM help site.

championofliberty

  • I’m new here
  • *
  • Posts: 6
  • Karma: 0
  • CiviCRM version: 4.2.8
  • CMS version: Drupal 7.20
  • MySQL version: 5.5.28-cll
  • PHP version: 5.3.18
Re: Question on Webform
March 18, 2013, 09:34:51 am
WOW! Thanks for the ultra super fast response!

I updated the module and while testing I found some issues.

The county field does not populate according to the state selected. It loads with every county from every state in the database. In troubleshooting this, I was getting an error when I attempted to edit the county form component.
Code: [Select]
Fatal error: Maximum execution time of 30 seconds exceeded in /home/miclcom/public_html/includes/common.inc on line 6582
On a different subject,  Is there a way to update the module without having to turn CiviCRM processing back on and re-create all the CiviCRM fields in existing forms?

Thanks again for your help! It would have taken me probably 16 hours to figure out how to implement the county field. I want to send a donation because of your help with this. Should I send it to for the "Make it happen" initiative? Also should I put anything special in the "Please provide instructions as to what to do with your contribution if this Make-it-Happen initiative is not sufficiently funded." field?

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Question on Webform
March 18, 2013, 10:50:10 am
Ok, so much for the simple approach. I'm going to have to add an ajax handler to the field so it can refresh "on-the-fly" based on state selection and will take me a few hours to implement. Can you donate something appropriate for that to CiviCRM and let me know when you have done so? http://civicrm.org/civicrm/contribute/transact?reset=1&id=19

As for updating the module, you should not need to disable or redo anything, just replace the old webform_civicrm directory in your modules folder with the new one and you're good to go. Sometimes you also need to visit the drupal upgrades page to update the database, but you don't need to do that for this change.
Try asking your question on the new CiviCRM help site.

Pages: [1] 2
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Question on Webform

This forum was archived on 2017-11-26.