dolibarr-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Dolibarr-dev] How to display error message using jnotify


From: Florian Henry
Subject: Re: [Dolibarr-dev] How to display error message using jnotify
Date: Fri, 09 Nov 2012 06:28:33 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20121028 Thunderbird/16.0.2

Hello Marc Henri,

   The common functions to call for this is located in core/lib/function.lib.php

/**
 *  Print formated error messages to output (Used to show messages on html output).
 *
 *  @param    string    $mesgstring          Error message
 *  @param  array    $mesgarray           Error messages array
 *  @param  int        $keepembedded        Set to 1 in error message must be kept embedded into its html place (this disable jnotify)
 *  @return    void
 *
 *  @see    dol_print_error
 *  @see    dol_htmloutput_mesg
 */
function dol_htmloutput_errors($mesgstring='', $mesgarray='', $keepembedded=0)

or

/**
 *    Print formated messages to output (Used to show messages on html output).
 *
 *    @param    string    $mesgstring         Message
 *    @param    array    $mesgarray       Messages array
 *  @param  string    $style           Which style to use ('ok', 'warning', 'error')
 *  @param  int        $keepembedded    Set to 1 if message must be kept embedded into its html place (this disable jnotify)
 *  @return    void
 *
 *  @see    dol_print_error
 *  @see    dol_htmloutput_errors
 */
function dol_htmloutput_mesg($mesgstring='',$mesgarray='', $style='ok', $keepembedded=0)




    Put it after the llxHeader() in your php page like :

llxHeader();
     
print_titre('toto');

if ($error) {
    dol_htmloutput_errors('',$mesg_err,1);
}



Kind regards


Florian HENRY
address@hidden
+33 6 03 76 48 07
http://www.open-concept.pro

Le 09/11/2012 03:07, Marc-Henri Pamiseux a écrit :
Hi,

In some case, i can see an error message on the top of the page, in a
red/pink box. This box is an html <div> using the CSS class
"jnotify-message". Ok, but what is the name of the function that can
display such a message ? I can't find it as easily than i would believe.

Best regards


_______________________________________________
Dolibarr-dev mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/dolibarr-dev


reply via email to

[Prev in Thread] Current Thread [Next in Thread]