Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2018-11-22 17:49:56

philwareham
Core designer
From: Farnham, Surrey, UK
Registered: 2009-06-11
Posts: 3,093
Website

Get Textile version with PHP

Here’s an edge case: can I get and display the Textile version used in my Textpattern install with some PHP?

Basically, on the revised Textile website I’m close to launching, I want to show what version of Textile it is running on.

Cheers!

Offline

#2 2018-11-22 19:39:13

jakob
Moderator
From: Germany
Registered: 2005-01-20
Posts: 3,159
Website

Re: Get Textile version with PHP

Maybe the getVersion function in Parser.php?

Using the example shown there, then maybe:

<txp:php>
    $parser = new \Netcarver\Textile\Parser();
    echo $parser->getVersion();
</txp:php>

Looking forward to your relaunch!


TXP Builders – finely-crafted code, design and txp

Offline

#3 2018-11-22 19:42:27

philwareham
Core designer
From: Farnham, Surrey, UK
Registered: 2009-06-11
Posts: 3,093
Website

Re: Get Textile version with PHP

Thanks, I’ll give that a try tomorrow.

Offline

#4 2018-11-23 10:05:40

philwareham
Core designer
From: Farnham, Surrey, UK
Registered: 2009-06-11
Posts: 3,093
Website

Re: Get Textile version with PHP

@jakob that worked perfectly, thanks!

Offline

Board footer

Powered by FluxBB