Grabbed latest dev release of nodereference explorer
Using modalframe 6.x-1.4
Using custom zen sub-theme, but I tried it with another theme and got the same result.
Works fine in firefox. Works fine in IE except for inability to submit from modalframe pop-up.
The exposed filters are working correctly and updating the frame, but the actual submit button is not doing anything.
I looked at the generated code and found what might be causing the problem.
While the html validates, I received the error of a nested form:
In the modalframe, the form with id "views-exposed-form-nodereference-explorer-default-table" (I'm using the default view) is nested inside the form with id "nodereference-explorer-dialog-form" (generated .
I've created a simple HTML test to see if this was the issue, and it looks like I can replicate the issue with the following code:
<form id="form1" action="" method="get">
<form id="form2">
<input type="text" value="test 1" id="test1" name="test1" />
<!-- This button will work, just as the exposed filters are working -->
<input type="submit" value="submit 1" />
</form>
<input type="text" value="test 2" id="test2" name="test2" />
<!-- This button will NOT work, and the form will not be submitted,
which is the same behavior I'm seeing with the dialog
-->
<input type="submit" value="submit 2" />
</form>
Comments
Comment #1
socratesone commentedOn the file includes/nodereference_explorer.menu.inc, on line 100, the line to enter the filters is commented out. This line allows the filters to be included in the appropriate place in the template. (theme/nodereference-explorer-dialog.tpl.php).
However, when this line is uncommented back in, there are two sets of filters being presented.
One looks like it is doing the correct thing (adding the filters without a form), and the other the incorrect thing (adding the filters nested in their own form). The correct one is being output by the template, via the filters that are being commented out. The incorrect one is being output by views, because the display is being rendered completely, and the filters are a part of the display.
The output for the display is being generated in the function get_display(), found on line 126 of nodereference_explorer.views.class.inc. It is this output that is causing the problem.
I'm not familiar with the views API. Is there a way to remove the exposed filters when generating the display with views_embed_view() or prior to it by doing something with the view object? Setting filters in the array to null, for instance?
I've tried to debug this, but have had no luck so far, as everything I touch seems to be breaking something else. I'm fairly skilled with PHP, and have a solid working knowledge of Drupal internals, but my knowledge of the views API and of this module is limited.
I've decided to leave this bug report as-is and attempt to revert to a previous version of the module.
Comment #2
gnindl commentedIssue #539808: Exposed filters handles the same problem. Avoiding nested form is done by separating the dialog from the submit form which holds the info about the selection. Check out the current development snapshot for further testing.
Comment #3
jasonawantsubmit buttons works in ie7 and ie8. however, after submitting image selection and when saving or previewing the content item in ie7, ie7 unexpectedly crashes.
Comment #4
gnindl commented#3 is probably client specific. For most common cases this issue should be resolved.