Download the PHP package thelia/tnt-search-module without Composer

On this page you can find all versions of the php package thelia/tnt-search-module. 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 tnt-search-module

Tnt Search

This module provides TNTSearch feature to Thelia. TNTSearch is a full-featured full text search (FTS) engine written entirely in PHP.

The module could be used in front-office, using the dedicated loop. It also replaces the standard back-office search.

Installation

Composer

Add it in your main thelia composer.json file

Configuration

The search indexes will be updated each time a product, category, folder, content, brand, ... is updated in the back-office. This could take some time, depending on your configuration. You can disable this reali-time udate in the module configuration, to speed up back-office changes.

In this case, you have to rebuild the indexes manually, using the Rebuild Indexes button in the module configuiration page, or automatically using a cron which trigger the index build from time to time with this Thelia command: Thelia tntsearch:indexes

Thelia Loops

tnt-search loop

This loops return ids of the elements selected.

Input arguments

Arguments Description
search_for A list of elements you want to search for (product, category, folder, content, brand, order or customer)
locale A list of lang you want to search on ex: 'fr_FR, en_US'
search The search term to look for

Output arguments

Variable Description
$PRODUCT A list of product ids or 0
$CATEGORY A list of category ids or 0
$BRAND A list of brand ids or 0
$FOLDER A list of folder ids or 0
$CONTENT A list of content ids or 0
$CUSTOMER A list of customer ids or 0
$ORDER A list of order ids or 0

Example

To use this loop you need to combine it with another loop Index available : product,brand,category,folder,content,customer,order

{loop type="tnt-search" name="product-tnt-search-loop" search_for="product" locale="fr_FR" search=$search}
    {loop type="product" name="product-loop" id=$PRODUCT order="given_id"}
        Put your code here
    {/loop}
{/loop}

The order="given_id" is important because TNTSearch return the ids in order of pertinence.

Example


All versions of tnt-search-module with dependencies

PHP Build Version
Package Version
Requires ext-json Version *
thelia/installer Version ~1.1
teamtnt/tntsearch Version 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 thelia/tnt-search-module contains the following files

Loading the files please wait ....