So, to help make my obsession with Left 4 Dead worse than it already is, I put up a dedicated L4D server on my server. The server has been put up as a MassiveLAN group server for all attendees and staff of MassiveLAN to battle on. So, if you’re a Left 4 Dead player, feel free to either connect directly to, or through the MassiveLAN steam group, the server: l4d.jonnyfunfun.net:27015. The server runs 24/7 and hosts only Versus mode. There are some tweaks to the config that will come down within the next few weeks, so please bear with me on that front. If anybody has any problems, complaints, or suggestions, feel free to post a comment here or send me an e-mail and I’ll see what I can work out!
Attendees,
Config,
Dead Server,
Dedicated Server,
E Mail,
Group Server,
Net Server,
Obsession,
Server Help,
Steam,
Tweaks
Posted by JonnyFunFun in C#
Okay, so I had a few problems today getting a simple C# application of mine to do what I wanted it to do. To make a long story short, I had some issues getting a WebRequest object to upload a slew of files via POST to a web-based form. Turns out that there is no simple way to do this in .Net – which is quite surprising because it’s quite easy to do just about everything in .Net. So, I did what every good developer does…I rolled my own class to take care of the problem: the JonnyFunFun.Net.FormPost class.
The class makes it easy for you to POST/GET variables to a web-based form with or without uploading files. Take for example this code:
List<string> FilesToUpload = new List<string>();
FilesToUpload.Add("c:\\debug.txt");
FilesToUpload.Add("c:\\upload_me.jpg");
FormPost form = new FormPost("http://www.jonnyfunfun.com/");
form.Method = FormPost.FormMethods.POST;
Dictionary<string, string> FormVariables = new Dictionary<string, string>();
FormVariables.Add("var1", "one");
FormVariables.Add("var2", "two");
WebResponse resp = form.PostWithFiles(FormVariables, FilesToUpload);
This code sends the var1 and var2 values in the FormVariables dictionary along with all the files specified in the FilesToUpload list. To make everybody else’s life easier, I’ve posted the class code and put it up using the GNU GPL. The only thing I ask for is that if you decide to use the code, or a derivative of it, in your own software project that you simply send me an e-mail and let me know! I like to see where my code ends up, and it makes a great thing to add to my resume! So, what are you waiting for – get the code!
C Application,
Class Code,
Debug,
Derivitive,
Dictionary,
Dictionary Files,
E Mail,
Gnu Gpl,
Jpg,
List Txt,
Lt,
New List,
Own Software,
Resume,
Send Mail,
Simple C,
Sleu,
Slew,
Software Project,
String String,
Upload,
Upload Files,
Uploading Files,
Variables,
Web Based