Question

how i can check or validated the text field which i declare in magento system.xml i mean when i enter the word in text field and press save config button the it will show message "this is reserved word". where i can call or set this function for system.xml text field.over code is.

public function isReserveWord($word) {

    $is_reserved = false;
    $reserve_words = array('supportportal','view','search','askquestion');
    if (in_array($word,$reserve_words)) {
    $is_reserved = true;}
    return $is_reserved;}
Était-ce utile?

La solution

yes you can manage with system.xml to make you own form in your extension

here i can give you very good document link which will very useful to you

http://alanstorm.com/magento_system_config_validation

just understand carefully and you can definitely achieve this by server side validation.

hope this will sure help you.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top