root/dev/mods/mail_forward/init.php @ 370

Revision 370, 1.1 KB (checked in by kovell, 11 years ago)

- SQL queries optimised for speed and error protection.
- feed syndication optimised
- front page includes optional clock and optional kill/loss display
- mysqli support added
- transaction protection of kills added where supported (mysqli and InnoDB)
- summary tables and contracts show total destroyed value instead of ship value
- html errors reduced
- related kill calculation improved
- query caching errors reduced
- minor bugfixes
- Smarty 2.6.25 added
- apoc fitting mod added and modded
- code optimisations
- code comments added (doxygen format)
- conflicting mods are now identified

Line 
1<?php
2event::register('killmail_added', 'post_forward::handler');
3event::register('killmail_imported', 'import_forward::importhandler');
4
5class post_forward
6{
7    function handler($object)
8    {
9        if (config::get('forward_active') == false)
10        {
11            return;
12        }
13        require_once('common/includes/class.http.php');
14
15        $req = new http_request(config::get('forward_site').'?a=post');
16
17        $req->set_postform('password', config::get('forward_pass'));
18        $req->set_postform('killmail', stripslashes($_POST['killmail']));
19        $req->request();
20    }
21}
22
23
24class import_forward
25{
26    function importhandler($object)
27    {
28                if (config::get('forward_active') == false)
29        {
30            return;
31        }
32        require_once('common/includes/class.http.php');
33
34        $req = new http_request(config::get('forward_site').'?a=post');
35
36        $req->set_postform('password', config::get('forward_pass'));
37        $req->set_postform('killmail', stripslashes($object->killmail_));
38        $req->request();
39   }
40}
41
42?>
Note: See TracBrowser for help on using the browser.