Jun

17

Disable Firefox 3 AwesomeBar

I just downloaded FireFox 3 and I'm pretty happy with it. It's fast and works well. The AwesomeBar is a cool feature, but I generally don't like auto-complete (EDIT: for bookmarks or previously typed-in URLs) in a browser, so having it search my entire bookmarks and list all the possible matches is something I wanted to disable. If you're annoyed by the Firefox 3 AwesomeBar (or SmartBar or whatever it's called) like I am, there's an easy way to display it.

Warning: if you are unfamiliar with FireFox's about:config settings, be VERY careful following these steps as you could hose your browser.

  • In the address field, type "about:config", without the quotes, and hit enter
  • In the filter field, type "browser.urlbar", also without the quotes, and hit enter
  • Double-click on the line with browser.urlbar.matchBehavior, change the value in the popup to 0, and click OK
  • Double-click on the line with browser.urlbar.maxRichResults, change the value in the popup to 0, and click OK
  • Now restart FireFox and enjoy!

EDIT: I should clarify that my intent is to COMPLETELY disable the AwesomeBar, not turn it into the old type-in-address-only-matching address bar from FireFox 2.

Jun

16

Sending Email From PHP On GoDaddy (And Possibly Other Hosts)

Recently, while working on the temporary site for Moonfar, I wanted to send the user an email as confirmation that they had signed up for email notifications. Essentially, you define the recipient, the subject line, the body, a few headers, and then call the mail() function while passing those parameters to it. PHP's mail() function does the rest, provided that your host has PHP configured properly.

Let me preface this by saying that I've only tested this on GoDaddy's Linux Deluxe Hosting plan. If you are trying to do this with another web host, you need to make sure that the install of PHP you are using supports the mail() function.

<?php
  $to = 'user@theirdomain.com';
  $subject = 'Your subject line';

  // the message here is HTML, but you could
  // use plain text in the same manner
  // this could also be pulled from a template file
  $message = '
    <html>
    <head>
      <title>Your Title Here</title>
    </head>
    <body>
      <p>Your content here...</p>
    </body>
    </html>';

  // To send HTML mail, the Content-type header must be set
  $headers  = 'MIME-Version: 1.0' . "\r\n";
  $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
  // Additional headers
  // I'm not sure how the To: field in the header functions since it's part
  // of the function call, so I've commented it out here
  //$headers .= 'To: ' . $emailAddr . "\r\n";
  $headers .= 'From: YourName <you@yourdomain.com>' . "\r\n";
  $headers .= 'Cc: ' . "\r\n";
  // if you want to receive a copy
  $headers .= 'Bcc: you@yourdomain.com' . "\r\n";

  // Mail it
  mail($to, $subject, $message, $headers);
?>

It's as easy as that. That said, I read somewhere that there is a 1000 emails per day limit using this method on GoDaddy without paying for outbound emailing services, but I could be mistaken.

Jun

15

WebVisions 2008 Conference Debriefing

I recently attended the WebVisions 2008 conference in Portland, OR. It was my first conference, so I can't speak to the quality with much experience. However, my general opinion was that there was some good, some bad, and some ugly, as one might expect. That said, the good was well worth the experience. Plus, I won the grand prize raffle: Adobe CS3 Premier. Although, as of the date of this post, I have not yet received it.

You can find the podcasts of the presentations and the associated presentation slides with these links:

Here is a quick debriefing of my impressions of the presentations and the most important things I learned

Blogging For A Living

Jim Turner

http://www.genuineblog.com/

  • Bloggers are social media managers
  • Be an evangelist through your blog
  • Monitor the net for negative or inaccurate information about your organization and use your blog to rapidly respond and provide an official statement to correct misinformation
  • "Control is an illusion. You can't control what is being said. It's already happening. You can't stop employees from spreading information, so push forward with positive blogging." (Paraphrased)

Hacking Social Media

DL Byron

http://texturadesign.com/

http://bikehugger.com/

  • DL was a very inspiring individual, but there wasn't much that I was able to draw from the presentation except for providing examples of how small organizations can combine (through mashups, etc.) services for cheap, rich aggregate tools.

Design Is In The Details

Dan Rubin, Bryan Veloso

http://design.isinthedetails.com/

http://bryanveloso.com/

http://superfluousbanter.org/

  • Great presentation. The best of the conference.
  • Let your layout breathe
    • Allow space between elements
    • You don't need borders on elements if you have 2 elements with a different colored space in between, such as two white boxes with a gap between them on a black background
  • Multiples and factors of a common measurement
    • If your main text font is 12px, then 6, 12, 18, 24, etc. for margins and other sizes are a good way to keep common feel through your site
  • Subtle effects
    • Use effects subtly, such as in drop shadows
    • Add noise for a subtle texture on a background to add a real-world feel
  • To get varying shades of the same color, pick your base hue, then add layers of black or white using soft light blending mode and transparencies to achieve shades and tints

Drupal

Sean Larkin

http://www.opensourcery.com/

  • This presentation sucked was less of a "howto" and more of a "this is how we make money" presentation. I wanted to hear more about how to use Drupal.

Faster, Cheaper, Better

David Verba

http://www.adaptivepath.com/aboutus/david.php

  • This was essentially a review of how it's cheaper and faster to make web apps now, which is obvious and doesn't require a conference session to make that point.
  • Saying "…and finally…" 6 times is 5 times too many.

CSS Transformation

Christopher Schmidtt

http://christopherschmitt.com/

Ruby On Rails

Jim Meyer

http://www.cucinamedia.com/

http://blog.geekdaily.org/

  • Very pro-Agile Dev and pro-TDD (Test Driven Development)
  • For any development, to improve scalability and performance:
    • Stay out of the DB as much as possible
    • Stay out of the dynamic code as much as possible
    • Push info (code?) as close to the user as possible

Web Site Optimization

Kimberly Blessing

http://www.kimberlyblessing.com/

  • Analyze, test, and tune
  • Validate
    • declare a valid DOCTYPE to ensure that the browser will stay in STANDARDS MODE, otherwise it will go into QUIRKS MODE which will cause slower rendering
    • Validate (X)HTML/CSS
  • Simplify
  • Concatenate
    • Use only 1 CSS file and 1 JS file; you can always merge at the build cycle if you prefer to keep them separate for development organization
  • IE-Proof CSS
    • Code against the FOUC (Flash Of Unstyled Content)
    • Don't use @import, use link
  • Call Javascript As Needed
    • Define JS near where it is needed
  • Save Scripts For Last
    • If it isn't needed on load, define it at the end of the page to prevent parsing until the page has displayed
  • If you can't GZip, then strip
    • Get rid of whitespace and comments, convert spaces to tabs (if you want to save spacing) in build phase