Menu

dotnetikibot in intranet

Help
2011-07-29
2013-05-13
  • Peter Gassner

    Peter Gassner - 2011-07-29

    dotnetwikibot runs in an intranet without access to the internet. if i try to create a new page in an intranet-wiki, an error occur:

    Unbehandelte Ausnahme: System.Net.WebException: Der Remotename konnte nicht aufgel”st werden: 'meta.wikimedia.org'
       bei System.Net.WebClient.DownloadDataInternal(Uri address, WebRequest& request)
       bei System.Net.WebClient.DownloadString(Uri address)
       bei DotNetWikiBot.Bot.GetWebResource(Uri address, String postData)
       bei DotNetWikiBot.Site.GetWikimediaWikisList()
       bei DotNetWikiBot.Page.GetInterWikiLinks(Boolean inSquareBrackets)
       bei DotNetWikiBot.Page.AddToCategory(String categoryName)
       bei EORAbl”sung.Program.Main(String args)

    what means, that he can not access meta.wikimedia.org.

    what can i do?

    Thanks in advance, Peter.

     
  • CodeDriller

    CodeDriller - 2011-07-29

    DotNetWikiBot requires access to meta.wikimedia.org in order to get a list of languages and sister sites. If there is no need for this and no access to the internet, you should firstly set:

    public static string WMSitesStr = "m";
    public static string WMLangsStr = "en";
    

    and then set:

    Site.iwikiLinkRE = new Regex(@"(?i)\[\[((" + WMLangsStr + "):(.+?))]]\r?\n?");
    Site.iwikiDispLinkRE = new Regex(@"(?i)\[\[:((" + WMLangsStr + "):(.+?))]]");
    Site.sisterWikiLinkRE = new Regex(@"(?i)\[\[((" + WMSitesStr + "):(.+?))]]");
    
     

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.