Breaks Webform
EclipseGc - September 30, 2008 - 22:49
| Project: | Webform Associate |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | EclipseGc |
| Status: | needs review |
Jump to:
Description
Currently webform associate breaks webform itself. Should be fixable, probably somewhere in the big form alter stuff that's going on. Just needs to check if we're currently on a webform node and if that webform node doesn't have an associated node, then node do the form alter work.

#1
I'm using the last version of webform and webform_associate and I'm not experiencing any problem at all...
#2
Might be some of the new code I WAS running. My next patch will fix this again.
#3
Newest code SHOULD fix this.
It needs testing w/ and w/o the uc_webform_productize module installed, however I believe it continues to work both ways. Checkout from CVS if you can't wait till the next dev tar gets produced. 4hrs still new tar is created.
#4
Still breaks Webform by the looks of it.
Running Drupal 6.6, just installed Webform 6.x-2.3 and Webform Associate 6.x-1.x-dev.
Spent the past 4 hours trying to figure out how to create a webform as it kept coming up with "You are not authorized to access this page.", wasn't until I disabled Webform Associate that I could get Webform to work.
Sorry, still a newbie so not much else I can tell you.
#5
I get the same message: "You are not authorized to access this page"
Any hints as to fix? Is there a permission or role to add somewhere?
cheers,
allanx
#6
I found that as soon as you choose a content type for webform associate it fixes the webform.
It looks like the "webform_associate_nodes" variable needs to be created.
The problem appears to be in the function:
function webform_associate_menu_access($func, $arguments = array(), $node = NULL, $a3 = NULL) {$vars = variable_get('webform_associate_nodes', array());
foreach ($vars as $var) {
if ($node->type == $var || $node->type == 'webform') {
switch ($func) {
case 'node_access':
return $func($arguments[0], $node->nid);
break;
case 'user_access':
return $func($arguments[0]);
break;
case 'webform_submission_access':
if (!$a3) {
return $func($node->nid, '', $arguments[2]);
}
else {
return $func($node->nid, $a3, $arguments[2]);
}
break;
}
}
else {
return FALSE;
}
}
}
If there is not any webform_associate_nodes then the function returns false and does not give access.