#20714 closed enhancement (fixed)
Theme customizer: Impossible to preview a search results page
Reported by: | johnbillion | Owned by: | westonruter |
---|---|---|---|
Milestone: | 4.7 | Priority: | normal |
Severity: | normal | Version: | 3.4 |
Component: | Customize | Keywords: | has-patch commit |
Focuses: | javascript | Cc: |
Description
Steps to reproduce:
- Open the theme customizer
- Attempt to do a search in the site's search box in order to preview the search results page
The form won't submit and you won't be able to preview your search results.
Attachments (1)
Change History (22)
#3
@
12 years ago
Since it's not implemented, yes, all forms are disabled yet.
See http://core.trac.wordpress.org/browser/trunk/wp-includes/js/customize-preview.dev.js#L40
#4
@
12 years ago
- Type changed from defect (bug) to enhancement
By design. Setting this to an enhancement.
#6
@
10 years ago
Actually, you can preview a search results page. You just can't access the search results by navigating within the customizer. The workaround is to do the search on the frontend, and then on the search results page, access the Customize link from the admin bar, and it will load up the Customizer with the preview open to that search results page, e.g.: http://src.wordpress-develop.dev/wp-admin/customize.php?url=http%3A%2F%2Fsrc.wordpress-develop.dev%2F%3Fs%3Dtest
This ticket was mentioned in IRC in #wordpress-dev by westonruter. View the logs.
10 years ago
#10
@
10 years ago
I've been working on this as a part of #30028, which would ensure that the Customizer can be used to preview all form submissions and even Ajax requests.
#11
@
10 years ago
Previewing of form submissions (both POST and GET requests), as well as jQuery Ajax requests, have been implemented at https://github.com/xwp/wordpress-develop/pull/61
This ticket was mentioned in Slack in #core-customize by westonruter. View the logs.
9 years ago
This ticket was mentioned in Slack in #core-customize by celloexpressions. View the logs.
8 years ago
#15
@
8 years ago
- Milestone changed from 4.6 to Future Release
Punting due to transactions being too large to finish patch and test in time for 4.6.
#16
@
8 years ago
- Milestone changed from Future Release to 4.7
- Owner set to westonruter
- Status changed from new to accepted
I just realized a very simple fix for this, and it's not dependent on transactions at all. All we have to do is listen for form submit
events and if the form has a GET
request method and if the action
points to a URL for the current WP instance, then we can just serialize
the form's data and amend it to the action
URL and send this new URL in the url
message to the Customizer pane, just as happens when clicking a regular link. See https://github.com/xwp/wp-customize-snapshots/pull/72/files#diff-56102a3fdc293b051600c9ab9fedc164R145
#17
@
8 years ago
- Keywords has-patch added; needs-patch removed
@johnbillion how does 20714.0.diff work for you?
Confirmed. Since normal links do work, I assume it would also be possible for GET forms to work as well. Not sure about POST forms.