Documentation > Solr Manager Control Panel > Opensolr Basic User Guide

Opensolr Basic User Guide with Integrations

Overview

Opensolr provides a fully managed Apache Solr hosting service that allows you to create and manage search indexes, connect external websites (Drupal, WordPress, or custom-built), and use Solr Search APIs easily without managing your own servers.


1. Getting Started

Create an Account

  1. Go to https://opensolr.com.
  2. Click Sign Up and create your account.
  3. Confirm your email and log in to the Opensolr Control Panel.

Access the Control Panel

  • After logging in, you’ll be directed to the Dashboard.
  • Here, you can manage Solr indexes, configurations, API keys, and user access.

2. Creating a Solr index

  1. In your dashboard, click New index.
  2. Choose the Solr version that matches your application (e.g., 8.x or 9.x).
  3. Give your index a name (e.g., drupal_search, wordpress_search, or custom_site).
  4. Click Create.
  5. Wait a few seconds for the index to initialize. Once ready, you’ll see connection details like:
    • Solr Core URL
    • Hostname and Port
    • index name
    • Authentication credentials (if enabled)

3. Connecting Drupal to Opensolr

Install Required Modules

  1. In your Drupal admin panel, install:
  2. Enable both modules.

Configure the Search Server

  1. Go to Configuration → Search and Metadata → Search API.
  2. Click Add Server.
  3. Fill in the following:
    • Name: Opensolr Search
    • Backend: Solr
    • Solr Host: Provided by Opensolr (e.g., server-name.opensolr.com)
  4. Save the server and test the connection — it should say “The Solr server could be reached successfully.”

Add an Index

  1. Under Search API, click Add Index.
  2. Choose your content types (e.g., Articles, Pages).
  3. Assign your newly created Opensolr server to the index.
  4. Save and index your content.

Your Drupal site is now powered by Opensolr.


4. Connecting WordPress to Opensolr

Install a Plugin

  1. From the WordPress dashboard, go to Plugins → Add New.
  2. Search for “Search with Solr” or “WPSOLR”.
  3. Install and activate the plugin.

Configure Plugin Settings

  1. Navigate to Settings → Solr Search.
  2. Fill in your Opensolr connection details:
    • Solr Host: e.g., https://yourdomain.opensolr.com/solr/wordpress_search
    • Port: 443 (for HTTPS)
    • Path: /solr/wordpress_search
  3. Save settings and reindex your site content.

Your WordPress search now uses Opensolr for fast and accurate results.


5. Integrating a Custom Website via Search API

If you have a custom PHP, Python, or Node.js website, you can interact directly with Opensolr’s Search API.

Example using cURL

curl "https://yourdomain.opensolr.com/solr/custom_site/select?q=example&rows=5&wt=json"

Example using PHP

<?php
$url = "https://yourdomain.opensolr.com/solr/custom_site/select?q=example&wt=json";
$response = file_get_contents($url);
$data = json_decode($response, true);
print_r($data);
?>

Example using JavaScript (Fetch API)

fetch("https://yourdomain.opensolr.com/solr/custom_site/select?q=example&wt=json")
  .then(res => res.json())
  .then(data => console.log(data));

6. Testing Your Integration

  1. Index some test data or publish content.
  2. Run a search from your website.
  3. Verify that results match your Opensolr index.

7. Troubleshooting

Issue Possible Cause Solution
Cannot connect to Solr Wrong hostname or index name Verify your Opensolr connection URL
No search results Schema mismatch or unindexed data Reindex your content or update schema
Plugin error in Drupal/WordPress Version incompatibility Update Solr module/plugin to latest version

8. Resources






Review us on Google Business
ISO-9001 CERTIFIED ISO-27001 CERTIFIED