Download the PHP package unocha/ocha_search without Composer

On this page you can find all versions of the php package unocha/ocha_search. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package ocha_search

OCHA search module

This module provides basic configuration and one or two search results pages for results from Google Custom Search Engine searches:

Google Indexing

To use GCSE effectively as an in-site search, the site’s content needs to be indexed by Google. We use Drupal xmlsitemap module to provide a sitemap and we can submit that to Google for indexing. This requires access to Google Search console which can be requested via [email protected]

Additional setup in the subtheme

The result page template can be overridden in the subtheme, and the styling can be extended by a subtheme library.

common_design_subtheme.info.yml

This module also provides a Drupal block for the search form. Place this block in the Header Search region. The markup of the search form currently relies on the Common Design base theme for styles and javascript.

Configuration

There are two sets of configurations required: 'Google config', on the Google site at https://programmablesearchengine.google.com/controlpanel/all 'Internal config', on the OCHA site at /admin/config/search/gcse-config

Site search results will appear at /results unless set to another path in the 'internal config'. This is to avoid conflict with /search as that path may already be defined by other modules.

OCHA-wide search results will by default appear at /ocha-wide-results. They can be turned off via the 'Enable tab for OCHA-wide results' checkbox, and the path can be configured. Both options are on the internal config page.

Site search requires a GCSE ID, which comes from the Google config page. That ID must be added on the internal config page.

Google config

The 'standard' configuration options are included in example-context-cse.xml in the gcse_config directory. The file can be uploaded to a custom search engine via the advanced tab in the setup. The name and description should be edited accordingly.

All the color preferences and other styling choices are included in a css file in the module, so configuration of those in the google interface can be ignored.

Internal config

Site search:


All versions of ocha_search with dependencies

PHP Build Version
Package Version
Requires composer/installers Version ^1 || ^2
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package unocha/ocha_search contains the following files

Loading the files please wait ....