Another Job Site

January 29, 2007

Another job site was launched today and I am going be following the progress of this site closely. There are more than a few job sites on the web today (Monster, CareerBuilder, etc...), but this one is being powered by a key Match.com developer as well as Telligent. It will be intersting to see how well jobBurner will match up Employers with prospective Employees! 

Looking quickly at my area, there are only two postings and they are not really in my area. I hope this grows over the next few weeks since I may be looking at the site for more reasons than just seeing the site progress!

Snap no more!

January 27, 2007

Apparently I am not the only one to think that "Snap" is one of the most annoying trends in the web/blog-sphere these days! When I mouse over a link I almost always am doing it to either 1) click on it or 2) see where it is pointing to in the status bar. When that window pops up it always grabs my attention and usually leads to an explicative flying out of my mouth.

For all you Snap Haters out there, hate no more because you can disable Snap! Mouse over a Snap pop-up and click on options, the you can opt-out for all sites!

Good Riddance.

What on Earth?

January 27, 2007

I was just browsing some spots on Google Maps and noticed some pretty strange looking water!

Anyone have any ideas? Is it just in some frozen state? Is there a nuclear power plant nearby?

Jeff Atwood posted up a C# implementation of Identicons the other day. While I do not see them being all that useful, they are pretty neat. I whipped up a little [csl] Add-on that can display an Identicon.

The code is more or less right from Jeff; I modified image caching to use [cs] caching rather than the straight up HttpRuntime Cache. 

I currently use this as a replacement link for the comments permalink in my blog (it used to use '#'). To see an example of these in action, just make a comment on this blog post. Once your comment appears you should have your unique Identicon!

This [cs] Add-On is packaged up into the CarKnee Bundle.

A couple of members on the Community Server forums wanted a way to block new members based on known SPAM domains. This sounded like a great idea for a CSModule. I looked at the list of events and saw that there is an event fired off before and after a user is created! Great! The PostUserUpdate event fires off after the user has been added to the database. This seems like the perfect place to change their account status, or moderation level, based on their email address.

The PostUserUpdate event allows me to modify the user before or after they are created, but it will not allow me to stop the registration process. While I could have just destroyed the user in the module, this would throw a nasty little error. Furthermore, if the person was legit you would need to disable the module to register them. With auto-banning them you can change them from banned to not-banned (or moderated to not moderated) in the control panel. The other possibility, which I hadn't tried, was that I could modify the user and set their email address to the anonymous user's email (anonymous@localhost.com) and this would throw a duplicate email address error. This module will not prevent a user from registering based on email.

This CSModule runs off of the PostUserUpdate event. If the user's email address matches a regular expression then we modify their account as either Banned or Moderated. We configure the module in the CommunityServer.config file as follows:

<add name = "NewMemberModerationModule" type = "CarKnee.CS.Bundle.NewMemberModerationModule, CarKnee.CS.Bundle">
<add domain="mailinator\.com$" action="ban" />
<add domain="(.+)freemail(.+)" action="moderate" />
</add>

We set the domain we want to match and the action we want to take (ban or moderate). It is that simple!

If a user is banned, they will not be able to make a post at all. They will get a message saying that their account has been banned for spamming. 

If a user is Moderated, they will get a message saying that their post needs to be approved. Note that this will only work if a forum is configured to moderate posts!


 

I toyed around with other options such as setting their account status to "Pending," but Community Server auto-logs in the user after registration (if the site is setup for automatic approval) even though their status is set to Pending. I do believe this is a bug! I think line 436 of CreateUser.cs should look something like:

if (csContext.SiteSettings.AllowLogin && user.AccountStatus != UserAccountStatus.ApprovalPending)

If the site didn't log them in automatically, they would be presented the following message upon login:

 

Since ApprovalPending didn't work I limited this Module to either a Ban or Moderate setting.

The code for the module is also pretty simple, but it is a bit long to post here.

This CSModule along with the "Top Poster Role Management Job" are packaged together into the "CarKnee Bundle"

Download Here: http://www.carknee.com/files/folders/cs/entry82.aspx 

Defrag your server

January 18, 2007

It seems that my fancy dancy server needs to run defrag every couple days. The site is running a well visited site (and some other not so visited sites) and is creating 300MB Log Files from IIS, as well as user uploaded files, etc... All of this is really fragmenting my nice and speedy data drive (actually, 2 drives in a RAID 1 configuration).

I hear a lot about the Windows Defrag program is an outdated POS and that you should  consider using DiskKeeper's newer products. It seems reasonable since Diskeeper is constantly running making sure your files aren't fragmented, but is it worth the $300 MSRP?

Does anyone have any thoughts to this?  [tags:Server]

