Jaysds1 Posted October 18, 2016 Share Posted October 18, 2016 Thanks @.:CiBeR:. for this kind update, hopefully no one asks for an updated offline version now. Link to comment
0xCiBeR Posted November 19, 2016 Share Posted November 19, 2016 On 18/10/2016 at 9:53 AM, Jaysds1 said: Thanks @.:CiBeR:. for this kind update, hopefully no one asks for an updated offline version now. You're welcome. Also the site has been updated, there is a new version of the wiki available as of 11-17-2016. Enjoy. 1 1 Link to comment
0xCiBeR Posted December 19, 2016 Share Posted December 19, 2016 Bump, latest update available: 12-19-2016 at http://mta.ggcommunity.net/arkives/ For some reason my linux machine got behind the clock and pulled the wiki 2 days later than intended, i've made a patch on the auto-updater to fetch online date fixing this error. Enjoy. 1 Link to comment
0xCiBeR Posted February 4, 2017 Share Posted February 4, 2017 Sorry for the late bump, latest version is now available http://mta.ggcommunity.net/arkives/ 1 Link to comment
Subtixx Posted February 17, 2017 Share Posted February 17, 2017 (edited) Since CiBeR's link is for some reason down. I took the time and wrote 2 Scripts in C# to export the MTA wiki. This will download all page names to a file called pages.txt using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; using System.Net; namespace Rextester { public class Program { public static string DownloadPage(int iteration, string url) { using(WebClient wc = new WebClient()) { Console.WriteLine("Requesting page: " + System.Web.HttpUtility.HtmlDecode(url)); Uri uri = new Uri("https://wiki.multitheftauto.com" + System.Web.HttpUtility.HtmlDecode(url)); string page = wc.DownloadString(uri); //System.IO.File.WriteAllText(iteration + ".txt", page); try { Regex regexObj = new Regex("<li><a href=\".*?\" title=\".*?\">(.*?)</a></li>"); Match matchResults = regexObj.Match(page); while (matchResults.Success) { System.IO.File.AppendAllText("pages.txt", matchResults.Groups[1].Value+Environment.NewLine); // matched text: matchResults.Value // match start: matchResults.Index // match length: matchResults.Length matchResults = matchResults.NextMatch(); } } catch (ArgumentException ex) { // Syntax error in the regular expression } Match match = Regex.Match(page, "<a href=\".*?\" title=\"Special:AllPages\">Previous page .*?</a> \\| <a href=\"(.*?)\" title=\"Special:AllPages\">Next page .*?</a>"); if(match.Success) { Console.WriteLine("Got next page: " + match.Groups[1].Captures[0].Value); return match.Groups[1].Captures[0].Value; }else{ Console.WriteLine("Failed to download or last page (" + url + ")!"); } return ""; } } public static void Main(string[] args) { using(WebClient wc = new WebClient()) { string indexPage = wc.DownloadString("https://wiki.multitheftauto.com/index.php?title=Special:AllPages"); Match match = Regex.Match(indexPage, "<a href=\"(.*?)\" title=\"Special:AllPages\">Next page .*?</a>"); if(match.Success) { string nextPage = match.Groups[1].Captures[0].Value; int iteration = 0; while(nextPage != "") { string prev = nextPage; nextPage = DownloadPage(iteration, nextPage); Console.WriteLine("Got: " + nextPage + " | PrevPage: " + prev); iteration++; } }else{ Console.WriteLine("Failed to download index page!"); Console.WriteLine(indexPage); } } } } } This will parse the pages.txt and download a file called export.xml which can be re-imported into a mediawiki: using System; using System.Text; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; using System.Net.Http; using System.Net.Http.Headers; using System.Threading; using System.Threading.Tasks; namespace Rextester { public class MyFormUrlEncodedContent : ByteArrayContent { public MyFormUrlEncodedContent(IEnumerable<KeyValuePair<string, string>> nameValueCollection) : base(MyFormUrlEncodedContent.GetContentByteArray(nameValueCollection)) { base.Headers.ContentType = new MediaTypeHeaderValue("application/x-www-form-urlencoded"); } private static byte[] GetContentByteArray(IEnumerable<KeyValuePair<string, string>> nameValueCollection) { if (nameValueCollection == null) { throw new ArgumentNullException("nameValueCollection"); } StringBuilder stringBuilder = new StringBuilder(); foreach (KeyValuePair<string, string> current in nameValueCollection) { if (stringBuilder.Length > 0) { stringBuilder.Append('&'); } stringBuilder.Append(MyFormUrlEncodedContent.Encode(current.Key)); stringBuilder.Append('='); stringBuilder.Append(MyFormUrlEncodedContent.Encode(current.Value)); } return Encoding.Default.GetBytes(stringBuilder.ToString()); } private static string Encode(string data) { if (string.IsNullOrEmpty(data)) { return string.Empty; } return System.Net.WebUtility.UrlEncode(data).Replace("%20", "+"); } } public class Program { public static void Main(string[] args) { Task.Run(async () => { using (var client = new HttpClient()) { string text = System.IO.File.ReadAllText("pages.txt"); var values = new Dictionary<string, string> { {"catname", ""}, {"pages", text}, {"curonly", "1"}, {"templates", "1"}, {"wpDownload", "1"}, {"wpEditToken", "%2B%5C"}, {"title", "Special%3AExport"} }; var content = new MyFormUrlEncodedContent(values); var response = await client.PostAsync("https://wiki.multitheftauto.com/wiki/Special:Export", content); var responseString = await response.Content.ReadAsStringAsync(); System.IO.File.WriteAllText("exported.xml", responseString); } }).GetAwaiter().GetResult(); } } } To convert the xml to sql you can use mwdumper like this: java -jar mwdumper.jar --format=sql:1.5 exported.xml > sql.sql Edited February 17, 2017 by KennyKiller Link to comment
0xCiBeR Posted February 22, 2017 Share Posted February 22, 2017 (edited) Sorry for that, i'm currently moving to a new hosting.. Some down time expected. EDIT: Site is back online, though it's having some page load timeouts, i'm sorting this out with support team. EDIT2: Damn microtime, freezes the server. Removed it and now all is working. Edited February 23, 2017 by .:CiBeR:. 1 Link to comment
0xCiBeR Posted April 20, 2017 Share Posted April 20, 2017 Site es running and update is pushed. Enjoy-. 1 1 Link to comment
Fist Posted April 20, 2017 Share Posted April 20, 2017 2 hours ago, .:CiBeR:. said: Site es running and update is pushed. Enjoy-. Thanks mate! Was waiting for this. Link to comment
0xCiBeR Posted May 18, 2017 Share Posted May 18, 2017 Update pushed yesterday, enjoy! http://mta.ggcommunity.net/arkives/ 1 Link to comment
0xCiBeR Posted July 26, 2018 Share Posted July 26, 2018 Well, it's been a while since the site went down, and i haven't had the time to get it up and running again, but now i made some time. Regretfully, old backups are lost, if anyone has a backup of the old arkives i'd be happy to re upload them. The new site is running here: https://nas.globalgaming.xyz/mta/ and will be updated once a month via a cron job. Hope you'll enjoy. 2 1 Link to comment
DiGiTal Posted August 29, 2018 Share Posted August 29, 2018 On 26/07/2018 at 15:42, .:CiBeR:. said: Well, it's been a while since the site went down, and i haven't had the time to get it up and running again, but now i made some time. Regretfully, old backups are lost, if anyone has a backup of the old arkives i'd be happy to re upload them. The new site is running here: https://nas.globalgaming.xyz/mta/ and will be updated once a month via a cron job. Hope you'll enjoy. It doesnt have colors or images how to fix it ? Link to comment
0xCiBeR Posted September 17, 2018 Share Posted September 17, 2018 On 29/08/2018 at 12:32, DiGiTal said: It doesnt have colors or images how to fix it ? What do you mean? Link to comment
DiGiTal Posted September 18, 2018 Share Posted September 18, 2018 15 hours ago, .:CiBeR:. said: What do you mean? It lookinh simple html page.means i see only text on the page without pictures Link to comment
0xCiBeR Posted January 25, 2019 Share Posted January 25, 2019 On 18/09/2018 at 07:21, DiGiTal said: It lookinh simple html page.means i see only text on the page without pictures Sorry for the late reply. I downloaded last version and its ok. Link to comment
Feche1320 Posted January 27, 2019 Share Posted January 27, 2019 Downloaded latest version, thanks Link to comment
=KoG=Rouche Posted March 21, 2019 Share Posted March 21, 2019 Thank you CiBeR. Usefull link. Link to comment
DiGiTal Posted December 9, 2019 Share Posted December 9, 2019 @.:CiBeR:. So? your website stopped any link for last update? Link to comment
Haxardous Posted December 31, 2019 Share Posted December 31, 2019 On 10/12/2019 at 01:40, DiGiTal said: @.:CiBeR:. So? your website stopped any link for last update? https://qaisjp.github.io/wiki-dump/wiki.localhost/wiki/Main_Page.html Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now