Quick Search:

Mode

Context

Displaying 3 lines of context. None | Less | More | Full

Other Diffs

Ignore

Blank Lines Whitespace:

Diff

486
 
503
 
503
 
payment.php
_> 11 <?php
  22 /*
<> 3 -  $Id: payment.php 486 2006-04-17 23:39:28Z hpdl $
   3+  $Id: payment.php 503 2006-04-19 00:19:25Z hpdl $
44 
  55   osCommerce, Open Source E-Commerce Solutions
  66   http://www.oscommerce.com
     
 !
319319       return $active;
  320320     }
  321321 
<> 322 -    function hasKeys() {
  323 -      static $has_keys;
  324 -
  325 -      if (isset($has_keys) === false) {
  326 -        $has_keys = (sizeof($this->getKeys()) > 0) ? true : false;
  327 -      }
  328 -
  329 -      return $has_keys;
  330 -    }
  331 -
  332 -    function getPostTransactionActions($history) {
  333 -      return false;
  334 -    }
  335 -
  336 -    function install() {
  337 -      global $osC_Database, $osC_Language;
  338 -
  339 -      $Qinstall = $osC_Database->query('insert into :table_templates_boxes (title, code, author_name, author_www, modules_group) values (:title, :code, :author_name, :author_www, :modules_group)');
  340 -      $Qinstall->bindTable(':table_templates_boxes', TABLE_TEMPLATES_BOXES);
  341 -      $Qinstall->bindValue(':title', $this->_title);
  342 -      $Qinstall->bindValue(':code', $this->_code);
  343 -      $Qinstall->bindValue(':author_name', $this->_author_name);
  344 -      $Qinstall->bindValue(':author_www', $this->_author_www);
  345 -      $Qinstall->bindValue(':modules_group', $this->_group);
  346 -      $Qinstall->execute();
  347 -
  348 -      foreach ($osC_Language->getAll() as $key => $value) {
  349 -        if (file_exists(dirname(__FILE__) . '/../languages/' . $key . '/modules/' . $this->_group . '/' . $this->_code . '.xml')) {
  350 -          foreach ($osC_Language->extractDefinitions($key . '/modules/' . $this->_group . '/' . $this->_code . '.xml') as $def) {
  351 -            $Qcheck = $osC_Database->query('select id from :table_languages_definitions where definition_key = :definition_key and content_group = :content_group and languages_id = :languages_id limit 1');
  352 -            $Qcheck->bindTable(':table_languages_definitions', TABLE_LANGUAGES_DEFINITIONS);
  353 -            $Qcheck->bindValue(':definition_key', $def['key']);
  354 -            $Qcheck->bindValue(':content_group', $def['group']);
  355 -            $Qcheck->bindInt(':languages_id', $value['id']);
  356 -            $Qcheck->execute();
  357 -
  358 -            if ($Qcheck->numberOfRows() === 1) {
  359 -              $Qdef = $osC_Database->query('update :table_languages_definitions set definition_value = :definition_value where definition_key = :definition_key and content_group = :content_group and languages_id = :languages_id');
  360 -            } else {
  361 -              $Qdef = $osC_Database->query('insert into :table_languages_definitions (languages_id, content_group, definition_key, definition_value) values (:languages_id, :content_group, :definition_key, :definition_value)');
  362 -            }
  363 -            $Qdef->bindTable(':table_languages_definitions', TABLE_LANGUAGES_DEFINITIONS);
  364 -            $Qdef->bindInt(':languages_id', $value['id']);
  365 -            $Qdef->bindValue(':content_group', $def['group']);
  366 -            $Qdef->bindValue(':definition_key', $def['key']);
  367 -            $Qdef->bindValue(':definition_value', $def['value']);
  368 -            $Qdef->execute();
  369 -          }
  370 -        }
  371 -      }
  372 -
  373 -      osC_Cache::clear('languages');
  374 -    }
  375 -
  376 -    function remove() {
  377 -      global $osC_Database, $osC_Language;
  378 -
  379 -      $Qdel = $osC_Database->query('delete from :table_templates_boxes where code = :code and modules_group = :modules_group');
  380 -      $Qdel->bindTable(':table_templates_boxes', TABLE_TEMPLATES_BOXES);
  381 -      $Qdel->bindValue(':code', $this->_code);
  382 -      $Qdel->bindValue(':modules_group', $this->_group);
  383 -      $Qdel->execute();
  384 -
  385 -      if ($this->hasKeys()) {
  386 -        $Qdel = $osC_Database->query('delete from :table_configuration where configuration_key in (":configuration_key")');
  387 -        $Qdel->bindTable(':table_configuration', TABLE_CONFIGURATION);
  388 -        $Qdel->bindRaw(':configuration_key', implode('", "', $this->getKeys()));
  389 -        $Qdel->execute();
  390 -      }
  391 -
  392 -      if (file_exists(dirname(__FILE__) . '/../languages/' . $osC_Language->getCode() . '/modules/' . $this->_group . '/' . $this->_code . '.xml')) {
  393 -        foreach ($osC_Language->extractDefinitions($osC_Language->getCode() . '/modules/' . $this->_group . '/' . $this->_code . '.xml') as $def) {
  394 -          $Qdel = $osC_Database->query('delete from :table_languages_definitions where definition_key = :definition_key and content_group = :content_group');
  395 -          $Qdel->bindTable(':table_languages_definitions', TABLE_LANGUAGES_DEFINITIONS);
  396 -          $Qdel->bindValue(':definition_key', $def['key']);
  397 -          $Qdel->bindValue(':content_group', $def['group']);
  398 -          $Qdel->execute();
  399 -        }
  400 -
  401 -        osC_Cache::clear('languages');
  402 -      }
  403 -    }
  404 -
<_ 405322     function _usortModules($a, $b) {
  406323       if ($GLOBALS['osC_Payment_' . $a]->getSortOrder() == $GLOBALS['osC_Payment_' . $b]->getSortOrder()) {
  407324         return strnatcasecmp($GLOBALS['osC_Payment_' . $a]->getTitle(), $GLOBALS['osC_Payment_' . $a]->getTitle());