Plugin for YOURLS 1.7.7+: Old Pages
Display pages that are located in <root>/pages/ instead of <root>/user/pages/
- In
/user/plugins, create a new folder namedold-pages - Drop these files in that directory
Run 32 bits version of N++
Plugins:
| #! /usr/bin/perl | |
| use File::Find; | |
| my $dir = '.'; | |
| my %actions; | |
| my %filters; | |
| $dir = $ARGV[0] if ($#ARGV != -1); |
Drop down of all timezones, grouped by Region, + a list of manual UTC offsets
| <?php | |
| /** | |
| * YOURLS actions upon instantiating | |
| */ | |
| namespace YOURLS\Config; | |
| class Init { |
| <?php | |
| $reflFunc = new ReflectionFunction('function_name'); | |
| print $reflFunc->getFileName() . ':' . $reflFunc->getStartLine(); | |
| // eg /home/you/includes/file.php:60 |
| <?php | |
| /* | |
| Plugin Name: RESET URLS | |
| Plugin URI: http://yourls.org/ | |
| Description: OMG | |
| Version: 1.0 | |
| Author: Ozh | |
| Author URI: http://ozh.org/ | |
| */ |
| <?php | |
| /* For the record: I played with Propel2 ORM and checked how I could use it with YOURLS. | |
| * | |
| * Setting up isn't complicated: | |
| * - install Propel with composer | |
| * - `vendor/bin/propel init` and answer quetions to generate the schema.xml, config file and mapped classes, | |
| * based on an existing DB | |
| * | |
| * Using isn't very complicated, but there are quite many functions to tame. |
| <?php | |
| // Needs YOURLS 1.7.3+ with PDO/AuraSQL | |
| $sql = "SET GLOBAL log_output = 'FILE';"; | |
| $ydb->exec($sql); | |
| $sql = "SET GLOBAL general_log_file = '/path/to/logfile.log';"; | |
| $ydb->exec($sql); | |
| $sql = "SET GLOBAL general_log = 'ON';"; | |
| $ydb->exec($sql); |
| <?php | |
| /** | |
| * Table is : | |
| * +-----------+-------------+--------------+ | |
| * | option_id | option_name | option_value | | |
| * +-----------+-------------+--------------+ | |
| * | 1 | version | 1.7.2 | | |
| * | 2 | db_version | 1337 | | |
| * | 3 | next_id | 69 | | |
| * +-----------+-------------+--------------+ |