"Fossies" - the Fresh Open Source Software Archive

Member "canopy-3.0.7/javascript/confirm/readme.txt" (1 Nov 2019, 733 Bytes) of package /linux/www/canopy-3.0.7.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 To use:
    2 
    3 // Question asked by confirm box
    4 $js_variables['QUESTION'] = 'Are you sure you want to delete this?';
    5 
    6 // Address to go to if they the user clicks yes
    7 $js_variables['ADDRESS'] = 'index.php?module=mymod&command=delete_it';
    8 
    9 // What they are clicking on - text or image
   10 $js_variables['LINK']     = 'Delete This';
   11 
   12 // Title for confirm link
   13 // make sure to add slashes
   14 $js_variables['TITLE'] = 'Delete link';
   15 
   16 // class for link
   17 $js_variables['CLASS'] = 'confirm-link';
   18 
   19 // If you want a button instead of a link.
   20 //$js_variables['type'] = 'button';
   21 
   22 $link = Layout::getJavascript('confirm', $js_variables);
   23 
   24 
   25 ----------------------------------------------------------------
   26 Make sure to run addslashes() on your variables!