Sha256: 65e3718bf2da22369127d35c45e6d97c83f33a0db195e42902bcc0b6c00a3de7

Contents?: true

Size: 375 Bytes

Versions: 8

Compression:

Stored size: 375 Bytes

Contents

#!/usr/bin/env ruby
#
# Sample script for searching page contents in a Wiki
#
require './lib/media_wiki'

config = MediaWiki::Config.new ARGV 
config.abort("Please specify search key as article name (-a)") unless config.article

mw = MediaWiki::Gateway.new(config.url, { :loglevel => Logger::DEBUG } )
mw.login(config.user, config.pw)
puts mw.search(config.article, nil, 50)

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mediawiki-gateway-0.6.2 samples/search_content.rb
mediawiki-gateway-0.6.1 samples/search_content.rb
mediawiki-gateway-0.6.0 samples/search_content.rb
mediawiki-gateway-0.5.2 samples/search_content.rb
mediawiki-gateway-0.5.1 script/search_content.rb
mediawiki-gateway-0.5.0 script/search_content.rb
mediawiki-gateway-0.4.5 script/search_content.rb
mediawiki-gateway-0.4.4 script/search_content.rb