Plugin Directory

Changeset 2334769


Ignore:
Timestamp:
07/03/2020 10:26:07 AM (6 years ago)
Author:
cystack
Message:

update verification file.txt

Location:
cystack-security
Files:
3 edited
10 copied

Legend:

Unmodified
Added
Removed
  • cystack-security/tags/1.0.1/cystack-security.php

    r2333929 r2334769  
    55 * Plugin URI: https://cloud.cystack.net
    66 * Description: CyStack Security constantly monitors your websites and servers to detect security issues and vulnerabilities.
    7  * Version: 1.0.0
     7 * Version: 1.0.1
    88 * Author: CyStack
    99 * Author URI: https://cystack.net
     
    5454}
    5555
     56if ( ! defined( 'CYSTACK_PLUGIN_HOME' ) ) {
     57    include_once( ABSPATH . 'wp-admin/includes/file.php' ); // get_home_path()
     58    define( 'CYSTACK_PLUGIN_HOME', get_home_path() );
     59}
     60
    5661/**
    5762 * The code that runs during plugins activation
  • cystack-security/tags/1.0.1/src/Api/Connection.php

    r2333929 r2334769  
    2525        $wp_user_id = $wp_user->ID;
    2626        add_user_meta( $wp_user_id, 'cystack_email', $cs_user_email );
     27
     28        // add verification file
     29        $filepath = CYSTACK_PLUGIN_HOME . $meta_key . '.txt';
     30        file_put_contents( $filepath , $meta_value );
    2731    }
    2832
     
    3135     */
    3236    public static function disconnect() {
     37        $filename = get_option('cystack_meta_key');
     38        $filepath = CYSTACK_PLUGIN_HOME . $filename . '.txt';
     39        if ( file_exists( $filepath ) ) {
     40            unlink($filepath);
     41        }
     42
    3343        delete_option( 'cystack_targetId' );
    3444        delete_option( 'cystack_targetName' );
     
    4656     */
    4757    public static function clear_meta() {
     58        $filename = get_option('cystack_meta_key');
     59        $filepath = CYSTACK_PLUGIN_HOME . $filename . '.txt';
     60        if ( file_exists( $filepath ) ) {
     61            unlink($filepath);
     62        }
     63
    4864        delete_option( 'cystack_meta_key' );
    4965        delete_option( 'cystack_meta_value' );
  • cystack-security/trunk/cystack-security.php

    r2333929 r2334769  
    55 * Plugin URI: https://cloud.cystack.net
    66 * Description: CyStack Security constantly monitors your websites and servers to detect security issues and vulnerabilities.
    7  * Version: 1.0.0
     7 * Version: 1.0.1
    88 * Author: CyStack
    99 * Author URI: https://cystack.net
     
    5454}
    5555
     56if ( ! defined( 'CYSTACK_PLUGIN_HOME' ) ) {
     57    include_once( ABSPATH . 'wp-admin/includes/file.php' ); // get_home_path()
     58    define( 'CYSTACK_PLUGIN_HOME', get_home_path() );
     59}
     60
    5661/**
    5762 * The code that runs during plugins activation
  • cystack-security/trunk/src/Api/Connection.php

    r2333929 r2334769  
    2525        $wp_user_id = $wp_user->ID;
    2626        add_user_meta( $wp_user_id, 'cystack_email', $cs_user_email );
     27
     28        // add verification file
     29        $filepath = CYSTACK_PLUGIN_HOME . $meta_key . '.txt';
     30        file_put_contents( $filepath , $meta_value );
    2731    }
    2832
     
    3135     */
    3236    public static function disconnect() {
     37        $filename = get_option('cystack_meta_key');
     38        $filepath = CYSTACK_PLUGIN_HOME . $filename . '.txt';
     39        if ( file_exists( $filepath ) ) {
     40            unlink($filepath);
     41        }
     42
    3343        delete_option( 'cystack_targetId' );
    3444        delete_option( 'cystack_targetName' );
     
    4656     */
    4757    public static function clear_meta() {
     58        $filename = get_option('cystack_meta_key');
     59        $filepath = CYSTACK_PLUGIN_HOME . $filename . '.txt';
     60        if ( file_exists( $filepath ) ) {
     61            unlink($filepath);
     62        }
     63
    4864        delete_option( 'cystack_meta_key' );
    4965        delete_option( 'cystack_meta_value' );
Note: See TracChangeset for help on using the changeset viewer.