| 60 |
case 13: // enter |
case 13: // enter |
| 61 |
input.blur(); |
input.blur(); |
| 62 |
e.preventDefault(); |
e.preventDefault(); |
| 63 |
|
|
| 64 |
|
//----- If the search module is installed, and the config option is checked, then pass the search terms |
| 65 |
|
//----- along to the search module if the "enter" key is pressed. |
| 66 |
|
var delta = $(input).parent().siblings('#edit-dynosearcho-delta').val(); |
| 67 |
|
var searchon = $('#edit-dynosearcho-integrated-search-' + delta).val(); |
| 68 |
|
if (searchon == 1) { |
| 69 |
|
//----- figure out the correct path to the Drupal search |
| 70 |
|
var basepath = $('#edit-dynosearcho-basepath-' + delta).val(); |
| 71 |
|
var useq = $('form#dynosearcho_search_form_' + delta).attr('action'); |
| 72 |
|
if (useq.indexOf("?q=") > 0) { |
| 73 |
|
window.location.href = basepath + "?q=search/node/" + Drupal.encodeURIComponent(this.input.value); |
| 74 |
|
} else { |
| 75 |
|
window.location.href = basepath + "search/node/" + Drupal.encodeURIComponent(this.input.value); |
| 76 |
|
} |
| 77 |
|
} |
| 78 |
} |
} |
| 79 |
} |
} |
| 80 |
|
|
|
|
|
| 81 |
/** |
/** |
| 82 |
* Handler for the "keyup" event |
* Handler for the "keyup" event |
| 83 |
*/ |
*/ |