This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Implements hook_field_attach_validate(). | |
*/ | |
function pu_misc_field_attach_validate($entity_type, $entity, &$errors) { | |
// If this entity has the body field attached to it, scan it to ensure that | |
// the user is not saving any embedded content over http://. This will prevent | |
// mixed content warnings when the site is viewed over https://. | |
if (isset($entity->body)) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Selectize doesn't support returning a "no results" message. This plugin | |
// tries to add the capability to display a no results message. | |
// Note that it won't actually display the message here automatically. | |
// Instead we show the empty results container manually in our AJAX callback | |
// when we load options dynamically and there are no results. | |
// See https://github.com/brianreavis/selectize.js/issues/470 | |
Selectize.define('no_results', function( options ) { | |
var self = this; |