2017 © Pedro Peláez
 

symfony-bundle match-against-bundle

A search bundle for symfony, using MySQL FULLTEXT MATCH AGAINST

image

ciricihq/match-against-bundle

A search bundle for symfony, using MySQL FULLTEXT MATCH AGAINST

  • Tuesday, April 12, 2016
  • by gtrias
  • Repository
  • 5 Watchers
  • 4 Stars
  • 583 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 2 Open issues
  • 2 Versions
  • 16 % Grown

The README.md

MatchAgainstBundle

Based on https://gist.github.com/ZeBigDuck/1234419, (*1)

Installing

composer require ciricihq/match-against-bundle

Usage

You must load the bundle provided config.yml in order to have the MATCH_AGAINST MySQL sentence, (*2)

imports:
    - { resource: ../../src/Cirici/MatchAgainstBundle/Resources/config/config.yml }

Make a query:, (*3)

  $qbuilder
      ->select('sti.foreignId')
      ->from('Cirici\MatchAgainstBundle\Entity\SearchTextIndex', 'sti')
      ->where('sti.model = :entityClass')
      ->andWhere('sti.field = :fieldName')
      // ->andWhere("MATCH_AGAINST(sti.content, :text 'IN NATURAL LANGUAGE MODE') > :score")
      ->andWhere("MATCH_AGAINST(sti.content, :text 'IN BOOLEAN MODE') > :score")
      ->setParameter('entityClass', $entity_class)
      ->setParameter('fieldName', $field_name)
      ->setParameter('text', $text)
      ->setParameter('score', $score)
  ;

License

Licensed under the GNU GPL 2.0 license. Check out the LICENSE file for more details., (*4)

Copyright 2015 © Cirici New Media, (*5)

The Versions

12/04 2016

dev-master

9999999-dev

A search bundle for symfony, using MySQL FULLTEXT MATCH AGAINST

  Sources   Download

GPL-2.0

The Requires

  • php >=5.6

 

symfony2 symfony mysql full-text match-against

12/04 2016

v1.0.0

1.0.0.0

A search bundle for symfony, using MySQL FULLTEXT MATCH AGAINST

  Sources   Download

GPL-2.0

The Requires

  • php >=5.6

 

symfony2 symfony mysql full-text match-against