Drivers on a Floppy?

January 15, 2007

A little rant here...

I purchased a Zonet GigE NIC (ZEN3301E) card a couple months back and finally got around to installing it. Installing a NIC shouldn't be too difficult, right? I threw it in, powered up the PC (actually, my backup web server) and let Windows (Server 2000) configure it. Windows didn't have the driver for it, but the NIC came with a floppy disk with the drivers.

Side Note:  I am not a big fan of floppies. In fact, I can't remember the last time I used one successfully! It seems that every floppy I get is busted, or all of my floppy drives are busted.

Well, my backup web server doesn't have a floppy drive installed on it. (It doesn't even have a CD-ROM drive in it.) Off to Zonet's web site to download their latest drivers. Guess what. No drivers listed. (They have since posted them). Now, being a person who has built many PC's for people I knew that chipset manufacturer's drivers typically work. I looked at the chip on the NIC and downloaded their driver and it works no problem.

If you are a manufacturer, try to post your drivers before you start releasing your products to major manufacturers!

[tags:Rants, Web Server]

DVR Rant

January 11, 2007

I just want to rant a little about Cablevision's IO HD DVR. The thing sucks! Sure, DVR's are great; when they work! I have been really busy every night working on the house and last night I quit early and wanted to catch up on last Thursday's episodes of "My Name is Earl" and "The Office". Guess what. "The Office" didn't record for some unknown reason. *ARGH* Looking back over my recorded list I am seeing a few programs didn't get recorded. I am annoyed.

While I am on a Cablevision Rant... I hate having my bandwidth throttled. I am currently living in a co-op and Verizon's FiOS isn't avaiable. You can be sure that when I move into my house I will be calling up verizon!

[name:Gadgets]

I am posting this just as a teaser, and to force myself to keep to my word... I have other CS Add-Ons that I will try to release when I get time to package them up. I wrote a few good ones about 6 months ago and have yet to release them. My favorite of the bunch is a "Site Supporter Add-On!"

The Site Supporter add-on will allow donations to be made to you and you will then assign that person to a Role. The Add-On is extensible so you are not limited to PayPal either. It is along the lines of Sean Winstead's Subscriber Add-On.

The main driver for me to write these add-ons is that I have been evaluating the migration of www.rswarrior.com from Snitz over to Community Server. RSWarrior is pretty heavily modified and I would need at least some of the core features in order to move over to Community Server. A big part of RSWarrior is the "Site Supporter" status that members can have. I needed to duplicate that feature and the answer was my "Site Supporter Add-On."

Some other Add-ons I have written for the new (pending) RSWarrior.com is a Links manager and Photo Gallery extender.

Stay tuned ;)

[tags:Community Server]

 

"Rocket City Web" of the Community Server forums asked if it is possible to limit top posting members to a certain forum. At first, I had though the member points system would be perfect for this. However, Member Points is an add-on and not available for the "Personal Edition" of Community Server. Dave Burke mentioned that you should just add top posting users to a specific Role and grant that Role access. I thought this would be perfect for a CSJob!

This was created in all of 15 minutes and it is all packaged up nicely for you here.

Here's the code:

public class AddPostersToRoleJob : IJob
{
private int minPosts = -1;
private string roleName = String.Empty;

public AddPostersToRoleJob() { }

public void Execute(XmlNode node)
{
try { minPosts = int.Parse(node.Attributes["minPosts"].Value); }
catch { }

try { roleName = node.Attributes["roleName"].Value; }
catch { }

// It is required that the job be setup properly
if (minPosts <= 0 || String.IsNullOrEmpty(roleName))
return;

SiteSettingsManager.IterateSiteSettings(new SiteSettingsListIterator(AddPosters));
}

private void AddPosters(int settingsid)
{
CSContext.Create(settingsid);

// get the users.
UserQuery q = new UserQuery();
q.PageSize = int.MaxValue;
UserSet users = Users.GetUsers(q, false);

// If there are no users, get out.
if (!users.HasResults)
return;

// Loop Through the users
foreach (User u in users.Users)
{
// if the posts are above the specified min
if (u.TotalPosts >= minPosts)
{
// and they are not already in the role
if (!u.IsInRoles(new string[] { roleName }))
{
// add them to the role
Roles.AddUserToRole(u.Username, roleName);
}
}
}

}
}

The routine is fairly straight forward. When the job executes it gets the specified minimum posts and role name from the communityserver.config file. The one part that could have some discussion is the SiteSettingsManager.IterateSiteSetting method. I like to programatically loop through all sites in my CS installation, but you could hard code the default SettingsID of 1000 if performance is an issue.

Let me know how it works out for you if you use it!