• Resolved widewings

    (@widewings)


    Hi,

    I want to import settings on 1000 websites. I have root access on my server.

    I read in docs that I can do it with this code:

    try {
        wordfence::importSettings($token);
    } catch(Exception $e){ echo $e->getMessage(); }
    

    But I dont know where should I put this code? In functions.php? Call it via REST API?

    • This topic was modified 7 years, 11 months ago by widewings.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter widewings

    (@widewings)

    I did it in nasty way…

    
    <?php
    include ('wp-config.php');
    include ('wp-blog-header.php');
    try {
        wordfence::importSettings('token');
    } catch(Exception $e){ echo $e->getMessage(); }
    
    ?>

    and I copy this file to every domain. Then I used curl to execute it.

    • This reply was modified 7 years, 11 months ago by widewings.
    Plugin Support wfphil

    (@wfphil)

    Hello,

    I am awaiting a response from some colleagues to give you a comprehensive reply.

    Thank you.

    Plugin Support wfphil

    (@wfphil)

    Hello,

    A colleague has had a good look at this and has said that if it works for you then it is ok.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Wordfence Import Settings on Many Websites’ is closed to new replies.