Closed (fixed)
Project:
Contact Forms
Version:
6.x-1.12
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
11 Mar 2008 at 23:07 UTC
Updated:
17 Apr 2012 at 08:47 UTC
Jump to comment: Most recent file
Comments
Comment #1
1kenthomas commentedSee http://drupal.org/node/166432#comment-765653 for reference.
Comment #2
behindthepage commentedHi 1.kenthomas
I am not suprised that you are having problems as Contact Forms is URL dependant and only modifies the output of the core contact module. This is more of a feature request than a bug report and I suspect a completely separate module to provide blocks for each contact category would work better than trying to get Contact Forms to work how you want it.
regards
Geoff
Comment #3
1kenthomas commentedGeoff,
Self-assigning for now; will look at code and reply. Seems to me it should be simple to exclude the redirect if called from outside /contact* hierarchy, but haven't had time to glance at it.
Comment #4
behindthepage commentedYes this morning I had a thought that you could just remove the redirect as it is only a "covering all bases" part of the module. However your idea is better
line 56 is where it is being redirected. you could add a if $path does not contain "contact" then don't redirect.
You could try this
OR you could add "&& strstr ( $path, 'contact' )" to the if then on line 50.
All the best with it
Geoff
Comment #5
behindthepage commentedComment #6
zyxware commentedI am reopening this. This issue exists in 6.x-1.12 as well.
The drupal_goto would prevent the contact us form to be displayed anywhere else on the site. Why should this module prevent the use of the default contact form in any place other than the /contact/* paths
The alter need to run only on contact forms shown under /contact/* paths. The attached patch takes fixes this by checking for the path before the logic of the alter runs. Checking the path just for the redirect would not work because the subsequent logic requires valid arguments which may not be relevant when the form is not shown under a /contact/* path.
Comment #7
behindthepage commentedGood fix. Thanks.
Comment #8
castroarguello commentedThe patch worked fine for me. Thanks
http://drupal.org/node/233024#comment-5433160
Comment #9
behindthepage commentedComment #10
ben coleman commentedThe fix in #6 works, but I had problems getting the patch file itself to apply. Attached is a redone patch file. I've left off the identifying information so zyxware can get credit when it is applied. I also note this fix doesn't yet show up as applied to -dev.
Comment #11
ben coleman commentedActually, I should say it hasn't been applied to 6.x-1.x branch (for at least what's in the Drupal repository).
Comment #12
behindthepage commentedIt has been applied now.
Thanks to everyone for their work on this issue.
Regards
Geoff
Comment #13
behindthepage commentedComment #14
ben coleman commentedDid this not get pushed to Drupal's repository for 6.x-1.x? It's still not showing up there.
Comment #15
behindthepage commentedSorry I posted too soon. I was about to push it when I realised I need to write a hook_update_N function for another fix I included so have to delay it until I do that.
Note to self - first things first
Regards
Geoff
Comment #16
behindthepage commented