Centered 2 Column Design

September 24th, 2004

After successfully finding a centered 2 column design and hacking it to pieces before installing it on my own site, I had some trouble with forms, IE 5.2 Mac, and the two column layout. I thought I would share my experience with all of you here.
I’ll pretty much cut to the chase, but I wanted to point out that for some reasonALA’s form did not work for me. There were a variety of others that I found that also didn’t work, I can’t say why because I really don’t know. I think it had something to do with my wanting the form on the left side of a 2 column layout.
So the final solution was this:

<div id="allcontent">
<h4> Interested in Pixel Conductor's services? </h4> <h5> Send him a note below. </h5>
<div id="leftcontent">
<div id="form">
<form method="post" action="http://www.pixelconductor.com/cgi-bin/cgiemail/cgiemail/station.txt">
<div>
<label for="name">Name:</label><input type="text" name="name" id="name" />
</div>
<div>
<label for="email">E-mail:</label><input type="text" name="email-required" id="email" />
</div>
<div>
<label for="text">Request:</label>
<textarea name="request" id="text" cols="20" rows="8">
</textarea>
</div>
<div>
<input type="submit" value="Send Your Message" class="formbutton" />
</div>
<div class="spacer">
</div>
</form>
</div>
</div>
<div id="rightcontent">
<img src="/images/ticketstub.jpg" alt="Ticket Stub" />
</div>
</div>

(Thanks to BBedit for the code converison.)

Nothing special here, just three main divs, one that holds everything and one for each side. The CSS here:
div#form {
width: 320px;
padding: 0;
margin: 1em;
margin-top: 0;
border: 1px solid #AF9101;
text-align: right;
}

label, input, textarea {
display: block;
width: 180px;
float: left;
margin-bottom: 10px;
}

label {
text-align: right;
width: 100px;
padding-right: 10px;
}

input.formbutton {
margin-left: 110px;
width: 80px;
width: auto;
text-align: center;
padding-right: 2em;
}

This bit of code comes mostly from a form on html dog. It seems that getting the textarea and associated label to line up correctly was the most difficult part, (which actually doesn’t happen on the html dog site, but does on the ALA site) IE Mac does not like placing a label to the left of a text box. Ah well, so bask in it’s functionality and let me know if you have any better solutions.

Managing DNS Servers

September 18th, 2004

I never cease learning. Today I woke up worrying about a site I just moved to a new server. For some reason the DNS hadn’t propagated overnight. In my experience this usually takes a couple hours at most. After dinking around for a couple of minutes wondering if it was ever going to change, a light bulb went off in my head. Why not use the new DNS server as my DNS server, then I would be sure to get the moved site as opposed to the old site.

The additional benefit of this thought cloud is raining down on me harder than the deluge outside. This is AMAZING! This means that whenever I move a site I can move it to the new server, tell that host that the site is going to be moved so they update their DNS servers, and then before I ever actually switch over, I can plug in their DNS server into my Network Control Panel and see and work on the new site as it will appear until I’m satisfied and then I can make the official switch later.

Have a great weekend everyone.

pixelconductor.com

September 16th, 2004

At long last I have found enough free time between working on livesuperfoods (selling health food online soon) and my various other projects to put together a site advetising my coding skills and my freedom to work for others.

I am actually quite happy with the result and pleased with myself for getting it together so quickly. It was a battle with CSS once again to get the placement of everything correct, and I still haven’t figured out how to do two columns of div’s centered on the page, but that will come soon. Thanks to glish for their reservoir of good coding for some hints to get me pointed in the right direction.

Only one more thing on my agenda and that is to wait for my new PC to come in the mail. I finally broke down, mostly because of the various bugs in IE Win CSS and bought a bran-spanking-new 2.4 GHz machine so that I can hack my standards compliant coding into pieces that actually work in that environment. Ah well, you can’t win everything I guess. If anyone is looking for a standards compliant hand coder for websites let me know.