Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2015-10-19 12:52:27

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,356
GitHub

[solved] Checking production_status in core

Is there a neat, hacky or unsupported way to find the production_status from core Textpattern?

I can do it with various plugins, but I’m curious if it is possible without using a plugin.

Thanks in advance.

Last edited by gaekwad (2015-10-19 15:49:50)

Offline

#2 2015-10-19 12:57:01

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: [solved] Checking production_status in core

<txp:php>echo $GLOBALS['production_status'];</txp:php>

Offline

#3 2015-10-19 12:59:03

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,356
GitHub

Re: [solved] Checking production_status in core

Perfect. Thank you, Ruud.

Offline

#4 2015-10-19 13:01:45

etc
Developer
Registered: 2010-11-11
Posts: 5,393
Website GitHub

Re: [solved] Checking production_status in core

Isn’t this safer?

<txp:php>echo get_pref('production_status');</txp:php>

Offline

#5 2015-10-19 13:10:29

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: [solved] Checking production_status in core

Yes, that’s better.

Offline

#6 2015-10-19 13:13:09

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,356
GitHub

Re: [solved] Checking production_status in core

Marvellous. Thank you, Oleg (and Ruud for second pair of eyes).

Offline

Board footer

Powered by FluxBB