Skip to content

u/rojaro

In this archive from Sep 2010 to Dec 2019

1
posts
25
comments
0
media
72
score

Top posts

Top comments

Just create a simple PHP file like this example:

<?php return [
    'foo' => 'bar'
];

Use it like this:

$config = include 'path/to/file.phjp';

The file will be cached by the opcode cache you're using and you can combine the approach with a database backend by automatically regenerating the file whenever you're inserting/updating/deleting a value from your configuration table i.e.:

file_put_contents('path/to/config.php', '<?php return ' . var_export($config, true) . ';');
9 points

Subreddits

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.