<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>HTMList.com, A Web Development Blog by Synapse StudiosHow To   </title>
	<atom:link href="http://www.htmlist.com/category/how-to/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.htmlist.com</link>
	<description>A Web Development Blog by Synapse Studios</description>
	<lastBuildDate>Thu, 19 Jan 2012 09:30:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Better Group (And Personal) Password Management with KeePass &amp; Dropbox</title>
		<link>http://www.htmlist.com/cool-stuff/better-group-password-management-with-keepass-dropbox/</link>
		<comments>http://www.htmlist.com/cool-stuff/better-group-password-management-with-keepass-dropbox/#comments</comments>
		<pubDate>Wed, 26 Jan 2011 05:58:12 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[Cool Stuff]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[dropbox]]></category>
		<category><![CDATA[encryption]]></category>
		<category><![CDATA[group passwords]]></category>
		<category><![CDATA[keepass]]></category>
		<category><![CDATA[password management]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=627</guid>
		<description><![CDATA[Managing multiple passwords within a group while maintaining security, good practices, and synchronization can be a challenge. We explore our utilization of a program called KeePass and a file-sharing system called Dropbox to help manage passwords.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.htmlist.com/wordpress/wp-content/uploads/2011/01/main.jpg"><img class="alignleft size-full wp-image-628" title="KeePass Screenshot" src="http://www.htmlist.com/wordpress/wp-content/uploads/2011/01/main.jpg" alt="" width="300" height="206" /></a>As a <a title="Phoenix, Arizona Web Development &amp; Design &amp; Custom Software" href="http://www.synapsestudios.com/">web development firm</a>, we frequently have to manage passwords and other credentials for multiple clients and their projects. This includes everything from SFTP and SSH information, database passwords, DNS managers, domain registrars, and everything else under the sun. We&#8217;ve moved to a policy of good password practice across the board at the urging of common sense, and one of our former developers, <a href="http://alanhogan.com/">Alan Hogan</a>. (Our previous system was not sharable, and wrought with other shortcomings.)</p>
<p>We needed a password system that was secure but which would allow us to share client passwords across our team, while ensuring limited access within the organization, and unique, complex passwords every single time. We ended up making use of the wonderful <a href="http://www.keepass.info">KeePass</a> tool, synced through <a title="Dropbox" href="http://db.tt/iFL8DPs">Dropbox</a>.</p>
<p>KeePass is a wonderful password manager (though not as much for Mac or Linux users, for reasons I&#8217;ll get to) in general. And it has some pretty great features, some unique to KeePass, others relatively standard fare:</p>
<p><span id="more-627"></span></p>
<p><strong>Strong Security</strong><br />
Clearly, any good password manager needs to be secure itself. KeePass supports AES and TwoFish, amongst other encryption standards that are very difficult to crack. Your password database is duly encrypted thusly. Further, you can expand your security by requiring the use of a unique key file in addition to (or instead of, though this isn&#8217;t recommended) the password you use to unlock the database. This adds an additional layer of security against things like keyloggers, in that the hacker must have access to and identify the key file to use, in addition to knowing or cracking your password. (A strong password is still important, since simple passwords will fall to <a href="http://en.wikipedia.org/wiki/Dictionary_attack">dictionary attacks</a> relative quickly.) You can also use your Windows login to unlock your database, but again, this shouldn&#8217;t be your only method to unlock, and this doesn&#8217;t work when sharing a password database as we do.</p>
<p>KeePass also goes to some length to keep your passwords completely out of process memory. This keeps malicious software from identifying passwords in the memory stream of the process while it&#8217;s running. It also can be configured to automatically purge the computer&#8217;s clipboard after a set period of time, to prevent a user from walking up to your computer and hitting paste and hoping for the best.</p>
<p><strong>Workspace Locking</strong><br />
Workspace locking goes hand-in-hand with strong security, itself being a subset of the program&#8217;s security. You can easily configure KeePass to automatically re-lock your database after a period of system OR KeePass inactivity, when the software is minimized, or when your workstation itself is locked. (I&#8217;ve noticed that it can sometimes pause the locking process when the database has changed, though this might have been resolved in recent updates.)</p>
<p><strong>Intelligent Sync Management</strong><br />
KeePass surprised me with its intelligent management of file changes. If a user on my team alters the KeePass file (which is stored to a Dropbox folder we all have access to) while I&#8217;m using the file, it prompts that it can merge the changes with any changes you may have made. Unless both of us happened to be editing the same record, the merge typically works perfectly, ensuring that all of our changes are current.</p>
<p><strong>Our Process</strong><br />
We store our KeePass file on our team&#8217;s Dropbox folder. We have a very strong password applied to that file, which we change frequently. We also require the use of a key file to unlock the database, which is NOT stored in our Dropbox. This file is distributed manually and only on a few systems. We also maintain several different databases, based on what access a user needs. Unfortunately, there isn&#8217;t a way to share a record amongst databases in order to keep it current, so this sort of functionality only goes so far, but if necessary, we&#8217;re able to quickly change all of the passwords we need to in the event of a personnel change or other problem.</p>
<p>Dropbox syncs the file as I described above, ensuring we&#8217;re all working off of the same copy of the file. If we wanted to, we could enforce a read-only rule that would have one member of the team making all password changes and entries, but this wouldn&#8217;t be very efficient for our team, and we trust our team members.</p>
<p><strong>Potential Issues</strong><br />
Unfortunately, KeePass isn&#8217;t built to play terribly kindly with OS X or Linux. KeePass is kept in two development variants: 1.x and 2.x, with 1.x being Windows- and WINE-compatible, but missing some great features, and 2.x only working in Mono, to varying degrees of success (as far as those in our organization were concerned.) A solution to this is <a href="http://www.keepassx.org/">KeePassX</a>, which works natively in OS X/Linux, but which doesn&#8217;t support the kdbx file format used by 2.x. The KeePassX developer is looking to rebuild it to support kdbx, so hopefully we&#8217;ll see that problem reconciled in time, but for now, Mono may be your best bet, if you can get it to cooperate.</p>
<p><strong>Neat Bonuses</strong><br />
KeePass has a pretty great Android app that can work together with the Dropbox app to load your database, even if it requires both the password AND key file. I haven&#8217;t had a chance to use the iOS apps, but apparently they&#8217;re pretty nice as well. I generally use this in read-only mode exclusively, but it&#8217;s convenient nonetheless when you absolutely *need* a password. There&#8217;s also a plugin system that allows for some cool extensibility, and it&#8217;s actively being developed, so you&#8217;ll see updates hit on a regular basis. It&#8217;s also entirely free.</p>
<p>You can easily sort passwords into folders and sub-folders, assign icons to them, search through records, attach other encrypted data to each record, store record histories, and even have it perform a macro of keystrokes when &#8220;auto-typing&#8221; your password in. (This is useful if you need to select a database, for instance, from a dropdown. You can even have it launch a new browser tab, browse to the page in question, and go from there, though this requires a bit of configuration to get working.)</p>
<p><strong>Conclusion<br />
</strong>Overall, we&#8217;ve been very happy with KeePass. We weren&#8217;t willing to take the plunge and use an online, hosted solution to store our passwords, if we could avoid it. Because we control the encryption and access requirements, and because Dropbox is pretty secure in and of itself, I feel comfortable keeping our password database on Dropbox, encrypted with AES-256 bit on a strong password, and backed by a non-Dropboxed encryption key.</p>
<p>This is a somewhat unique configuration for our smaller group, and you&#8217;ll likely need to modify it accordingly, but hopefully this can give you a great starting place for good password management with your team.</p>
<p><a href="http://keepass.info/index.html">KeePass Password Manager</a> (free!)</p>
<p><a href="http://db.tt/iFL8DPs">Dropbox</a> (free!)</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=627&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/cool-stuff/better-group-password-management-with-keepass-dropbox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>8 Simple Tips For Making A Restaurant Web Site That Doesn&#8217;t Suck</title>
		<link>http://www.htmlist.com/design/8-simple-tips-for-making-a-restaurant-web-site-that-doesnt-suck/</link>
		<comments>http://www.htmlist.com/design/8-simple-tips-for-making-a-restaurant-web-site-that-doesnt-suck/#comments</comments>
		<pubDate>Sun, 26 Sep 2010 08:35:18 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[design tips]]></category>
		<category><![CDATA[food service]]></category>
		<category><![CDATA[menus]]></category>
		<category><![CDATA[restaurant sites]]></category>
		<category><![CDATA[restaurants]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=622</guid>
		<description><![CDATA[We list some simple tips for building a great web site for a restaurant.]]></description>
			<content:encoded><![CDATA[<p>Restaurant web sites are an interesting beast. It&#8217;s 2010. By now, nearly every restaurant realizes they need a web site. Unfortunately, a lot of owners still don&#8217;t quite understand what purpose their site serves or how to best serve their potential customers.</p>
<p>I&#8217;ll keep this simple:</p>
<ol>
<li>Your full address, hours, and phone number should appear on EVERY SINGLE PAGE, please. Don&#8217;t make me hunt for this information, since this is what at least 90% of your visitors are hunting for. Jam it into a sidebar or footer, but do NOT make me click a separate link or search like a truffle pig for something so very basic.</li>
<li>Put a map on your contact page. Don&#8217;t just link to it, put the damn map there. This is extraordinarily simple, and <a href="http://maps.google.com/help/maps/getmaps/quick.html">full instructions are here</a>, but suffice to say, enter your address on Google maps, click the Link option in the upper right corner, and copy and paste the embed code that appears. Don&#8217;t make me click through to see the map.</li>
<li>Stop using Flash. Just stop. Resist the urge. It doesn&#8217;t make you edgy. It annoys the hell out of me. And any of your users who are trying to pull your site up on their phones. You can accomplish cool image changing effects in other ways, and if you&#8217;re playing music, that needs to stop too. Save the ambiance for your restaurant. Flash is also exquisitely bad for search engine optimization; people searching for a specific dish or words and phrases that would otherwise appear on your site may not find them if the search engines have trouble grabbing them. They&#8217;ve gotten better at searching Flash, but it&#8217;s still nearly impossible to drop someone accurately to the right spot in your Flash movie, so it just frustrates people.</li>
<li>Make your full menu available. With prices. And incredibly prominently. The 10% of users who already know where you are and when you&#8217;re open are coming to check your menu. If you have several menus, list each of them. If they change often, that&#8217;s fine, but keep it seasonally representative at the very least.</li>
<li>Make your menu available in a manner other than PDF. I know this one is a toughy and it&#8217;s unlikely to be a change anyone adopts in the near future. Restaurant owners are busy people who barely have the time to update the menu in PDF form, which is how they get it printed, to worry about converting it to HTML or making it otherwise available on the site in a way that looks half decent. But doing this the right way is better for search engines, mobile users, and people who know that opening a PDF is a sometimes-Sisyphean ordeal that causes you to curse the gods. Don&#8217;t put us through that. We want to plan our meals or see if you have something we like. Make it easier on us.</li>
<li>Only show fantastic food photos. Pay a photographer to get it right if you must, but do NOT post cell phone pictures from your Blackberry that you took on the patio at 11pm. This reflects poorly on your presentation even if the dish looks fantastic in person, and there&#8217;s no need to give people a specific reason NOT to show up. Also, you need not over-emphasize photos. While fantastic photos can really help push someone the right direction, you don&#8217;t need to overwhelm them. This isn&#8217;t McDonalds. In any event, make sure they&#8217;re great quality photos: well-lit, not overly compressed, and of something appetizing and plated well.</li>
<li>Make sure you list things that set you apart. If you offer dietary considerations for diabetic, gluten-free, kosher, vegetarians, or vegan dieters, mention that. It&#8217;ll help in search engine results, and it&#8217;s invaluable for people who are looking specifically for that information and are unsure if you have anything that works for them. Consider whipping up an online menu that showcases some of those dishes; people in those communities will be extremely appreciative.</li>
<li>Give us a little personality. Clearly state your purpose, your passion, and what you do to deliver and set yourself apart. A simple explanation with a few well-written bits about how much you love making great food for people can get your visitors energized and ready to make a reservation.</li>
</ol>
<p>These are pretty universal, simple to apply tips that can enhance the experience for visitors who need a very specific piece of information typically very quickly: don&#8217;t frustrate us by burying it, forgetting to supply it entirely, or by designing the site so horribly that it&#8217;s nearly closing time when we finally track down your hours.</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=622&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/design/8-simple-tips-for-making-a-restaurant-web-site-that-doesnt-suck/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Twitter Advice for Companies: Engage Intelligently</title>
		<link>http://www.htmlist.com/how-to/twitter-advice-for-companies-engage-intelligently/</link>
		<comments>http://www.htmlist.com/how-to/twitter-advice-for-companies-engage-intelligently/#comments</comments>
		<pubDate>Sun, 27 Dec 2009 17:16:44 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[companies]]></category>
		<category><![CDATA[social media]]></category>
		<category><![CDATA[Social Networking]]></category>
		<category><![CDATA[social presence]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[twitter]]></category>
		<category><![CDATA[twitter advice]]></category>
		<category><![CDATA[twitter for business]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=516</guid>
		<description><![CDATA[Companies are moving to engage their customers left and right over Twitter. Here are a few tips to offer your customers the most bang for the buck.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.htmlist.com/wordpress/wp-content/uploads/2009/12/sp_twitter.jpg"><img class="alignleft size-medium wp-image-517" title="Sarah Palin Twitter" src="http://www.htmlist.com/wordpress/wp-content/uploads/2009/12/sp_twitter-300x162.jpg" alt="sp_twitter" width="300" height="162" /></a>As more and more companies move to engage their customers over Twitter, I thought it might be useful to outline a few guidelines companies should use when tweeting.</p>
<p>Naturally your mileage will vary, but these are tips I&#8217;ve put together based on my experience with companies who are doing Twitter right, and some who haven&#8217;t quite got the hang yet:<br />
<span id="more-516"></span></p>
<ol>
<li><strong>DO: SPELL THINGS CORRECTLY. </strong>Don&#8217;t treat Twitter like you&#8217;re a third-grader sending a text message. If your message is so long that you find yourself having to edit &#8220;see&#8221; to &#8220;c&#8221; or &#8220;you&#8221; to &#8220;u&#8221;, find a way to make it shorter without resorting to sounding like an idiot. (I&#8217;m looking at you, <a href="http://www.twitter.com/sarahpalinusa">@SarahPalinUSA</a>.) Use the emdash (hold alt and press 0151 on the pc keypad) to break up thoughts—without spaces on either side—instead of ellipses, or other &#8220;open set&#8221; punctuation. Breaking messages down into &#8220;leet speak&#8221; or SMS chatter is unprofessional and sloppy. If it absolutely must be said in more than 140 characters, seriously consider a blog.</li>
<li><strong>DO: TWEET SPECIAL OFFERS OCCASIONALLY</strong>. Use Twitter to incentivize your followers to stick around, but don&#8217;t spam them dozens of times throughout the day. Assume that one or two offers a day is a good maximum. (See tip #7.) Consider offering discounts or free products with a &#8220;code word&#8221; like <a href="http://www.twitter.com/sprinkles">Sprinkles Cupcakes</a> does. Nearly every day, they give away a free cupcake to the first 25 or so customers who whisper their coupon phrase that day. This has the wonderful benefit of getting people in to your store, where they&#8217;ll likely make a purchase even if they&#8217;re not one of the 25. There&#8217;s also a good chance that they&#8217;ll buy something else even if they get the free cupcake, and by limiting it to the first few customers, you can contain your costs outright. Even if you&#8217;re not a brick and mortar, special offers can encourage customers to make purchases they had been holding off on but wouldn&#8217;t have otherwise known about. Dell claims to have booked <a href="http://www.pcworld.com/article/184076/dell_proves_that_twitter_can_be_profitable.html">$6.5 million in sales</a> directly through their Twitter presence over the past two years.</li>
<li><strong>DON&#8217;T: BE BORING. </strong>Special offers are great and might be enough to keep followers around, but you can engage your customers on a much deeper level by talking about your product, your business practices, and even offering some single-tweet behind the scene glimpses into how you operate. Restaurants especially can make use of this, and one local eatery called <a title="Liberty Market" href="http://www.twitter.com/libertymarket">Liberty Market</a> does a great job tweeting about new menu items they&#8217;re working on, showing pictures, and discussing special offerings of the day. It keeps your brand on people&#8217;s minds and makes the brand far more personable.</li>
<li><strong>DO: PROACTIVELY ENGAGE CUSTOMERS.</strong> Use Twitter&#8217;s search capacity or any respectable Twitter client to set up a search with your brand or company name in it. For smaller businesses, you&#8217;ll likely see feedback directed to your Twitter account as a mention, but larger brands are going out of their way to engage customers who simply tweet ABOUT them. <a href="http://twitter.com/pizzahut">Pizza Hut</a> is a fantastic example of a corporation that really engages their customers intelligently. They reply back to people simply mentioning Pizza Hut, asking what they had and thanking them for their patronage. They also try to resolve issues, which is my next tip.</li>
<li><strong>DO: RESOLVE ISSUES WITH CUSTOMERS. </strong>Twitter is a valuable tool for companies to identify trends and monitor feedback about their brand. It&#8217;s also a powerful tool for customers to share their dissatisfaction. Because conversations through mentions/replies are public, it&#8217;s in a company&#8217;s best interest to identify negative tweets and attempt to engage the customer and make their problem right. Pizza Hut does this with nearly any negative experience tweet that comes through. You should focus on making things right, but feel free to move things off the &#8220;public&#8221; side of Twitter to resolve the issue.Similarly, I tweeted to <a href="http://www.twitter.com/hpsupport">@hpsupport</a> about a problem my brother had with his HP laptop and they engaged me directly, asking me to send an email to one of their Twitter support staff. They&#8217;ve now set up a call next Monday. This is a level of service that&#8217;s above and beyond what I was expecting from going through normal channels, and you can believe that it&#8217;s in part because the alternative is a vocal, upset customer.</li>
<li><strong>DO: TWEET THROUGHOUT THE DAY. </strong> Twitter is a different medium than an email newsletter. While mail can lose itself in the shuffle, it&#8217;s likely that a customer will at least see the message&#8217;s presence in their inbox even if they simply delete it. With Twitter, there is no such assurance. Depending on your audience, your customers may very likely not see tweets about offers or important news simply because you mentioned them earlier in the day. Most clients only fetch the last hundred or so tweets so a user who has just opened their client will likely miss a tweet from a day ago. If you&#8217;re going to have a Twitter presence, commit. An account with no new updates for three months looks worrisome.</li>
<li><strong>DON&#8217;T: TWEET NONSTOP OR SPAM YOUR USERS. </strong>Keep things to a balanced 7-12 tweets a day. Don&#8217;t repeat yourself over and over, but don&#8217;t count replies (tweets starting with someone else&#8217;s name)  in that number. Encourage users to tweet back by asking questions about what your customers like or want to see more of. Hold mini contests, discuss upcoming events, or talk about your history. But keep things in check and try to spread out your tweets. <a href="http://www.cotweet.com/">CoTweet</a> is a wonderful tool for scheduling tweets to go out so that you don&#8217;t have to be in front of a computer managing your account all day.</li>
<li><strong>DO: FOLLOW COMPETITORS &amp; OTHER LOCALS. </strong>Even though you compete with other local businesses, it&#8217;s vitally important that you follow them and see what they&#8217;re doing on Twitter, but you can also feel free to engage them online and stay friendly out in the open. You should also make a concerted effort to track down local businesses whom you work with and follow their accounts and engage with them. Word of mouth is everything and the people following your favorite businesses are likely to be great potential customers for you as well. Strike up conversations with others and you can bet they&#8217;ll return the favor. When other companies mention you (@reply within a message), it appears in their follower&#8217;s feeds, linking right to your name. A great way to earn free word of mouth is just to have productive conversations with your favorite local fellow businesses.</li>
</ol>
<p>Twitter is a quick growing medium that companies are still feeling their way around within. It&#8217;s really exciting to see companies taking customer feedback over Twitter to heart, engaging users directly, offering great deals, and using Twitter to solve problems. Still, jumping in to social networking can be a bit of a challenge and is something that does require time and effort. If you need more advice or want some help establishing your Twitter or Facebook social media presence, we&#8217;d love for you to <a title="Phoenix, Arizona web development and design" href="http://www.synapsestudios.com/contact">contact us</a>. In the meantime, I&#8217;d love to hear any tips or favorite practices you&#8217;ve seen other companies make use of that I might have left out.</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=516&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/how-to/twitter-advice-for-companies-engage-intelligently/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Anatomy of a Smart Survey: Netflix Email Surveys</title>
		<link>http://www.htmlist.com/design/anatomy-of-a-smart-survey-netflix-email-surveys/</link>
		<comments>http://www.htmlist.com/design/anatomy-of-a-smart-survey-netflix-email-surveys/#comments</comments>
		<pubDate>Mon, 30 Nov 2009 09:40:18 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[customer feedback]]></category>
		<category><![CDATA[feedback]]></category>
		<category><![CDATA[lists]]></category>
		<category><![CDATA[netflix]]></category>
		<category><![CDATA[surveys]]></category>
		<category><![CDATA[usability]]></category>
		<category><![CDATA[user experience]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=489</guid>
		<description><![CDATA[Netflix understands the key to a successful customer satisfaction survey: keeping it simple. We look at how to incorporate some of their best practices in your next survey.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.htmlist.com/wordpress/wp-content/uploads/2009/11/netflix_survey.gif"><img class="size-full wp-image-490 alignleft" title="Netflix Survey Screenshot" src="http://www.htmlist.com/wordpress/wp-content/uploads/2009/11/netflix_survey.gif" alt="netflix_survey" width="300" height="217" /></a><a title="Netflix" href="http://www.netflix.com/">Netflix</a> is a company built entirely around efficiency. When you deal with the volume Netflix does, every penny, every action, every little detail counts immensely. Take their mailer: Over the years, it has evolved from a cardboard-backed affair, to a paper-based piece with a foam insert, to today&#8217;s design: thin, simple paper. (They determined the breakage rates didn&#8217;t decrease enough with the padding to make it cost-effective.)</p>
<p>It&#8217;s no surprise then that they&#8217;d take the time to get surveys right. Netflix (like most companies trying to make a profit) has a need for constant feedback from their customers. They want to know how their distribution system is working, where there may be bottlenecks, and other things like how their new instant streaming service is performing. Instead of producing staid, time-consuming, multi-page affairs, they send an email with a single question.</p>
<p>In my most recent survey, that question read &#8220;How was the picture and audio quality?&#8221; Simple enough. The real stroke of genius lies in how the user is asked to respond: Three links are displayed, each with a different quality option: &#8220;The quality was very good&#8221;, acceptable, or unacceptable. You click the link and your survey response is sent. Done. That&#8217;s all there is to it.</p>
<p>The survey requires exactly one click to respond to. Users aren&#8217;t asked to login, fill out demographic data, attempt to remember details they aren&#8217;t likely to, or even read anything to qualify their answer. They are given three relatively unambiguous options and clicking the link from within the email submits their response.</p>
<p>Since not every company has the luxury of being able to boil their customer feedback loop down into simple multiple choice questions, let&#8217;s look at a few key points almost anyone can replicate:<span id="more-489"></span></p>
<ol>
<li><strong>Keep it simple. </strong>Remember that users value their time, and while they may like to let you know what they think of your company and how you&#8217;re doing, they may simply not have the time. Focus on a few measurements that can be easily procured and ask just a couple of questions. Consider anything else an imposition for the sake of a casual survey.</li>
<li><strong>Don&#8217;t require a login. </strong>If your users have accounts with you, don&#8217;t require them to login to complete their survey. Include a hash tag unique to the individual survey in every call to action link and compile your results from that. Every additional step a user has to complete is another hoop that will encourage them to close their browser and forget about responding. Remember that when you consider adding a confirmation screen, for instance.</li>
<li><strong>Provide a call to action. </strong>Even if you can&#8217;t find a way to boil a survey down into a completely self-contained piece like Netflix does, provide the user with an initial call to action. Have them answer a single question up front, and present the user with an optional means to supply more information based on their response. In the Netflix example, the user might be prompted to explain the issue if they mark the quality as unacceptable.</li>
<li><strong>Require as little data entry as possible. </strong>This goes back to items one and two: every next step or request for additional information is an opportunity to frustrate your user. In order to ensure the highest quality data, don&#8217;t give your users those opportunities to jump ship.</li>
<li><strong>Allow users to opt-out or set email frequencies. </strong>Don&#8217;t abuse users with surveys, or you&#8217;ll find they&#8217;re no longer users. Provide an unsubscribe link that does the work for them so that they can go back to enjoying your service and so that you don&#8217;t frustrate them.</li>
<li><strong>Keep the design simple, too. </strong>More than just the format of the survey itself, consider paring the design down dramatically. If you&#8217;re emailing the survey, the user shouldn&#8217;t have to activate images to make a selection. A logo, a border, and some simple elements that tie your corporate color scheme in are acceptable, but making the entire email HTML-based is yet another barrier for users to hit when they may have otherwise completed your survey.</li>
<li><strong>Provide context.</strong> Users love to know they&#8217;re making a difference. While it may seem obvious, just mentioning that you&#8217;re issuing the survey as a means of proactively enhancing their experience can go a long way. Feel free to let some personality come through, but don&#8217;t forget to keep it simple overall. The less users have to read, the better your response rate will be.</li>
<li><strong>Say &#8220;thank you.&#8221; </strong>This may seem like a no-brainer, but since the user will be directed to a page upon clicking your call to action/survey response link, make sure you thank them and provide them with options to navigate back to your site if they so desire<strong>.</strong></li>
</ol>
<p>Even with these tenets in mind, you may find it difficult to break out of the mold and build surveys based around such narrow data points. Consider it an exercise in analyzing what really makes your customers happy and what makes your business tick. Think a bit outside the box and consider: If you can only ask your customers one question about their experience with you, (a multiple-choice at that!) what would it be? Remember that you can rotate questions around of course, but start there.</p>
<p>Finally, if you&#8217;re reading this and not sure how to implement this sort of survey system on your own website, by all means please <a title="Contact Synapse Studios" href="http://www.synapsestudios.com/contact">contact us</a> over at <a title="Phoenix, Arizona Web Application Development and Custom Software" href="http://www.synapsestudios.com/">Synapse Studios</a>. It&#8217;s what we do!</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=489&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/design/anatomy-of-a-smart-survey-netflix-email-surveys/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Easy Tip: Tame Your Facebook Feed with Facebook Friend Lists</title>
		<link>http://www.htmlist.com/how-to/easy-tip-tame-your-facebook-feed-with-facebook-friend-lists/</link>
		<comments>http://www.htmlist.com/how-to/easy-tip-tame-your-facebook-feed-with-facebook-friend-lists/#comments</comments>
		<pubDate>Wed, 04 Feb 2009 08:58:33 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[bookmarks]]></category>
		<category><![CDATA[bookmarks toolbar]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[feeds]]></category>
		<category><![CDATA[Friend List]]></category>
		<category><![CDATA[Friends]]></category>
		<category><![CDATA[minifeed]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=429</guid>
		<description><![CDATA[Change your Facebook bookmark to default to a feed with the people who matter most to you.]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-full wp-image-431" title="facebook_friend_list_feeds" src="http://www.htmlist.com/wordpress/wp-content/uploads/2009/02/facebook_friend_list_feeds1.gif" alt="facebook_friend_list_feeds" width="520" height="188" /></p>
<p>In my review of <a title="Filttr.com" href="http://www.filttr.com/">Filttr</a>, I mentioned that Facebook features some comprehensive friend sorting and grouping tricks that Twitter sorely lacks. But the feature is only slightly obvious, so I&#8217;m going to show you an equally obvious quick tutorial on the quick way to get a reasonable Facebook feed of People You Actually Care About, and setting <em>that</em> as your home page, to differentiate from People You Met At That Party That One Time or That One Girl (or Guy) You Shouldn&#8217;t Have Hooked Up With Who Keeps Posting Creepy Profile Pictures Of Themselves But Blocking Them Would Only Make Things Worse.</p>
<p>This is really simple: When you first log into Facebook, click the down arrow next to Live Feed. Next to Friend List Feeds, click Edit Feed, click Make New List, name it something cool, and start typing the names of people you really care about. Easy. (You can also manage all of this from the Friends page, from the top nav.)</p>
<p>Now, if you access Facebook via a bookmark, or through the Bookmarks Toolbar, you can click on the same arrow, right click on the Friend Feed, and use that for your new bookmark.</p>
<p>To be fair, this feature has been around since <a href="http://www.techcrunch.com/2008/08/12/facebook-users-get-more-control-over-feeds/">August 2008</a>. Disturbingly, they broke the permalink functionality about two months ago, which drove me absolutely insane because it happened to be about three weeks into having changed my primary bookmark to the Friend List Feed. Facebook Support told me that they knew it was an issue and that they were working to resolve it and it looks as if it&#8217;s finally been restored, so you can now make the first thing you see when you log into Facebook the feed of people you care about. Or your &#8220;Keeping My Enemies Closer&#8221; list. Whatever.</p>
<p>(Bonus: You can also use Friend Lists to send blanket messages to groups of friends. To do this, just start typing the Friend List name when composing a message.)</p>
<div class="zemanta-pixie" style="margin-top: 10px; height: 15px;"><a class="zemanta-pixie-a" title="Zemified by Zemanta" href="http://reblog.zemanta.com/zemified/3e414e79-6db6-43c6-90b6-3ffe016e4dc5/"><img class="zemanta-pixie-img" style="border: medium none; float: right;" src="http://img.zemanta.com/reblog_e.png?x-id=3e414e79-6db6-43c6-90b6-3ffe016e4dc5" alt="Reblog this post [with Zemanta]" /></a></div>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=429&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/how-to/easy-tip-tame-your-facebook-feed-with-facebook-friend-lists/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Project Management Tips from the Developer&#8217;s Point of View</title>
		<link>http://www.htmlist.com/development/project-management-tips-from-the-developers-point-of-view/</link>
		<comments>http://www.htmlist.com/development/project-management-tips-from-the-developers-point-of-view/#comments</comments>
		<pubDate>Wed, 27 Aug 2008 23:48:37 +0000</pubDate>
		<dc:creator>Brandon Ching</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[documentation]]></category>
		<category><![CDATA[framework]]></category>
		<category><![CDATA[management]]></category>
		<category><![CDATA[project management]]></category>
		<category><![CDATA[projects]]></category>
		<category><![CDATA[scrum]]></category>
		<category><![CDATA[software development]]></category>
		<category><![CDATA[task management]]></category>
		<category><![CDATA[time management]]></category>
		<category><![CDATA[waterfall]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=320</guid>
		<description><![CDATA[Brandon discusses some helpful principles of project management, from the developer's point of view.]]></description>
			<content:encoded><![CDATA[<p>Today&#8217;s post is on something a bit different but still very much relevant in the web development world: project management. Now, I&#8217;m not all that old and I haven&#8217;t been a web developer for all that long (about 6 years in total, 3 actually getting paid ;-) but I have had the opportunity of working for a medium-sized media company with a development team of about 25 developers, a small 5-6 person development company (3 developers), and as an independent contractor.</p>
<p>When I began my career at the medium sized company, I initially saw my project managers as a pain in the ass. All I was interested in doing was coding. I had my own ideas of how the project or feature was going to be done and I thought that I could handle deadlines and project requirements better than they could. Was it really necessary to ask me multiple times a day what I was doing and what percentage of the project was still left to be done? PM&#8217;s gave new meaning to the phrase &#8220;avoid like the plague.&#8221; In all honesty, I wondered why in the hell these people were even hired to begin with. I just could not see the role of a project manager as being all that important.</p>
<p><span id="more-320"></span></p>
<p>Of course, after a bit of development work and experience doing projects with and without them, I found myself having moments of&#8230; &#8220;OMFG&#8230;where is my project manager?&#8221; As developers, void of project managers, we often get carried away with the art that is code. We plan for one thing but, weeks post-deadline, end up creating something entirely different. Does it work? Usually. Is it beautiful? Maybe. Is it what was promised to the customer? Well, no.</p>
<p>I&#8217;m not just talking about instances where a simple login feature ballooned into a grand hierarchical authentication scheme. I&#8217;m also talking about those projects, that for some reason or another, we just despise working on and push off completion; sometimes even writing substandard code just to get it over with. And don&#8217;t forget those projects that are just so complex that we&#8217;re not even sure if we are starting at the right place, much less dedicated to a deadline of any sort.</p>
<p>It seems that the problem here is not one of competence—most of us could, if we really tried to, stick within initial specs and scope. To me the problem lies in the fact that without the role of the project manager on the team, we lack the time and task management designed to keep us on track. We are trained in how to solve problems of logic through good coding principals and design. We are artists. Our canvas is digital and we sometimes let our creativity and desire for compounding beauty interfere with the job we were hired to do. We are not trained in restraint; the project manager is, at least in theory.</p>
<p>Depending on your experience, I suppose this next statement may be gospel or blasphemy, but to me, it is gospel all the way. The successful completion of any project hinges upon a solid development methodology based in clearly defined project goals, block specifications, complete use cases, and the division and distribution of task level development. A good project manager will be able to take high level design specs and goals from a product manager or customer contact and break them out into clearly defined and manageable building blocks. Each block can then be broken down into feature/requirement sets which can finally be tasked out to the developer/s for completion. This is the job of the project manager, not the developer. Developers should only be given spec&#8217;d out tasks with detailed use cases and an explanation of <em>exactly </em>what should be done. It is then up to the developer to determine how the task will be done.</p>
<p>Now, this is not to say that developers are not to be involved in planning or design phases of projects; by nature, they have to be. However, design and planning meetings involving developers should be focused on the technical goals of the project or block, not on management and product/customer level concerns. These meetings must be narrow in focus and should have a clearly defined result. For instance, determining the database schema for the project or settling on a development framework. The layer of abstraction here is critical in keeping the project within scope and to prevent developers from expanding on or reducing the project deliverables. Once the meeting objectives have been met, project managers should then be able to chunk and task out the technical specs to the team of developers.</p>
<p>Now, up until a little while ago, I hated the word &#8220;task.&#8221; Every morning I would check my email and see, &#8220;You have been assigned a new task from&#8230;&#8221; after which my head would sink low and I would seriously contemplate my career path yet again. I would constantly wonder why everything had to be a task: a task to change a misspelled word, a task to add 5 pixels of spacing to the end of the page. Wouldn&#8217;t it just be easier to send me an email or IM or for goodness sake, just turn around and tell me? Surely this couldn&#8217;t be the Zen that is programming? However, recent experience has taught me that, by God, we all need tasks just like we all need competent project managers!</p>
<p>Task assignment, and by extension, a good task management system (note that a task/project management system is very different from a strict bug tracking system) is an absolute necessity for project management. Proper task etiquette enabled by a solid and complete project management system serves many purposes. First and foremost to developers, it serves as our grocery list. It tells us EXACTLY what we have to do, when it needs to be done by, and contains a history of the problem or feature (most PM system tasks have comments/histories and file attachment capabilities). From the management side of things, a PM system will track the number of hours developers spend on each task which can then be used for billing or other performance metrics. It also can serve as a yardstick in determining the level of project completion by showing a variety of statistics based on ticket assignment, time used, percentage of tasks complete for a given project, and developer performance.</p>
<p>Not to sound too preachy (or take too much of an aside), but I have come across a number of good techniques gathered from the various project managers and lead developers I have worked with in the past that I would like to share and recommend that people use.</p>
<h3 id="toc-quote-tasks">Quote Tasks</h3>
<p>Make use of quote tasks. It may take a little more time and to some it may seem really useless, but in the end it will serve as a good measure of your time estimation abilities and speak to the thoroughness of your work. The way it works is that for every task you are assigned, unless fixing the problem will take less than 10 min., in the comments section you should list the files and line numbers that you will need to make changes to in addition to a brief one liner explaining the expected change. You then assign the ticket back to your project manager to quickly review. If your time estimate falls within the allowable project time, then you will get the task back and no matter how many days or weeks may pass, you will know immediately what needs to be fixed and where.</p>
<h3 id="toc-notate-completed-tasks">Notate Completed Tasks</h3>
<p>When tasks are complete, you should list each file and line number range that you made modifications to and provide a one or two sentence description of changes (in addition your regular brief outlining the totality of changes). This makes tracking changes easier for those who may follow you and serves as a written history in a developers words of exactly what was done for the task.</p>
<h3 id="toc-the-six-hour-work-day">The Six-Hour Work Day</h3>
<p>One small tip on time management and allocation I learned from my last PM was to only allot 6 hours of estimated work in a day. He said that the remaining 2 hours are spent on bathroom breaks, water cooler conversations, task switching ramp up, nerf fights, etc. At first I thought this was strange. Could bathroom breaks really take up 2 hours of my working day? But as I was tasked on this schedule, it seemed to work out pretty well. While I didn&#8217;t exactly lose 2 hours doing random things, what did happen was that I was rarely under pressure to squeeze out tasks leaving me less stressed and able to produce better quality and more thoroughly tested code and documentation. Funny thing, comparing a &#8220;6 hour&#8221; work day with the regular, &#8220;get as much work done in the 8 hours you are here&#8221; approach, I felt more productive and competent under the 6 hour routine. Give it a try, you may be surprised.</p>
<h3 id="toc-developers-as-project-managers-warning">Developers as Project Managers: Warning</h3>
<p>Developers should never be placed in the role of a project manager; creating and managing their own tasks. However, sometimes there is little choice (little company resources, sole operation, etc). If this is the case, expect that as a developer you will be spending probably 1/4-1/3 of your day planning and managing tasks; <em>not</em> working on them. Be sure your boss knows this if they are not willing or able to task out projects properly to begin with. This is really for your sanity and for the thoroughness that comes with being a competent developer. Now, in the rare case where you as the developer are tasked with actually taking customer specs and being told to simply get it done, placing the entire development life cycle on you or your team&#8217;s shoulders, I strongly suggest that you ask management to hire a project manager. If that is not possible then maybe you should be dusting off that resume because project specing, chunking, and higher level project management duties like those are not your job. There is a good reason developers are not PM&#8217;s and PM&#8217;s are not developers.</p>
<h3 id="toc-the-devils-in-the-details">The Devil&#8217;s in the Details</h3>
<p>Nag, nag, nag. If you get assigned tasks that are too general in scope and you have any questions about exactly what it is that your PM or boss is asking for, send the ticket back and ask for further explanation. It usually only takes a few times doing this for your boss to get the idea of what information you need to get your work done right. Remember, training goes both ways; you learn from your boss as much as your boss learns from you. It&#8217;s better to take the time upfront and get accurate and detailed specs than for you to guess and have to go back and rewrite something down the road.</p>
<p>All that being said, there are a number of development methodologies out there to help you and your team develop software in an efficient and smart manner. Now, as I&#8217;ve made crystal clear, I&#8217;m not a PM so I don&#8217;t claim to be an expert on any development methodology, but I take particular affinity to <a href="http://en.wikipedia.org/wiki/Agile_software_development" target="_blank">Agile</a> development methods like <a href="http://en.wikipedia.org/wiki/SCRUM" target="_blank">Scrum</a>. Any methodology where you as a developer are protected from business processes (changes in specs/customer expectations, etc) external to your core job function is a winner in my book. Avoid the traditional <a href="http://en.wikipedia.org/wiki/Waterfall_model" target="_blank">waterfall</a> and <a href="http://en.wikipedia.org/wiki/Cowboy_coding" target="_blank">cowboy</a> coding approaches as they are highly inflexible and in the former case, plain stupid as a development methodology for any business.</p>
<p>So there! I hope I&#8217;ve been able to give a little personal experience to you developers out there (and you managers) who may be a little too code-centric. Don&#8217;t ignore the management side of your business. It can save your sanity and make you a better developer in the process!</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=320&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/development/project-management-tips-from-the-developers-point-of-view/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>10 Ways to Ensure Your Data is Safe From the Feds</title>
		<link>http://www.htmlist.com/rants/10-ways-to-ensure-your-data-is-safe-from-the-feds/</link>
		<comments>http://www.htmlist.com/rants/10-ways-to-ensure-your-data-is-safe-from-the-feds/#comments</comments>
		<pubDate>Sat, 26 Jul 2008 01:29:02 +0000</pubDate>
		<dc:creator>Brandon Ching</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[Rants]]></category>
		<category><![CDATA[bitlocking]]></category>
		<category><![CDATA[browser cache]]></category>
		<category><![CDATA[cryptography]]></category>
		<category><![CDATA[customs]]></category>
		<category><![CDATA[data encryption]]></category>
		<category><![CDATA[data protection]]></category>
		<category><![CDATA[encryption]]></category>
		<category><![CDATA[feds]]></category>
		<category><![CDATA[forensics]]></category>
		<category><![CDATA[GIAC]]></category>
		<category><![CDATA[rant]]></category>
		<category><![CDATA[us customs]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=217</guid>
		<description><![CDATA[We take a bit of a tongue-in-cheek look at the best ways to ensure your data is safe wherever you go. Just don't blame us if you get tased by the feds.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.htmlist.com/wordpress/wp-content/uploads/2008/07/donttaseshirt.jpg"><img style="padding-right:5px;" title="donttaseshirt" src="http://www.htmlist.com/wordpress/wp-content/uploads/2008/07/donttaseshirt.jpg" alt="" width="150" height="150" align="left" /></a> News that our US Customs agents can stop and look through a person&#8217;s laptop and digital devices when they enter the country happened to hit me very late. Only yesterday did I actually read <a href="http://news.cnet.com/8301-13578_3-9834495-38.html">an article</a> explaining this gross violation of privacy; US citizen or not. While I would love to go off on the legal, constitutional, and ethical shortcomings of a policy such as this, I promised my editors (read: bosses) I would try to provide a bit more of an upside with my rants, instead of just straight ranting.</p>
<p style="0in;">Thus I am here today to offer a few recommendations for those of us that still believe in the right to individual privacy. (And a few that might get you into trouble on your next time at the airport.)</p>
<p><span id="more-217"></span>As a certified <a href="http://www.giac.org/">GIAC</a> Computer Forensic Analyst, I have a bit of experience in the methods used by law enforcement to collect and process digital evidence. Thus, here is a list of 10 things that you can do to keep your data protected when either crossing the Gestapo-controlled borders of our fine country or sitting in your home office with a warm mug of hot chocolate:</p>
<h4 id="toc-1-encryption">1. Encryption</h4>
<p>Yes, this one may seem obvious, but I am constantly amazed at how many people do not encrypt their data or encrypt it in a less-than-ideal manner. There is (currently) no easy or entirely effective way to retrieve data within a well-encrypted (1024-bit key or greater) archive. Despite the fact that most types of encryption today are considered relatively safe against attack, I would still recommend a tiered approach to data encryption:</p>
<ol>
<li>
<p style="0in;">Your first and most broad layer 	of protection should be at the system or hardware level. This type of encryption is implemented by either the operating system or hard disk hardware itself. In general, this type of protection is very good. Most current major OS&#8217;s either include or offer as an enhancement, the ability to encrypt your entire drive. (This is true of OSX and Vista Ultimate) There are also third-party software packages like <a href="http://www.truecrypt.org/">TrueCrypt</a> that offer this ability.</p>
<p>Many hard drive manufacturers now also offer hardware-based encryption of their drives. How&#8217;s this work? Well, prior to any data being read/written, the hard drive I/O stream is passed through a hardware encryption chip. Thus, there is no way for any unencrypted data to be accidentally written to the disk.</p>
<p>However, keep in mind that both of these methods, while easy to implement, have some downfalls: In order for an OS-level encryption scheme to work seamlessly, the encryption key must be readily available for use. Otherwise, the system would constantly ask you for your password for every file you wish modify, add, delete and move. How does the OS get around this? It keeps the encryption key in memory. To try it yourself, do a memory dump and parse it for your entire key&#8230;it will be there. If you can find it, so can the fuzz (usually). (Consider, this is also the method used successfully by hackers trying to break HD-DVD and Blu-Ray encryption.)</p>
<p>As far as hardware encryption is concerned, I don&#8217;t entirely trust it. There are a number of recorded instances where the government has successfully &#8220;requested&#8221; private entities to build in backdoor access to systems it deemed important. Thus, I&#8217;m inclined not to fully trust the claims of the manufacturers. (If your whole-drive encryption scheme was backdoored for the government, would <em>you</em> advertise that a vulnerability existed?) For casual, non-the-feds-have-confiscated-my-shit use, this is a good option. But we&#8217;re trying to <strong>beat</strong> the feds here.</li>
<li>
<p style="0in;">The next layer of protection would be individual file encryption for your most sensitive files. Programs like <a href="http://www.gnupg.org/">GPG</a>, <a href="http://www.pgp.com/">PGP</a>, TrueCrypt and a multitude of others offer solid encryption methods. Most of these programs will also allow you to create encrypted &#8220;drives&#8221; or self-executing archives that contain many files and can be used to fill USB drives or moved around quite easily. Also, your hard disk key and file level key should be different. (In other words, use different passwords and encryption algorithms!)</p>
<p>I have read a number of threads where people recommend file-level passwords to protect their content. Here&#8217;s the story there: These password protection schemes are useless unless there is some form of encryption involved. This means that, in general, PDF, Word, ZIP, and other types of 		password-only protections are a waste of time—cracking tools are easily available to even casual users with a quick Google search. They&#8217;re typically based on two-way encryption schemes and thus, aren&#8217;t secure at all.</li>
</ol>
<h4 id="toc-2-frequent-free-space-drive-wipes">2. Frequent Free Space Drive Wipes</h4>
<p style="0in;">Most encryption packages also include a method to &#8220;wipe&#8221; your drive. This is important since we all know that &#8220;delete&#8221; really 	doesn&#8217;t mean delete. (When you delete a file, the OS just marks that space as &#8220;writable&#8221; and removes the file&#8217;s listing from the file system. It&#8217;s still <strong>highly</strong> recoverable, though.)</p>
<p>A free space wipe forces your hard 	drive to write either a set or random stream of 1&#8242;s or 0&#8242;s to all 	the areas of your drive designated as free space by your OS. (Or basically, over the files you&#8217;ve deleted.) If you are using an encryption software package, you may find that there are all kinds of crazy options for drive wiping including impressive titles like, “NSA level data protection, blah, blah, blah” that wipe your drive 7+ times. It&#8217;s generally a waste of time—a single wipe with random data is typically all you need. But if you want to feel extra safe, go ahead and run a few more passes over it.</p>
<h4 id="toc-3-setting-your-browser-to-automatically-clear-its-cache-cookies-on-close">3. Setting Your Browser To Automatically Clear Its Cache &amp; Cookies on Close</h4>
<p style="0in;">I know this one is a pain in the ass since you end up losing all of your logins and such but it 	makes clearing your internet trail automatic and fast.  It would suck if your friend quickly jumped on your computer only to see all the S&amp;M sites in your history from the other day that you forgot to clear. Unless that&#8217;s your thing. And maybe their thing. And then you guys could, you know, discuss it. As men do.</p>
<p>It&#8217;s a judgment call if this level of protection is worth it for you. At the very least, you need to make sure you follow my next tip and:</p>
<h4 id="toc-4-password-protect-your-screen-saver">4. Password-Protect Your Screen Saver</h4>
<p style="0in;">. This one may be a bit annoying, but it&#8217;s nowhere near as frustrating as clearing your browser cache can be. And it&#8217;s probably the most important thing you can do to protect your data after encrypting your drive. This one&#8217;s simple. Quick instructions follow, <a href="http://www.askdavetaylor.com/change_my_windows_xp_screen_saver_password.html">for XP users</a>, for <a href="http://www.lockergnome.com/windows/2007/03/13/password-protected-screensaver-in-vista/">Vista users</a> and for <a href="http://kb.iu.edu/data/ajqx.html">OSX users</a>.</p>
<p>Also, get in the habit of locking your screen ANYTIME you leave your desk. It may not seem like much, but from a Five-O investigative perspective, this is a serious pain in the ass. 	The reason being, if you encrypted your drive like you should, then the investigator has no choice but to pull the plug on your system since they cannot do a live forensic duplication. However, when they 	later proceed with the duplication after seizing your drive, they will find the drive is encrypted AND they will have lost the 	volatile evidence in memory. Thus, they will get NOTHING!</p>
<p>Don&#8217;t forget to <strong>use strong passwords</strong> or passphrases. Be clever: pick a line in a song you really like and use the first letter of each word. Better if it has a number. And don&#8217;t write your passwords down.</p>
<h4 id="toc-5-always-wipe-the-entire-drive-when-giving-away-a-system-or-drive">5. Always Wipe the Entire Drive When Giving Away a System or Drive</h4>
<p style="0in;">Again, this should be obvious but it bears repeating: formatting does not overwrite data on the drive, it simply erases any reference to the data. The best method to wipe an entire drive is to attach that drive to an existing system and to wipe the entire drive from there. There are many people out there who buy drives or old systems for the sole purpose of analyzing them for the previous owner&#8217;s personal data. We did this as part of my CF training. Fortunately, we didn&#8217;t do anything with the private data, but this represents a huge vector for identity theft. If you&#8217;re simply tossing a hard drive instead of donating it, go the extra mile: Wipe the drive and then drill several holes straight through it.</p>
<h4 id="toc-other-less-savory-data-protection-practices">Other, Less Savory Data Protection Practices&#8230;</h4>
<p style="0in;">All that said, I&#8217;ve gone ahead and brainstormed a few ways to give your friendly customs agent a bit of a hazard at getting to your data. Try these at your own risk:</p>
<ol>
<li>
<p style="0in;">Remove the hard drive and mail it home. When customs tries to start the laptop and it won&#8217;t boot, tell them it&#8217;s idiot proof. (Expect a pistol-whipping or a tasing here.)</p>
</li>
<li>
<p style="0in;">Leave your computer in sleep mode but take a screen shot of your desktop (with incriminating filenames on the desktop) and make that the background of the login screen. See how many mouse clicks and keystrokes it takes them to figure out that their actions aren&#8217;t really doing anything. (Vista doesn&#8217;t display your desktop wallpaper when your system is locked, but there are ways to <a href="http://www.howtogeek.com/howto/windows-vista/customize-your-windows-vista-logon-screen/">customize your login screen</a> for fun as well.)</p>
</li>
<li>
<p style="0in;">Pop the keys off the keyboard and move them around to different positions. (Or just use <a href="http://en.wikipedia.org/wiki/Dvorak_Simplified_Keyboard">Dvorak</a>.) When they ask for your password, give them a random sting and watch as they try to figure it out.</p>
</li>
<li>
<p style="0in;">Mail your real laptop home and/or bring a fake/broken laptop. (If you happen to have one on hand. Clearly, we&#8217;re being a bit tongue-in-cheek here.) Before you leave, epoxy the lid closed and see how long it takes them to get the lid open. When they ask you how to open it, explain that they have to say a Harry Potter spell to open the laptop. (Expect a tasing here, too.)</p>
</li>
<li>
<p style="0in;">When it still doesn&#8217;t open, tell them you left your wand at home. Or that you just use the battery compartment to store your cocaine. Customs agents are renowned for their wonderful sense of humor.</p>
</li>
</ol>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=217&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/rants/10-ways-to-ensure-your-data-is-safe-from-the-feds/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Linux CLI Tutorial Part 1—Some Under-Utilized Bash Tools for the CLI Feeble</title>
		<link>http://www.htmlist.com/how-to/linux-cli-tutorialpart-1-some-under-utilized-bash-tools-for-the-cli-feeble/</link>
		<comments>http://www.htmlist.com/how-to/linux-cli-tutorialpart-1-some-under-utilized-bash-tools-for-the-cli-feeble/#comments</comments>
		<pubDate>Thu, 24 Jul 2008 04:41:07 +0000</pubDate>
		<dc:creator>Brandon Ching</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[cli]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[cut]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[linux tutorial]]></category>
		<category><![CDATA[man]]></category>
		<category><![CDATA[paste]]></category>
		<category><![CDATA[rtfm]]></category>
		<category><![CDATA[sort]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[tr]]></category>
		<category><![CDATA[truncate]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=200</guid>
		<description><![CDATA[Working with the LAMP stack can be a bit confusing if you've found yourself using Windows as your IDE up to this point. We look at some basic CLI commands in Linux with cut, paste and tr, and how to make use of them.]]></description>
			<content:encoded><![CDATA[<p>Today, web developers have a number of platform options to develop on. Some like the familiarity of Windows combined with an IDE like <a href="http://www.eclipse.org/">Eclipse</a> or <a href="http://www.zend.com/">Zend Development Environment</a>, while others (like myself) prefer the more down-and-dirty method of <a href="http://en.wikipedia.org/wiki/Vi">vi</a> on a Linux workstation. Whatever your taste (or skillset) requires, if you develop on the LAMP stack as we do, then eventually you may have to interact with the Linux command line interface (CLI).</p>
<p>In my few years of experience in LAMP development, I have worked with a number of developers with wide-ranging abilities on the CLI. I have oftentimes been surprised that even some of the very best PHP coders can feel a bit uncomfortable when faced with the CLI (hey, sometimes it’s unavoidable). So I thought I might write a series of how-to articles on some of the more useful CLI tools, to help the budding or even advanced PHP developer increase their familiarity with the CLI when they need it. Dive in, after the jump.</p>
<p><span id="more-200"></span></p>
<p>Since I&#8217;m sure most of us have at least a basic understanding of the Linux CLI, I first wanted to cover some of the lesser-known yet incredibly simple Bash tools. In this post, I&#8217;ll be covering the basics of cut, paste, tr, and sort.</p>
<h3 id="toc-cut">Cut</h3>
<p><strong>Cut</strong> is a very useful command that is used to, as you may expect, extract various fields of data on a line-by-line basis. It has only a few arguments, the most useful of which I will cover here. Basic usage looks like this:</p>
<p><code>
<pre class="brush: bash">$ cut –c1-10 file.txt</pre>
<p></code></p>
<p>The &#8220;<code>–c</code>&#8221; option specifies the range of characters on the line to print. The above command prints out the first 10 characters of each line in file.txt. (Note that it&#8217;s not zero-relative, like, say, PHP&#8217;s <a title="PHP substr" href="http://us.php.net/substr">substr</a>.) You can also specify an open ended character range like so:</p>
<p><code>
<pre class="brush: bash">&lt;/code&gt;&lt;code&gt;$ cut –c1,5-, file.txt</pre>
<p></code></p>
<p>This will print the first character, followed by the fifth character continuing through the end of the line, for every line in the file.</p>
<p>The &#8220;<code>-d</code>&#8221; and &#8220;<code>-f</code>&#8221; options specify a delimiter and field number. These are very useful for, say, parsing out log files with a standard delimiter. The default delimiter, when not specified with &#8220;<code>-d</code>&#8221; is the tab character.</p>
<p>The <code>/etc/passwd</code> file is a good example to parse with cut. Let’s say we wanted to get a list of all the users of a system and their home directories:</p>
<p><code>
<pre class="brush: bash">$ cut –d: -f1,6 /etc/passwd</pre>
<p></code></p>
<p>The output would look something like:</p>
<p><code>user1:/home/user1<br />
user2:/home/user2</code></p>
<p>In laymen terms, this might read something like, &#8220;cut out fields 1 and 6, as delimited by a &#8216;:&#8217;, from /etc/passwd.&#8221; Now let&#8217;s look at paste.</p>
<h3 id="toc-paste">Paste</h3>
<p>The <strong>paste</strong> command functions pretty much as you&#8217;d expect it to: as the opposite of the cut command; it pastes multiple lines in two or more files together. Let&#8217;s say we have three files with the following contents:</p>
<p>file1:<br />
<code>Hello</code></p>
<p>file2:<br />
<code>there</code></p>
<p>file3:<br />
<code>everyone</code></p>
<p>If we ran paste on these three files, using a <code>+</code> as a delimiter (again, the default is a tab), we would end up with a single line:</p>
<p><code>
<pre class="brush: bash">$ paste -d+ file1 file2 file3
Hello+there+everyone</pre>
<p></code></p>
<p>Basically, each line in each file is pasted together, 1-&gt;1, 2-&gt;2, etc. Now, if you specify the &#8220;<code>-s</code>&#8221; option and only list one file, then each line of that file will be pasted together to form one giant line:</p>
<p>file1:<br />
<code>hello<br />
there!</code></p>
<p><code>
<pre class="brush: bash">$ paste -d&#039; &#039; -s file1
hello there!</pre>
<p></code></p>
<h3 id="toc-tr">Tr</h3>
<p>The <strong>tr</strong> command stands for translate and basically acts like a substitution filter. Let&#8217;s say I wanted to replace all capital letters in a document to lowercase; you could run this:</p>
<p><code>
<pre class="brush: bash">$ tr &#039;[A-Z]&#039; &#039;[a-z]&#039; &lt; file1</pre>
<p></code></p>
<p>You will notice that tr does not take a file argument. This is because tr is a filter, not a command and thus you will have to pass it text through pipes, redirection, or standard in.</p>
<p>One of the more useful features of tr is that it takes octal values of certain ASCII characters:</p>
<p>Bell = 7<br />
Backspace = 10<br />
Tab = 11<br />
Newline = 12<br />
Linefeed = 12<br />
Formfeed = 14<br />
Carriage return = 15<br />
Escape = 33&lt;</p>
<p>So, if you wanted to replace all spaces with a newline, you&#8217;d run the following:</p>
<p><code>
<pre class="brush: bash">$ tr &#039; &#039; &#039;\12&#039; &lt; file1</pre>
<p></code></p>
<p>tr also has the &#8220;<code>-s</code>&#8221; option which will squeeze out multiple occurrences of the replacing character after the input is translated. So given a file like:</p>
<p>file1:<br />
<code>this</code></p>
<p>is some</p>
<p>text</p>
<p>If you ran:<br />
<code>
<pre class="brush: bash">$ tr -s &#039;\12&#039; &lt; file1
this
is some
text</pre>
<p></code></p>
<p>The above command replaces multiple newlines with only one.</p>
<p>Finally, the &#8220;<code>-d</code>&#8221; option will delete the specified character from the input stream:</p>
<p><code>
<pre class="brush: bash">$ tr -d &#039;\12&#039; &lt; file1
thisis sometext</pre>
<p></code></p>
<h3 id="toc-sort">Sort</h3>
<p>The <strong>sort</strong> command has a number of options available so I&#8217;ll just cover the basics here. The most obvious usage is to simply sort a file alphabetically.</p>
<p>file1:<br />
<code>orange<br />
apple<br />
grape</code></p>
<p><code>
<pre class="brush: bash">$ sort file1
apple
grape
orange</pre>
<p></code></p>
<p>Sort will convert the characters into your system&#8217;s internal encoding, (typically ASCII on Linux boxes) and then order them based on the encoded value.</p>
<p>Here are a few easy to use options:</p>
<p><code>-u</code> = Removes duplicates<br />
<code>-r</code> = Reverses the order<br />
<code>-o</code> = Output file (this is useful if you want to replace the source file, since using a redirect into the input file will obviously not work since it is still being parsed by sort)<br />
<code>-n</code> = Tells sort to order the line arithmetically (used for sorting files containing numbers)</p>
<h3 id="toc-conclusion">Conclusion</h3>
<p>Next time, I will be covering the <strong>sed</strong> and <strong>grep</strong> tools as they are extremely useful, yet a bit more involved than the simple tools I covered today. In the future, you can look forward to topics on process and memory management, a vi primer, using PHP as a CLI scripting tool, and much more. And in the mean time, please feel free to post your helpful hints for getting around CLI or using Linux as a dev environment in general.</p>
<p>And if even these commands have gone over your head, you should probably read through these tutorials first to get the hang of CLI basics:</p>
<p><a href="http://www.tuxfiles.org/linuxhelp/cli.html">Linux Command Line Tutorials</a> [tuXfiles.org]</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=200&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/how-to/linux-cli-tutorialpart-1-some-under-utilized-bash-tools-for-the-cli-feeble/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A Simple mod_rewrite Tutorial: SEO-Friendly, Attractive URLs</title>
		<link>http://www.htmlist.com/how-to/a-simplemod_rewrite-tutorial/</link>
		<comments>http://www.htmlist.com/how-to/a-simplemod_rewrite-tutorial/#comments</comments>
		<pubDate>Wed, 23 Jul 2008 07:32:20 +0000</pubDate>
		<dc:creator>Jeremy Lindblom</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[difficulty-intermediate]]></category>
		<category><![CDATA[intern]]></category>
		<category><![CDATA[mod_rewrite]]></category>
		<category><![CDATA[regex]]></category>
		<category><![CDATA[regular expressions]]></category>
		<category><![CDATA[seo]]></category>
		<category><![CDATA[urls]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=184</guid>
		<description><![CDATA[Take a look at our guide to getting started with mod_rewrite—an Apache module that allows you to use clean and easy-to-read URLs to generate your dynamic pages.]]></description>
			<content:encoded><![CDATA[<p>As an intern here at <a title="Phoenix, Arizona Web Development" href="http://www.synapsestudios.com/">Synapse Studios</a>, I used to be naive about some things. <em>[*Some* things? *Used* to be?—Ed]</em> I&#8217;d visit websites, look at their URLs and wonder about the time and planning they must have taken in creating so many directories.  Take this news article from Yahoo for example: <code>http://news.yahoo.com/s/ap/20080715/ap_on_bi_ge/oil_prices</code></p>
<p>Does news.yahoo.com really have the directory structure reflected by this URL?  Of course not.  That would create an astronomical amount of directories in a website with thousands of index.html files.  (And wouldn&#8217;t make any sense to begin with; that&#8217;s what query strings and dynamic pages are for.) But there&#8217;s a way to create legible, sensical URLs that mirror a directory structure but really include variables to a dynamic page.  It&#8217;s called a rewrite engine.  Through the use of a rewrite engine, we can create URLs that make sense to people AND that are attractive to search engines. Take a look at how, after the jump.</p>
<p><span id="more-184"></span></p>
<p>Apache includes a rewrite engine called <a title="Apache Mod_rewrite" href="http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html">mod_rewrite</a>. Since we use Apache as our web server of choice, we&#8217;ll be covering how to configure mod_rewrite.</p>
<p>Mod_rewrite is an interesting beast. Some call it “magic” and some call it a “nightmare”.  Really, it&#8217;s a bit of a magical nightmare that, when skillfully and practically employed becomes a powerful tool.  It&#8217;s not a cure-all for every problem with URLs, but it&#8217;s great for doing many things.  You can use mod_rewrite to:</p>
<ul>
<li>Prevent hotlinking</li>
<li>Create pretty and SEO friendly URLs, eschewing the use of illegible query strings</li>
<li>Create redirect pages</li>
</ul>
<p>Redirection is handy because you can move pages if need be, maintaining the old URL while serving a page from the new address.  This removes the need for a redirection server-side script, client-side script or meta-refresh and keeps your search engine rankings from taking a hit.</p>
<p>However, in this tutorial I want to focus on how to use mod_rewrite to replace illegible query strings.  This tutorial is not comprehensive, but it should provide you with a place to start from and teach you how to do basic rewrites.</p>
<h3 id="toc-our-goal">Our Goal</h3>
<p>Let&#8217;s say you have written a PHP script that lists the top 10 restaurants of any city in any state.  You are very happy with your excellent script and you have spent several years traveling across the United States on unicycle to personally collect this data.  Let&#8217;s say your website is www.best-food-of-the-usa.com. Well, the URL to look at the best restaurants in Mesa, Arizona, is pretty ugly looking:</p>
<p><code>http://www.best-food-of-the-usa.com/index.php?operation=top&amp;state=arizona&amp;<br />
city=mesa&amp;limit=10</code></p>
<p>Blah!  Let&#8217;s see what we can do with mod_rewrite to make that look nicer, more appealing and comprehensible to the user, and more search engine friendly. (As search engines apply rank based on the file name and path, putting relevant information in the core path instead of the query string can help boost your ranks considerably.)</p>
<h3 id="toc-enable-mod_rewrite">Enable mod_rewrite</h3>
<p>The first step to using mod-rewrite on your website is to make sure it&#8217;s installed and enabled.  If you have a system administrator, they should be able to do this for you.  If you don&#8217;t, you&#8217;ll need access to your <code>httpd.conf</code> and you&#8217;ll want to uncomment the line that reads:</p>
<p><code>#LoadModule rewrite_module modules/mod_rewrite.so</code></p>
<p>by removing the <code>#</code>.  (Or add the line it if it doesn&#8217;t exist.) You&#8217;ll need to restart Apache for this change to take effect.</p>
<h3 id="toc-create-an-htaccess-file">Create an .htaccess File</h3>
<p>Create a plaintext file and add the following two lines:</p>
<p><code>Options +FollowSymLinks<br />
RewriteEngine On</code></p>
<p>These lines ensure that mod_rewrite is enabled and active.  Save this file as .htaccess.  Make sure that you do not accidentally name it .htaccess.txt.  (If you&#8217;re creating the file in notepad, make sure you select &#8220;All Files&#8221; from the file type dropdown when saving it. If you&#8217;re creating the file in vi on the server, you should already know what&#8217;s up, and it won&#8217;t try to add an extension automagically.)  Put this file in the directory with your script.</p>
<h3 id="toc-rewrite-rules-regular-expressions">Rewrite Rules &amp; Regular Expressions</h3>
<p>Now we are ready to start writing some basic rewrite rules.  Each rule follows this form:</p>
<p>RewriteRule PATTERN DESTINATION [FLAGS]</p>
<p>The PATTERN is what we are looking for and the DESTINATION is what we are going to rewrite to. FLAGS are options you can set for each rewrite&#8230; optionally.  FLAGS are beyond the scope of this tutorial and will have to wait for the next.</p>
<p>Here&#8217;s a small example:</p>
<p><code>RewriteRule ^home\.html$ index.html [R,NC,L]</code></p>
<p>This rewrite rule redirects visitors to home.html to the index.html page. Mod_rewrite makes use of <a href="http://en.wikipedia.org/wiki/Regular_Expression">regular expressions</a> (regexes, for short) to parse your PATTERN element. If you&#8217;re not familiar with regex, they&#8217;re extremely powerful expressions that make use of special characters to denote pattern-types to search for, like ranges, white space, numbers and more. They&#8217;re a bit difficult to wrap your head around at first, so let&#8217;s look at this example to start.</p>
<p>The PATTERN portion of the rewrite rule typically begins with a carat, <code>^</code> and ends with a dollar sign, <code>$</code>. This syntax establishes the beginning and end of the pattern to match.  These two symbols are optional, and including or excluding them can have different effects.  If only carat (^) is used at the beginning, our PATTERN must appear at the beginning of the URL.  If only the $ is used, our PATTERN must be at the end of the URL.  If both are used, our PATTERN can appear anywhere inside the URL.  To make our PATTERN exactly what we want, we are going to remove the carat so that the PATTERN is matched only at the end of the URL.  This will be the case in rest of this tutorial.</p>
<p>Next we have the period, <code>(.)</code>. (In case you didn&#8217;t know what symbol I was referring to there&#8230;) The period is used in regular expression syntax to indicate &#8220;any single character.&#8221; Since that&#8217;s not what you mean in the example <code>home.html</code>, you need to tell the parser to ignore it. You do this with a backslash, <code>\</code>, directly in front of EACH character you need to escape. Because your DESTINATION doesn&#8217;t go through a regex parser, you don&#8217;t need to deal with that on the destination side of things.</p>
<p>If you find your PATTERN breaking, you&#8217;re probably going to want to give it a once-over and escape any non-alphanumeric characters with a backslash. Chief among these, <code>^ $ [ ]  ( ) { } ! \ .</code>. (That&#8217;s right—if you want a literal backslash in your PATTERN, you need to escape it&#8230; with a backslash.</p>
<p>Our first rewrite rule example wasn&#8217;t too helpful; it redirected users but didn&#8217;t rewrite a query string.  What we need are rules that can apply to variable incoming requests. Let&#8217;s suppose we take any page and redirect it to index.html.  This is a useful way to create a <a href="http://en.wikipedia.org/wiki/Front_controller">front controller pattern</a>.  We would write the rule like this:</p>
<p><code>RewriteRule (.+)\.html$ index.html</code></p>
<p>You use parentheses to group things in your regular expressions.  In this case we have created a group containing &#8220;<code>.+</code>&#8220;.  The period is interpreted as &#8220;any character&#8221; and the plus means &#8220;1 or more times&#8221;.  So all together, our PATTERN is (any character one or more times).html.  That matches any page with an html extension.  If we wanted to include htm extensions, we would change our rule thusly:</p>
<p><code>RewriteRule (.+)\.(html|htm)$ index.html</code></p>
<p>The pipe character ( | ) is used to represent a logical OR.  That means our pattern can end in &#8220;html&#8221; OR &#8220;htm&#8221;.</p>
<p>Range brackets are also very useful.  Let&#8217;s say we only wanted to accept pages that had alphabetical characters in their URL only.  Then we would write our rule as follows:</p>
<p><code>RewriteRule ([a-zA-Z]+)\.html$ index.html</code></p>
<p>The range is shown by putting values within square brackets.  You can choose specific values like [abc] (only allows a, b, or c) or you can do ranges like [a-g], [0-9] or [n-y]. Now that we&#8217;ve covered some regex basics, we can build a pattern that can accept variables within a &#8220;directory structured&#8221; URL.</p>
<h3 id="toc-pretty-urls">Pretty URLs</h3>
<p>Our example URL from earlier looks like this:</p>
<p><code>http://www.best-food-of-the-usa.com/index.php?operation=top&amp;state=arizona&amp;<br />
city=mesa&amp;limit=10</code></p>
<p>We&#8217;re wanting to convert it to this:</p>
<p><code>http://www.best-food-of-the-usa.com/arizona/mesa/top10.html</code></p>
<p>However, we want to use the same Rewrite Rule for any city and state.  To do this we will use regular expressions, but we will also use variables in our DESTINATION by using the values from the groups in our PATTERN. Whenever we use a group (groups are contained in left and right parentheses) in our PATTERN, the string that gets matched in that group can be accessed by use of a variable in our DESTINATION  .  That way, if our group <code>([a-zA-z]+)</code> matches the string &#8220;arizona&#8221;, we will be able to use that string in our DESTINATION.</p>
<p><code>RewriteRule ([a-zA-z]+)/([a-zA-z]+)/top10\.html$ index.php?operation=top&amp;state=$1&amp;city=$2&amp;limit=10</code></p>
<p>This will rewrite our pretty URL to the URL needed by our script.  You will notice within our DESTINATION that we have <code>state=$1</code> and <code>city=$2</code>.  The $1 and the $2 represent the values from our first and second regular expressions in our patterns, respectively,  and contain whatever strings matched.  in the case of our example URL $1 would contain &#8220;arizona&#8221; and $2 would contain &#8220;mesa&#8221;.</p>
<h3 id="toc-conclusion-other-resources">Conclusion &amp; Other Resources</h3>
<p>We&#8217;ve rewritten our ugly URLs to be able to parse something a good deal more readable. And we learned a little bit about regular expressions along the way. Regex can be a confounding mistress; extremely powerful but extremely confusing, depending on how complex your patterns are.</p>
<p>I highly recommend you take a look at <a href="http://www.addedbytes.com/">Added Bytes&#8217;</a> <a href="http://www.addedbytes.com/apache/mod_rewrite-cheat-sheet/">mod_rewrite Cheat Sheet</a> to get you started and as a handy reference. And their <a href="http://www.addedbytes.com/cheat-sheets/regular-expressions-cheat-sheet/">Regular Expressions Cheat Sheet</a> is great for that side of things.</p>
<p>You can also take a look at Apache&#8217;s documentation on mod_rewrite:<br />
<a title="Apache Mod_rewrite" href="http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html"> Apache Mod_rewrite</a></p>
<p>And a few other guides on getting started:<br />
<a title="A Beginner's Guide" href="http://www.workingwith.me.uk/articles/scripting/mod_rewrite"> Mod_rewrite: A Beginner&#8217;s Guide</a><br />
<a title="URL Rewriting" href="http://www.yourhtmlsource.com/sitemanagement/urlrewriting.html"> URL Rewriting</a><br />
<a title="Easy Mod Rewrite" href="http://www.easymodrewrite.com/"> Easy Mod Rewrite</a></p>
<p>If you&#8217;re getting stuck with regular expressions, post a comment and we&#8217;ll ask the regular expressions bear (that&#8217;s Edgar) to reply.</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=184&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/how-to/a-simplemod_rewrite-tutorial/feed/</wfw:commentRss>
		<slash:comments>21</slash:comments>
		</item>
		<item>
		<title>Doing Twitter Right: Complete Twitter Immersion</title>
		<link>http://www.htmlist.com/cool-stuff/doing-twitter-right-complete-twitter-immersion/</link>
		<comments>http://www.htmlist.com/cool-stuff/doing-twitter-right-complete-twitter-immersion/#comments</comments>
		<pubDate>Fri, 18 Jul 2008 18:24:51 +0000</pubDate>
		<dc:creator>Chris Cardinal</dc:creator>
				<category><![CDATA[Cool Stuff]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[twitter]]></category>
		<category><![CDATA[twitter plugins]]></category>

		<guid isPermaLink="false">http://www.htmlist.com/?p=102</guid>
		<description><![CDATA[We take a look at the quickest way to get going with Twitter and to make it work rather seamlessly with your Facebook and Firefox.]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.htmlist.com/wordpress/wp-content/uploads/2008/07/twitter.png" alt="" title="twitter" width="210" height="49" align="left" style="padding-right: 5px;"/> So I&#8217;ve been staying away from the <a href="http://www.twitter.com/" title="Twitter">Twitter</a> craziness for some time, primarily because Facebook integration was sketchy at best (the <a href="http://apps.facebook.com/twitter/">Twitter app</a> used to add &#8220;is twittering&#8221; to your Facebook status so you&#8217;d look like a total ass) and because none of my friends were on it. But then I watched as the <a href="http://www.intrigo.com/">Intrigo</a> folks commented on <a href="http://www.htmlist.com/rants/collaborative-idiocy-intrigo-and-the-wiki-as-a-company-website-approach/">my post</a> on Twitter, where I could see it and respond back and something appealed to me about the &#8220;open text messaging/IMing&#8221; concept. Allowing others to join in on a conversation is fun and, more importantly, a great way to find interesting people. </p>
<p>After I configured <a href="http://www.twitter.com/chriscardinal">my account</a>, it was time to make Twitter work for me, to the maximum extent allowed by the law. Here&#8217;s what I&#8217;ve done to make my Twitter experience a bit better, after the jump.
<p><span id="more-102"></span></p>
<p><b>Firefox Integration</b><br />
If you&#8217;re running <a href="http://www.getfirefox.com/">Firefox</a> like you should be, then you&#8217;ll want to take a look at TwitterFox and TwitterBar. <a href="https://addons.mozilla.org/en-US/firefox/addon/5081" title="TwitterFox">TwitterFox</a> is a tasty little Add-On that sits in your status bar and offers pop-up updates when your friends tweet. @replies are colored different as are direct messages, and you can of course set your status right from the box. I like this better than some of the sidebar-based add-ons mostly because I hate the sidebar concept in general.</p>
<p>You can have TwitterFox check multiple accounts and configure its update frequency and popup duration. Just what I&#8217;d want from a Twitter app.</p>
<p><a href="https://addons.mozilla.org/en-US/firefox/addon/4664">TwitterBar</a> is an even simpler way to post status updates. Just start typing into the address bar and click the green + instead of the blue arrow. Done and done.</p>
<p><b>Facebook Integration</b><br />
This one&#8217;s simple: Browse on over to the <a href="http://apps.facebook.com/twitter/">Twitter Facebook App</a> and get cracking. This app used to prepend your status with &#8220;is twittering&#8221; much to the chagrin of a good deal of users. Now there&#8217;s something of a schism, and two distinctly boring camps have formed. I&#8217;m in the &#8220;please don&#8217;t verb my FB status&#8221; camp, for what it&#8217;s worth.</p>
<p>An alternative used to be available called TwitterSync which allowed you to customize the prepend verb. Since Twitter <a href="http://www.scripting.com/stories/2008/07/08/whichWayWillTwitterGo.html">deactivated their XMPP service</a> for most API clients, this and many other plugins have stopped working. (That link discusses the possibility of them reactivating the XMPP functionality.)</p>
<p>Finally, you&#8217;ll need to ensure you browse to the privacy options and explicitly allow Twitter to push status updates through to Facebook.</p>
<p><b>Mobile Integration</b><br />
Now you&#8217;ll want to <a href="http://twitter.com/devices">set up your phone</a> to allow you to post Twitter updates. By simply text messaging 40404, you can publish a status update to Twitter and to Facebook. Cool. You can also select if you wish to be text-pinged with direct messages.</p>
<p>For some reason that completely confounds me, however, Twitter does NOT allow you to be SMS-pinged with @replies. Since hardly anyone uses direct messages (relatively speaking), this smacks of obnoxiousness. What&#8217;s worse is that they acknowledge their own stupidity on this matter with the follow FAQ answer: &#8220;Unlike Direct Messages, there is no special setting for receiving @replies only, but if you&#8217;d like to see one, send us a feature request by selecting &#8220;idea.&#8221; Let me just say that <b>if enough users have requested a feature for you to write an FAQ about it, perhaps you should build it instead of suggesting we file it as a feature request</b>!</p>
<p>One Twitter user <a href="http://getsatisfaction.com/twitter/topics/sms_when_i_receive_replies">posts a workaround</a>, essentially relying on the mobile &#8220;track&#8221; feature. Type &#8220;track {yourname}&#8221; and you&#8217;ll get all updates that mention that phrase. This totally sucks if your user name also happens to be, say, a word someone would use in their normal vocabulary. (It also seems to have a significant delay associated with it&#8230;)</p>
<p><b>Other Twitter Stuff</b><br />
There are plenty of other Twitter features and fun times to be had including other mobile applications, desktop- and sidebar-based apps and more. Check out VirtualHosting.com&#8217;s <a href="http://www.virtualhosting.com/blog/2007/the-twitter-toolset-50-guides-hacks-and-scripts/">rather comprehensive breakdown</a> of Twitter applications and plugins and get tweeting!</p>
<img src="http://www.htmlist.com/wordpress/?ak_action=api_record_view&id=102&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.htmlist.com/cool-stuff/doing-twitter-right-complete-twitter-immersion/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

