Changeset 17518


Ignore:
Timestamp:
Aug 9, 2012, 10:46:10 PM (8 years ago)
Author:
mistic100
Message:

clean definition of CONTACT_FORM_PUBLIC

Location:
extensions/ContactForm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/ContactForm/include/functions.inc.php

    r17491 r17518  
    99  global $tokens, $page, $conf;
    1010 
    11   if (!defined('CONTACT_FORM_PUBLIC')) define('CONTACT_FORM_PUBLIC', make_index_url(array('section' => 'contact')) . '/');
    12 
    1311  if ($tokens[0] == 'contact')
    1412  {
     
    4139  if ( !is_classic_user() and !$conf['ContactForm']['cf_allow_guest'] ) return;
    4240  if ( !count(get_contact_emails()) ) return;
    43  
    44   if (!defined('CONTACT_FORM_PUBLIC')) define('CONTACT_FORM_PUBLIC', make_index_url(array('section' => 'contact')) . '/');
    4541
    4642  $menu = &$menu_ref_arr[0];
  • extensions/ContactForm/main.inc.php

    r17491 r17518  
    1111if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
    1212
    13 define('CONTACT_FORM_PATH',  PHPWG_PLUGINS_PATH . basename(dirname(__FILE__)) . '/');
    14 define('CONTACT_FORM_ADMIN', get_root_url() . 'admin.php?page=plugin-' . basename(dirname(__FILE__)));
     13define('CONTACT_FORM_PATH',   PHPWG_PLUGINS_PATH . basename(dirname(__FILE__)) . '/');
     14define('CONTACT_FORM_ADMIN',  get_root_url() . 'admin.php?page=plugin-' . basename(dirname(__FILE__)));
     15define('CONTACT_FORM_PUBLIC', get_absolute_root_url() . make_index_url(array('section' => 'contact')) . '/');
    1516
    1617
     
    2223{
    2324  add_event_handler('get_admin_plugin_menu_links', 'contact_form_admin_menu');
    24   define('CONTACT_FORM_PUBLIC', make_index_url(array('section' => 'contact')) . '/');
    2525}
    2626
Note: See TracChangeset for help on using the changeset viewer.