Update to Drupal 8.0.0 beta 14. For more information, see https://drupal.org/node/2544542
This commit is contained in:
parent
3b2511d96d
commit
81ccda77eb
2155 changed files with 54307 additions and 46870 deletions
|
@ -1,14 +0,0 @@
|
|||
/**
|
||||
* @file
|
||||
* Styles for administration pages.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Add search page select/submit.
|
||||
*/
|
||||
.search-admin-settings .container-inline {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
.search-admin-settings label[for="edit-search-type"] {
|
||||
display: block;
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
/**
|
||||
* @file
|
||||
* Stylesheet for results generated by the Search module.
|
||||
*/
|
||||
ol.search-results {
|
||||
list-style: none;
|
||||
}
|
25
core/modules/search/migration_templates/d6_search_page.yml
Normal file
25
core/modules/search/migration_templates/d6_search_page.yml
Normal file
|
@ -0,0 +1,25 @@
|
|||
id: d6_search_page
|
||||
label: Drupal 6 search page configuration
|
||||
migration_tags:
|
||||
- Drupal 6
|
||||
source:
|
||||
plugin: variable
|
||||
variables:
|
||||
- node_rank_comments
|
||||
- node_rank_promote
|
||||
- node_rank_recent
|
||||
- node_rank_relevance
|
||||
- node_rank_sticky
|
||||
- node_rank_views
|
||||
constants:
|
||||
id: node_search
|
||||
path: node
|
||||
plugin: node_search
|
||||
process:
|
||||
id: 'constants/id'
|
||||
path: 'constants/path'
|
||||
plugin: 'constants/plugin'
|
||||
'configuration/rankings':
|
||||
plugin: d6_search_configuration_rankings
|
||||
destination:
|
||||
plugin: entity:search_page
|
|
@ -0,0 +1,22 @@
|
|||
id: d6_search_settings
|
||||
label: Drupal 6 search configuration
|
||||
migration_tags:
|
||||
- Drupal 6
|
||||
source:
|
||||
plugin: variable
|
||||
constants:
|
||||
status: true
|
||||
variables:
|
||||
- minimum_word_size
|
||||
- overlap_cjk
|
||||
- search_cron_limit
|
||||
- search_tag_weights
|
||||
- search_and_or_limit
|
||||
process:
|
||||
'index/minimum_word_size': minimum_word_size
|
||||
'index/overlap_cjk': overlap_cjk
|
||||
'index/cron_limit': search_cron_limit
|
||||
logging: 'constants/status'
|
||||
destination:
|
||||
plugin: config
|
||||
config_name: search.settings
|
|
@ -1,10 +0,0 @@
|
|||
drupal.search.results:
|
||||
version: VERSION
|
||||
css:
|
||||
theme:
|
||||
css/search.theme.css: {}
|
||||
|
||||
admin:
|
||||
css:
|
||||
theme:
|
||||
css/search.admin.css: {}
|
|
@ -8,7 +8,6 @@
|
|||
use Drupal\Component\Utility\SafeMarkup;
|
||||
use Drupal\Component\Utility\Html;
|
||||
use Drupal\Component\Utility\Unicode;
|
||||
use Drupal\Component\Utility\Xss;
|
||||
use Drupal\Core\Cache\Cache;
|
||||
use Drupal\Core\Form\FormStateInterface;
|
||||
use Drupal\Core\Routing\RouteMatchInterface;
|
||||
|
@ -768,7 +767,7 @@ function search_excerpt($keys, $text, $langcode = NULL) {
|
|||
// Highlight keywords. Must be done at once to prevent conflicts ('strong'
|
||||
// and '<strong>').
|
||||
$text = trim(preg_replace('/' . $boundary . '(?:' . implode('|', $keys) . ')' . $boundary . '/iu', '<strong>\0</strong>', ' ' . $text . ' '));
|
||||
return Xss::filter($text, ['strong']);
|
||||
return SafeMarkup::xssFilter($text, ['strong']);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -137,8 +137,6 @@ class SearchController extends ControllerBase {
|
|||
'#type' => 'pager',
|
||||
);
|
||||
|
||||
$build['#attached']['library'][] = 'search/drupal.search.results';
|
||||
|
||||
return $build;
|
||||
}
|
||||
|
||||
|
|
|
@ -112,6 +112,7 @@ abstract class SearchPageFormBase extends EntityForm {
|
|||
'#field_prefix' => 'search/',
|
||||
'#default_value' => $this->entity->getPath(),
|
||||
'#maxlength' => '255',
|
||||
'#required' => TRUE,
|
||||
);
|
||||
$form['plugin'] = array(
|
||||
'#type' => 'value',
|
||||
|
@ -144,8 +145,8 @@ abstract class SearchPageFormBase extends EntityForm {
|
|||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function validate(array $form, FormStateInterface $form_state) {
|
||||
parent::validate($form, $form_state);
|
||||
public function validateForm(array &$form, FormStateInterface $form_state) {
|
||||
parent::validateForm($form, $form_state);
|
||||
|
||||
// Ensure each path is unique.
|
||||
$path = $this->entityQuery->get('search_page')
|
||||
|
|
|
@ -0,0 +1,34 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\search\Plugin\migrate\destination\EntitySearchPage.
|
||||
*/
|
||||
|
||||
namespace Drupal\search\Plugin\migrate\destination;
|
||||
|
||||
use Drupal\Core\Entity\EntityInterface;
|
||||
use Drupal\migrate\Plugin\migrate\destination\EntityConfigBase;
|
||||
use Drupal\migrate\Row;
|
||||
|
||||
/**
|
||||
* @MigrateDestination(
|
||||
* id = "entity:search_page"
|
||||
* )
|
||||
*/
|
||||
class EntitySearchPage extends EntityConfigBase {
|
||||
|
||||
/**
|
||||
* Updates the entity with the contents of a row.
|
||||
*
|
||||
* @param \Drupal\Core\Entity\EntityInterface $entity
|
||||
* The search page entity.
|
||||
* @param \Drupal\migrate\Row $row
|
||||
* The row object to update from.
|
||||
*/
|
||||
protected function updateEntity(EntityInterface $entity, Row $row) {
|
||||
$entity->setPlugin($row->getDestinationProperty('plugin'));
|
||||
$entity->getPlugin()->setConfiguration($row->getDestinationProperty('configuration'));
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\search\Plugin\migrate\process\d6\SearchConfigurationRankings.
|
||||
*/
|
||||
|
||||
namespace Drupal\search\Plugin\migrate\process\d6;
|
||||
|
||||
use Drupal\migrate\ProcessPluginBase;
|
||||
use Drupal\migrate\MigrateExecutableInterface;
|
||||
use Drupal\migrate\Row;
|
||||
|
||||
/**
|
||||
* Generate configuration rankings.
|
||||
*
|
||||
* @MigrateProcessPlugin(
|
||||
* id = "d6_search_configuration_rankings"
|
||||
* )
|
||||
*/
|
||||
class SearchConfigurationRankings extends ProcessPluginBase {
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* Generate the configuration rankings.
|
||||
*/
|
||||
public function transform($value, MigrateExecutableInterface $migrate_executable, Row $row, $destination_property) {
|
||||
$return = array();
|
||||
foreach ($row->getSource() as $name => $rank) {
|
||||
if (substr($name, 0, 10) == 'node_rank_' && $rank) {
|
||||
$return[substr($name, 10)] = $rank;
|
||||
}
|
||||
}
|
||||
return $return;
|
||||
}
|
||||
|
||||
}
|
|
@ -108,7 +108,7 @@ class Search extends FilterPluginBase {
|
|||
if (!$form_state->isValueEmpty($key)) {
|
||||
$this->queryParseSearchExpression($form_state->getValue($key));
|
||||
if (count($this->searchQuery->words()) == 0) {
|
||||
$form_state->setErrorByName($key, $this->formatPlural(\Drupal::config('search.settings')->get('index.minimum_word_size'), 'You must include at least one positive keyword with 1 character or more.', 'You must include at least one positive keyword with @count characters or more.'));
|
||||
$form_state->setErrorByName($key, $this->formatPlural(\Drupal::config('search.settings')->get('index.minimum_word_size'), 'You must include at least one keyword to match in the content, and punctuation is ignored.', 'You must include at least one keyword to match in the content. Keywords must be at least @count characters, and punctuation is ignored.'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -260,11 +260,6 @@ class SearchPageListBuilder extends DraggableListBuilder implements FormInterfac
|
|||
'#attributes' => array(
|
||||
'class' => array('container-inline'),
|
||||
),
|
||||
'#attached' => [
|
||||
'library' => [
|
||||
'search/admin',
|
||||
],
|
||||
],
|
||||
);
|
||||
// In order to prevent validation errors for the parent form, this cannot be
|
||||
// required, see self::validateAddSearchPage().
|
||||
|
|
|
@ -0,0 +1,50 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\search\Tests\d6\Migrate\SearchConfigsTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\search\Tests\Migrate\d6;
|
||||
|
||||
use Drupal\config\Tests\SchemaCheckTestTrait;
|
||||
use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase;
|
||||
|
||||
/**
|
||||
* Upgrade variables to search.settings.yml.
|
||||
*
|
||||
* @group search
|
||||
*/
|
||||
class MigrateSearchConfigsTest extends MigrateDrupal6TestBase {
|
||||
|
||||
use SchemaCheckTestTrait;
|
||||
|
||||
/**
|
||||
* Modules to enable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $modules = array('search');
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
$this->loadDumps(['Variable.php']);
|
||||
$this->executeMigration('d6_search_settings');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests migration of search variables to search.settings.yml.
|
||||
*/
|
||||
public function testSearchSettings() {
|
||||
$config = $this->config('search.settings');
|
||||
$this->assertIdentical(3, $config->get('index.minimum_word_size'));
|
||||
$this->assertIdentical(TRUE, $config->get('index.overlap_cjk'));
|
||||
$this->assertIdentical(100, $config->get('index.cron_limit'));
|
||||
$this->assertIdentical(TRUE, $config->get('logging'));
|
||||
$this->assertConfigSchema(\Drupal::service('config.typed'), 'search.settings', $config->get());
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,70 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\search\Tests\Migrate\d6\MigrateSearchPageTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\search\Tests\Migrate\d6;
|
||||
|
||||
use Drupal\migrate\MigrateExecutable;
|
||||
use Drupal\Core\Database\Database;
|
||||
use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase;
|
||||
|
||||
/**
|
||||
* Upgrade search rank settings to search.page.*.yml.
|
||||
*
|
||||
* @group search
|
||||
*/
|
||||
class MigrateSearchPageTest extends MigrateDrupal6TestBase {
|
||||
|
||||
/**
|
||||
* The modules to be enabled during the test.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
static $modules = array('node', 'search');
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
$this->loadDumps(['Variable.php']);
|
||||
$this->executeMigration('d6_search_page');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests Drupal 6 search settings to Drupal 8 search page entity migration.
|
||||
*/
|
||||
public function testSearchPage() {
|
||||
$id = 'node_search';
|
||||
/** @var \Drupal\search\Entity\SearchPage $search_page */
|
||||
$search_page = entity_load('search_page', $id);
|
||||
$this->assertIdentical($id, $search_page->id());
|
||||
$configuration = $search_page->getPlugin()->getConfiguration();
|
||||
$this->assertIdentical($configuration['rankings'], array(
|
||||
'comments' => 5,
|
||||
'relevance' => 2,
|
||||
'sticky' => 8,
|
||||
'views' => 1,
|
||||
));
|
||||
$this->assertIdentical('node', $search_page->getPath());
|
||||
|
||||
// Test that we can re-import using the EntitySearchPage destination.
|
||||
Database::getConnection('default', 'migrate')
|
||||
->update('variable')
|
||||
->fields(array('value' => serialize(4)))
|
||||
->condition('name', 'node_rank_comments')
|
||||
->execute();
|
||||
|
||||
$migration = entity_load_unchanged('migration', 'd6_search_page');
|
||||
$executable = new MigrateExecutable($migration, $this);
|
||||
$executable->import();
|
||||
|
||||
$search_page = entity_load('search_page', $id);
|
||||
$configuration = $search_page->getPlugin()->getConfiguration();
|
||||
$this->assertIdentical(4, $configuration['rankings']['comments']);
|
||||
}
|
||||
|
||||
}
|
|
@ -40,13 +40,11 @@ class SearchAdvancedSearchFormTest extends SearchTestBase {
|
|||
}
|
||||
|
||||
/**
|
||||
* Test using the search form with GET and POST queries.
|
||||
* Test using the advanced search form to limit search to nodes of type "Basic page".
|
||||
* Tests advanced search by node type.
|
||||
*/
|
||||
function testNodeType() {
|
||||
// Verify some properties of the node that was created.
|
||||
$this->assertTrue($this->node->getType() == 'page', 'Node type is Basic page.');
|
||||
|
||||
// Assert that the dummy title doesn't equal the real title.
|
||||
$dummy_title = 'Lorem ipsum';
|
||||
$this->assertNotEqual($dummy_title, $this->node->label(), "Dummy title doesn't equal node title.");
|
||||
|
||||
|
@ -63,11 +61,56 @@ class SearchAdvancedSearchFormTest extends SearchTestBase {
|
|||
$this->drupalPostForm('search/node', $edit, t('Advanced search'));
|
||||
$this->assertText($this->node->label(), 'Basic page node is found with POST query.');
|
||||
|
||||
// Advanced search type option.
|
||||
// Search by node type.
|
||||
$this->drupalPostForm('search/node', array_merge($edit, array('type[page]' => 'page')), t('Advanced search'));
|
||||
$this->assertText($this->node->label(), 'Basic page node is found with POST query and type:page.');
|
||||
|
||||
$this->drupalPostForm('search/node', array_merge($edit, array('type[article]' => 'article')), t('Advanced search'));
|
||||
$this->assertText('search yielded no results', 'Article node is not found with POST query and type:article.');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests that after submitting the advanced search form, the form is refilled.
|
||||
*/
|
||||
function testFormRefill() {
|
||||
$edit = array(
|
||||
'keys' => 'cat',
|
||||
'or' => 'dog gerbil',
|
||||
'phrase' => 'pets are nice',
|
||||
'negative' => 'fish snake',
|
||||
'type[page]' => 'page',
|
||||
);
|
||||
$this->drupalPostForm('search/node', $edit, t('Advanced search'));
|
||||
|
||||
// Test that the encoded query appears in the page title. Only test the
|
||||
// part not including the quote, because assertText() cannot seem to find
|
||||
// the quote marks successfully.
|
||||
$this->assertText('Search for cat dog OR gerbil -fish -snake');
|
||||
|
||||
// Verify that all of the form fields are filled out.
|
||||
foreach ($edit as $key => $value) {
|
||||
if ($key != 'type[page]') {
|
||||
$elements = $this->xpath('//input[@name=:name]', array(':name' => $key));
|
||||
$this->assertTrue(isset($elements[0]) && $elements[0]['value'] == $value, "Field $key is set to $value");
|
||||
}
|
||||
else {
|
||||
$elements = $this->xpath('//input[@name=:name]', array(':name' => $key));
|
||||
$this->assertTrue(isset($elements[0]) && !empty($elements[0]['checked']), "Field $key is checked");
|
||||
}
|
||||
}
|
||||
|
||||
// Now test by submitting the or/not part of the query in the main
|
||||
// search box, and verify that the advanced form is not filled out.
|
||||
// (It shouldn't be filled out unless you submit values in those fields.)
|
||||
$edit2 = array('keys' => 'cat dog OR gerbil -fish -snake');
|
||||
$this->drupalPostForm('search/node', $edit2, t('Advanced search'));
|
||||
$this->assertText('Search for cat dog OR gerbil -fish -snake');
|
||||
foreach ($edit as $key => $value) {
|
||||
if ($key != 'type[page]') {
|
||||
$elements = $this->xpath('//input[@name=:name]', array(':name' => $key));
|
||||
$this->assertFalse(isset($elements[0]) && $elements[0]['value'] == $value, "Field $key is not set to $value");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -36,6 +36,7 @@ class SearchBlockTest extends SearchTestBase {
|
|||
|
||||
// Test availability of the search block in the admin "Place blocks" list.
|
||||
$this->drupalGet('admin/structure/block');
|
||||
$this->clickLinkPartialName('Place block');
|
||||
$this->assertLinkByHref('/admin/structure/block/add/search_form_block/classy', 0,
|
||||
'Did not find the search block in block candidate list.');
|
||||
|
||||
|
@ -92,16 +93,16 @@ class SearchBlockTest extends SearchTestBase {
|
|||
// Test that after entering a too-short keyword in the form, you can then
|
||||
// search again with a longer keyword. First test using the block form.
|
||||
$this->submitGetForm('node', array('keys' => $this->randomMachineName(1)), t('Search'));
|
||||
$this->assertText('You must include at least one positive keyword', 'Keyword message is displayed when searching for short word');
|
||||
$this->assertText('You must include at least one keyword to match in the content', 'Keyword message is displayed when searching for short word');
|
||||
$this->assertNoText(t('Please enter some keywords'), 'With short word entered, no keywords message is not displayed');
|
||||
$this->submitGetForm(NULL, array('keys' => $this->randomMachineName()), t('Search'), 'search-block-form');
|
||||
$this->assertNoText('You must include at least one positive keyword', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
$this->assertNoText('You must include at least one keyword to match in the content', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
|
||||
// Same test again, using the search page form for the second search this
|
||||
// time.
|
||||
$this->submitGetForm('node', array('keys' => $this->randomMachineName(1)), t('Search'));
|
||||
$this->drupalPostForm(NULL, array('keys' => $this->randomMachineName()), t('Search'), array(), array(), 'search-form');
|
||||
$this->assertNoText('You must include at least one positive keyword', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
$this->assertNoText('You must include at least one keyword to match in the content', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
|
||||
namespace Drupal\search\Tests;
|
||||
|
||||
use Drupal\Component\Utility\SafeMarkup;
|
||||
|
||||
/**
|
||||
* Verify the search without keywords set and extra conditions.
|
||||
*
|
||||
|
@ -59,6 +61,6 @@ class SearchKeywordsConditionsTest extends SearchTestBase {
|
|||
$keys = 'moving drop ' . $this->randomMachineName();
|
||||
$this->drupalGet("search/dummy_path", array('query' => array('keys' => 'bike', 'search_conditions' => $keys)));
|
||||
$this->assertText("Dummy search snippet to display.");
|
||||
$this->assertRaw(print_r(array('keys' => 'bike', 'search_conditions' => $keys), TRUE));
|
||||
$this->assertRaw(SafeMarkup::checkPlain(print_r(array('keys' => 'bike', 'search_conditions' => $keys), TRUE)));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -57,11 +57,11 @@ class SearchNodePunctuationTest extends SearchTestBase {
|
|||
$edit = array('keys' => '&');
|
||||
$this->drupalPostForm('search/node', $edit, t('Search'));
|
||||
$this->assertNoRaw('<strong>&</strong>amp;');
|
||||
$this->assertText('You must include at least one positive keyword');
|
||||
$this->assertText('You must include at least one keyword');
|
||||
|
||||
$edit = array('keys' => '&');
|
||||
$this->drupalPostForm('search/node', $edit, t('Search'));
|
||||
$this->assertNoRaw('<strong>&</strong>amp;');
|
||||
$this->assertText('You must include at least one positive keyword');
|
||||
$this->assertText('You must include at least one keyword');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -30,6 +30,22 @@ class SearchPageTextTest extends SearchTestBase {
|
|||
$this->searchingUser = $this->drupalCreateUser(array('search content', 'access user profiles', 'use advanced search'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests for XSS in search module local task.
|
||||
*
|
||||
* This is a regression test for https://www.drupal.org/node/2338081
|
||||
*/
|
||||
function testSearchLabelXSS() {
|
||||
$this->drupalLogin($this->drupalCreateUser(array('administer search')));
|
||||
|
||||
$keys['label'] = '<script>alert("Dont Panic");</script>';
|
||||
$this->drupalPostForm('admin/config/search/pages/manage/node_search', $keys, t('Save search page'));
|
||||
|
||||
$this->drupalLogin($this->searchingUser);
|
||||
$this->drupalGet('search/node');
|
||||
$this->assertEscaped($keys['label']);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the failed search text, and various other text on the search page.
|
||||
*/
|
||||
|
@ -119,10 +135,10 @@ class SearchPageTextTest extends SearchTestBase {
|
|||
// message, and that if after that you search for a longer keyword, you
|
||||
// do not still see the message.
|
||||
$this->drupalPostForm('search/node', array('keys' => $this->randomMachineName(1)), t('Search'));
|
||||
$this->assertText('You must include at least one positive keyword', 'Keyword message is displayed when searching for short word');
|
||||
$this->assertText('You must include at least one keyword', 'Keyword message is displayed when searching for short word');
|
||||
$this->assertNoText(t('Please enter some keywords'), 'With short word entered, no keywords message is not displayed');
|
||||
$this->drupalPostForm(NULL, array('keys' => $this->randomMachineName()), t('Search'));
|
||||
$this->assertNoText('You must include at least one positive keyword', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
$this->assertNoText('You must include at least one keyword', 'Keyword message is not displayed when searching for long word after short word search');
|
||||
|
||||
// Test that if you search for a URL with .. in it, you still end up at
|
||||
// the search page. See issue https://www.drupal.org/node/890058.
|
||||
|
@ -135,6 +151,5 @@ class SearchPageTextTest extends SearchTestBase {
|
|||
$this->drupalPostForm('search/node', array('keys' => '.something'), t('Search'));
|
||||
$this->assertResponse(200, 'Searching for .something does not lead to a 403 error');
|
||||
$this->assertText('no results', 'Searching for .something gives you a no search results page');
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -64,7 +64,7 @@ class SearchExtraTypeSearch extends ConfigurableSearchPluginBase {
|
|||
'link' => Url::fromRoute('test_page_test.test_page')->toString(),
|
||||
'type' => 'Dummy result type',
|
||||
'title' => 'Dummy title',
|
||||
'snippet' => SafeMarkup::set("Dummy search snippet to display. Keywords: {$this->keywords}\n\nConditions: " . print_r($this->searchParameters, TRUE)),
|
||||
'snippet' => SafeMarkup::format("Dummy search snippet to display. Keywords: @keywords\n\nConditions: @search_parameters", ['@keywords' => $this->keywords, '@search_parameters' => print_r($this->searchParameters, TRUE)]),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
Reference in a new issue