inc/error.inc.php
author rejo
Tue, 10 Jul 2007 21:24:06 +0000
changeset 37 b785e54690ce
parent 13 2ff220cfde13
child 47 ae140472d97c
permissions -rwxr-xr-x
[feladat @ 84] Bugfix. The function zone_count() now also counts zones an owner has only partial access to, not just those zones the owner has full access to. This fixes just the count, the zones a user has partial access to are not (yet!) shown in the "list zones" page. Bugfix. In the zone listing the "edit" button is now show for users with access level 1. Untill now they were presented an overview of the zones they could change, but there was no link for them to actually edit the zone. Bugfix. Some of the buttons in the "edit zone" interface that are of no use to a user with access level 1 have been hidden. Bugfix. Make sure a user with access level 1 with only partial access to a zone cannot add new records to that zone. Only the zone owner should be able to add new record. Bugfix. If a user with access level 1 edits a record in a zone he has only partial access to, an error was shown because of call to a non- existing function in the PEAR:MDB2. This bug was most likely introduced while migrating from PEAR:DB to PEAR:MDB2. Bugfix. A user with access level 1 was able to delete all records of a zone he has only partial access to. Some additional checks have been added. Bugfix. If a user with accees level 1 has partial access to one or more zones starting with a certain character, but did not own at least one entire zone starting with the same character, the character wasn't clickable in the "list zone" page. Interface. If no record or zone id is given for delete_record.php or delete_domain.php, don't just die but echo a nice message. The i18n files have not yet been updated to reflect this change. Interface. If no master IP is given in delete_supermaster.php, don't just die but echo a nice message. The i18n files have not yet been updated to reflect this change. [All fixes by Peter Beernink.]
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
     1
<?
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
     2
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     3
// Added next line to enable i18n on following definitions. Not sure
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     4
// if this is the best (or at least a proper) location for this. /RZ.
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     5
require_once("inc/i18n.inc.php");
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     6
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
     7
/* USER LEVELS */
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     8
define("ERR_LEVEL_5", _('You need user level 5 for this operation'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
     9
define("ERR_LEVEL_10", _('You need user level 10 for this operation'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    10
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    11
/* RECORD STUFF */
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    12
define("ERR_RECORD_EMPTY_CONTENT", _('Your content field is empty'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    13
define("ERR_RECORD_ACCESS_DENIED", _('Access denied, you do not have access to that record'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    14
define("ERR_RECORD_DELETE_TYPE_DENIED", _('You are not allowed to delete %s records'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    15
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    16
/* DOMAIN STUFF */
13
2ff220cfde13 [feladat @ 60]
rejo
parents: 4
diff changeset
    17
define("ERR_DOMAIN_INVALID", _('This is an invalid zone name'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    18
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    19
/* USER STUFF */
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    20
define("ERR_USER_EXIST", _('Username exist already, please choose another one'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    21
define("ERR_USER_NOT_EXIST", _('User doesnt exist'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    22
define("ERR_USER_WRONG_CURRENT_PASS", _('You didnt enter the correct current password'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    23
define("ERR_USER_MATCH_NEW_PASS", _('The two new password fields do not match'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    24
define("ERR_USER_EDIT", _('Error editting user'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    25
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    26
/* OTHER */
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    27
define("ERR_INV_ARG", _('Invalid argument(s) given to function %s'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    28
define("ERR_INV_ARGC", _('Invalid argument(s) given to function %s %s'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    29
define("ERR_UNKNOWN", _('unknown error'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    30
define("ERR_INV_EMAIL", _('Enter a valid email address'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    31
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    32
/* DNS */
4
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    33
define("ERR_DNS_CONTENT", _('Your content field doesnt have a legit value'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    34
define("ERR_DNS_HOSTNAME", _('Invalid hostname'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    35
define("ERR_DNS_RECORDTYPE", _('Invalid record type! You shouldnt even been able to get that here'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    36
define("ERR_DNS_IPV6", _('This is not a valid IPv6 ip.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    37
define("ERR_DNS_IPV4", _('This is not a valid IPv4 ip.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    38
define("ERR_DNS_CNAME", _('This is not a valid CNAME. Did you assign an MX or NS record to the record?'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    39
define("ERR_DNS_NS_CNAME", _('You can not point a NS record to a CNAME record. Remove/rename the CNAME record first or take another name.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    40
define("ERR_DNS_NS_HNAME", _('IN NS fields must be a hostnames.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    41
define("ERR_DNS_MX_CNAME", _('You can not point a MX record to a CNAME record. Remove/rename the CNAME record first or take another name.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    42
define("ERR_DNS_MX_PRIO", _('A prio field should be numeric.'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    43
define("ERR_DNS_SOA_NUMERIC", _('One of your SOA data fields is not numeric!'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    44
define("ERR_DNS_SOA_NUMERIC_FIELDS", _('You can only have 5 numeric fields'));
55ed92aa7cf5 [feladat @ 5]
rejo
parents: 1
diff changeset
    45
define("ERR_DNS_SOA_HOSTNAME", _('The first part of your SOA record does not contain a valid hostname for a DNS Server'));
1
58094faf794d [feladat @ 2]
rejo
parents:
diff changeset
    46
?>