function send_to_hellanzb($nzb_info) { global $config; print 'sending to hellanzb' . $config['debug_separator']; switch ($config['nzb_site']) { case 'nzbmatrix': print 'nzbmatrix + hellanzb are INCOMPATIBLE'; break; case 'newzbin': try { $hc = new HellaController($config['hellanzb_server'], $config['hellanzb_port'], 'hellanzb', $config['hellanzb_password']); } catch (Exception $e) { print 'hellanzb not running!'; return false; } //use the hellanzb class to send the id $hc->enqueueNewzbin($nzb_info['id']); //check hellanzb log to see if the id was processed successfully //-- print 'sent'; break; } return true; }
function send_to_hellanzb($newzbin_id) { global $config; print 'sending to hellanzb' . $config['debug_separator']; try { $hc = new HellaController($config['hellanzb_server'], $config['hellanzb_port'], 'hellanzb', $config['hellanzb_password']); } catch (Exception $e) { print 'hellanzb not running!'; return false; } //use the hellanzb class to send the id $hc->enqueueNewzbin($newzbin_id); //check hellanzb log to see if the id was processed successfully //-- print 'sent'; return true; }