public function BasicAuthSolrConnector::viewSettings in Search API Solr 8
Returns additional, connector-specific information about this server.
This information will be then added to the server's "View" tab in some way. In the default theme implementation the data is output in a table with two columns along with other, generic information about the server.
Return value
array An array of additional server information, with each piece of information being an associative array with the following keys:
- label: The human-readable label for this data.
- info: The information, as HTML.
- status: (optional) The status associated with this information. One of "info", "ok", "warning" or "error". Defaults to "info".
Overrides SolrConnectorPluginBase::viewSettings
File
- src/
Plugin/ SolrConnector/ BasicAuthSolrConnector.php, line 129
Class
- BasicAuthSolrConnector
- Standard Solr connector.
Namespace
Drupal\search_api_solr\Plugin\SolrConnectorCode
public function viewSettings() {
$vars = array(
'%user' => $this->configuration['username'],
'%pass' => str_repeat('*', strlen($this->configuration['password'])),
);
$info[] = array(
'label' => $this
->t('Basic HTTP authentication'),
'info' => $this
->t('Username: %user | Password: %pass', $vars),
);
return $info;
}