Plugin Directory

Changeset 2192489


Ignore:
Timestamp:
11/14/2019 08:01:16 AM (6 years ago)
Author:
sach3932
Message:

Deactivation Hook Added

Location:
copy-code-to-clipboard
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • copy-code-to-clipboard/tags/1.1/copy-code-clipboard.php

    r2191421 r2192489  
    119119   
    120120<?php }
     121
     122//Deactivation Hook
     123// this code runs during plugin deactivation
     124function deactivate_copy_code_to_clipboard(){
     125   
     126//Delete Option
     127   delete_option( 'copy_text_label' );
     128   delete_option( 'copied_text_label' );
     129   delete_option( 'copy_text_label_safari' );
     130   delete_option( 'copy_text_label_other_browser' );
     131   delete_option( 'copy_button_background' );
     132   delete_option( 'copy_button_text_color' );
     133}
     134
     135register_deactivation_hook(__FILE__, 'deactivate_copy_code_to_clipboard');
  • copy-code-to-clipboard/trunk/copy-code-clipboard.php

    r2191421 r2192489  
    119119   
    120120<?php }
     121
     122//Deactivation Hook
     123// this code runs during plugin deactivation
     124function deactivate_copy_code_to_clipboard(){
     125   
     126//Delete Option
     127   delete_option( 'copy_text_label' );
     128   delete_option( 'copied_text_label' );
     129   delete_option( 'copy_text_label_safari' );
     130   delete_option( 'copy_text_label_other_browser' );
     131   delete_option( 'copy_button_background' );
     132   delete_option( 'copy_button_text_color' );
     133}
     134
     135register_deactivation_hook(__FILE__, 'deactivate_copy_code_to_clipboard');
Note: See TracChangeset for help on using the changeset viewer.