diff options
Diffstat (limited to 'post.php')
| -rw-r--r-- | post.php | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -421,6 +421,15 @@ if (isset($_POST['delete'])) { wordfilters($post['body']); $post['body'] = escape_markup_modifiers($post['body']); + if ($config['country_flags']) { + if (!geoip_db_avail(GEOIP_COUNTRY_EDITION)) { + error('GeoIP not available: ' . geoip_db_filename(GEOIP_COUNTRY_EDITION)); + } + if ($country_code = @geoip_country_code_by_name('8.8.8.8')) { + $post['body'] .= '<tinyboard flag_country>' . strtolower($country_code) . '</tinyboard>'; + } + } + if ($mod && isset($post['raw']) && $post['raw']) { $post['body'] = '<tinyboard raw html>' . $post['body'] . '</tinyboard>'; } |
