Menu

Do you know pywikipedia?

2005-01-10
2013-04-17
  • Bananeweizen

    Bananeweizen - 2005-01-10

    Hi,

    do you know the pywikipedia project on SF? Maybe you should have a look at it to avoid reinventing the wheel...

    Ciao, Michael.

     
    • Borislav Manolov

      Yes, I know it, but I've developed the bot before I had heard about it. However I do not intend a further development :-).

       
    • DansGalaxy

      DansGalaxy - 2007-02-20

      how do i use this project?!?

       
      • Borislav Manolov

        Here a very simple php script:

        <?php
        require 'bgbot.php';

        $wiki = 'XX';
        $user = 'USERNAME';
        $pass = 'xxxxxxxx';
        $sleep_time = 60; // sleep 60 secs between edits
        $bot = new Bgbot($wiki, $user, $pass);

        $pages = array('page_1', 'page_2', 'page_3');

        foreach ($pages as $page) {
            if ( $bot->edit($page, $wiki, false) ) {
                $content = $bot->page_content;
                // do something to $content
                $summary = 'my summary for this edit';
                $bot->submit($content, $summary, $wiki);
                sleep($sleep_time);
            }
        }
        ?>

         

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.