meta-tags icon indicating copy to clipboard operation
meta-tags copied to clipboard

charset function

Open fatihgvn opened this issue 4 years ago • 2 comments

I think you should add this function as well

public function charset($set = "utf-8")
    {
        $tag = $this->createTag('meta', ['charset' => $set]);
        $this->addToTagsGroup('meta', 'charset', $tag);
        return $tag;
    }

fatihgvn avatar May 14 '20 19:05 fatihgvn

public function charset($set = "utf-8") { $tag = $this->createTag('meta', ['charset' => $set]); $this->addToTagsGroup('meta', 'charset', $tag); return $tag; }

How does it work?

NeftaliAcosta avatar Jul 02 '20 08:07 NeftaliAcosta

public function charset($set = "utf-8") { $tag = $this->createTag('meta', ['charset' => $set]); $this->addToTagsGroup('meta', 'charset', $tag); return $tag; }

How does it work?

$tags = new MetaTags;

$tags->title('My Awesome Site');
$tags->charset(); // default value = utf-8

$tags->render();

or

$tags = new MetaTags;

$tags->title('My Awesome Site');
$tags->charset('iso-8859-3'); // is Latin 3 Alphabet (ISO)

$tags->render();

But you need to add this function manually. Because it has not been added to the library yet.

fatihgvn avatar Jul 02 '20 08:07 fatihgvn