2017 © Pedro Peláez
 

library smart-quotes

Smart quotes replacement toolkit

image

sebastiansulinski/smart-quotes

Smart quotes replacement toolkit

  • Friday, November 10, 2017
  • by sebastiansulinski
  • Repository
  • 1 Watchers
  • 1 Stars
  • 91,411 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 10 Versions
  • 6 % Grown

The README.md

Smart quotes replacement toolkit

The kit replaces all irregular - Microsoft version single and double quotes to simple - ASCII type ones., (*1)

Requirements

Starting from version 1.3.0 package requires PHP 7.1 or higher. Please use version 1.2.0 for PHP 7.0 or 1.0.5 for earlier versions., (*2)

Usage example

There are two implementations - one, which converts quotes and returns content as UTF-8 and the other which does the same, but returns it as ASCII - with the exception of a pound symbol (£), which is also returned correctly., (*3)

use SSD\SmartQuotes\Utf8CharacterSet;
use SSD\SmartQuotes\Factory as SmartQuotesFactory;

$string = "“Contrary to ‘popular belief’, Lorem Ipsum is not simply ‘random text’. The cost in Sterling is £20.00”";

// UTF-8 implementation
echo SmartQuotesFactory::filter(new Utf8CharacterSet, $string);

// ASCII implementation
echo SmartQuotesFactory::filter(new AsciiCharacterSet, $string);

// both return:
// "Contrary to 'popular belief', Lorem Ipsum is not simply 'random text'. The cost in Sterling is £20.00"

The Versions

10/11 2017

dev-master

9999999-dev

Smart quotes replacement toolkit

  Sources   Download

MIT

The Requires

  • php ^7.1

 

The Development Requires

by Sebastian Sulinski

10/11 2017

v1.3.0

1.3.0.0

Smart quotes replacement toolkit

  Sources   Download

MIT

The Requires

  • php ^7.1

 

The Development Requires

by Sebastian Sulinski

24/09 2017

v1.2.0

1.2.0.0

Smart quotes replacement toolkit

  Sources   Download

MIT

The Requires

  • php ^7.0

 

The Development Requires

by Sebastian Sulinski

20/02 2017

v1.1.0

1.1.0.0

Smart quotes replacement toolkit

  Sources   Download

MIT

The Requires

  • php ^7.0

 

The Development Requires

by Sebastian Sulinski

09/04 2015

1.0.5

1.0.5.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski

09/04 2015

1.0.4

1.0.4.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski

09/04 2015

1.0.3

1.0.3.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski

11/02 2015

1.0.2

1.0.2.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski

11/02 2015

1.0.1

1.0.1.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski

11/02 2015

1.0

1.0.0.0

Smart quotes replacement toolkit

  Sources   Download

MIT

by Sebastian Sulinski