duplicate-field.js
2 years ago
email-reports.js
2 years ago
notices.js
2 years ago
scroll-to-top.js
2 years ago
sticky-sidebar.js
2 years ago
support.js
2 years ago
user-roles.js
1 year ago
support.js
19 lines
| 1 | const $ = jQuery; |
| 2 | |
| 3 | const Support = { |
| 4 | setup() { |
| 5 | if ($('body').hasClass('analytics_page_independent-analytics-support-center')) { |
| 6 | $('#search-field').focus(); |
| 7 | |
| 8 | const form = document.getElementById('search-form') |
| 9 | const searchField = document.getElementById('search-field'); |
| 10 | |
| 11 | form.onsubmit = function(e) { |
| 12 | e.preventDefault(); |
| 13 | window.open('https://independentwp.com/?post_type=kb_article&s=' + searchField.value); |
| 14 | } |
| 15 | } |
| 16 | } |
| 17 | } |
| 18 | |
| 19 | export { Support }; |