Howdy. Welcome to our webdesign blog!

Thanks for dropping by! Please make yourself at home by leaving comments and subscribing to the RSS feed to stay updated.

  • Categories:

  • Blogroll

  • Archives:
  • Connect Windows (vista or 7) to a linux share – Ubuntu

    February 25, 2010

    Have you ever thought it would be great to have a linux dropbox to share files from computer to computer in your network? Well, I did and found it was a bit difficult to set up right off the bat!

    Sharing Folders on Ubuntu Linux

    Before you share any folders, you will need to do a little setup on ubuntu. After some digging, I found the following blog that explains this setup.

    http://www.goitexpert.com/general/connect-vista-to-a-linux-share–ubuntu/

    The blog article goes on to say that there are two things that need to be done. First make sure your samba version is 3.0.22 or higher. Second you need to give samba a username and password. This will be the username and password that windows will use to connect to the share.

    1.  
    2. sudo smbpasswd -a username
    3.  

    Once you have samba upgraded and configured a username and password, you can start sharing folders and files. To Share folders or files, you need to right click on the item and go to sharing options. Then enable sharing.

    Connecting to the Share via Windows Vista or Windows 7

    In windows you need to go to your network. If your lucky, it will show up in the list of servers, but you will probably have to plug the local alias or local ip into the address bar.

    1. \\server-name
    2.  

    or
    1.  
    2. \\192.168.1.#
    3.  

    Windows should now bring up a login window. I don’t know if it matters about the host in this login prompt, but I didn’t bother taking chances. I entered my username as

    server-name\username

    And voila, you can now access your linux shared folder. Amazing!

    Share and Enjoy:
    • Print this article!
    • Digg
    • StumbleUpon
    • del.icio.us
    • LinkedIn
    • Facebook
    • Twitter
    • MySpace
    • Reddit
    • Google Bookmarks
    • Live
    • Yahoo! Bookmarks
    • RSS
    • E-mail this story to a friend!

    Debug javascript without alerts through the Firebug console

    February 14, 2010

    If you are a javascript developer at all, most likely you have had to debug your code with an alert box. This can be horribly annoying when trying to detect line numbers or when working with periodical functions. This is where the Firebug console can be super handy

    I have taken my information for this post from David Walsh’s blog (because it is a great ref for mootools, and because his posts are always helpful).

    Getting Started

    First off, you are gonna need firefox and a little plugin called firebug. I personally enjoy the web developer toolbar for firefox as well. Now you should have these up and running.

    To start out, you will need to open firebug by clicking on the little bug icon at the bottom right corner of firefox.

    Now click the arrow next to “console” and click “enable”. You can enable different features of firebug for different domains.

    Lastly, go to your site where you have written some javascript.

    Hello World meet Hello Console

    Now, it’s time to write some basic debug javascript. A list of console commands can be found on David Walsh’s blog, here:

    http://davidwalsh.name/firebug-console-log

    here is a basic “hello world” type of example of the firebug console:

    1. console.log('hello console');
    2.  

    now refresh your page to run that javascript, and say hello to firebug console. Now close your console and refresh the page again, or try to run the page in IE. You get a javascript error, and your browser throws a temper tantrum. Next, I will show you a little fix for this. I want to make a major note that I do NOT condone leaving debug code in your javascript, but the next section will allow you to sniff for firebug and for the console.

    Sniff out firebug and it’s console friend

    As stated on Walsh’s blog, some site get bogged down under firebug because of many ajax requests. Or you might want to just run your site on IE real quick without removing your debug console code. Well, Walsh comes to the rescue again with some awesome snippets found here:

    http://davidwalsh.name/how-to-sniff-firebug-disable

    1. if (! ('console' in window) || !('firebug' in console)) {
    2.  var names = ['log', 'debug', 'info', 'warn', 'error', 'assert', 'dir', 'dirxml',
    3. 'group', 'groupEnd', 'time', 'timeEnd', 'count', 'trace', 'profile', 'profileEnd'];
    4.  window.console = {};
    5. for (var i = 0; i < names.length; ++i) window.console[names[i]] = function() {};
    6. }
    7.  

    Share and Enjoy:
    • Print this article!
    • Digg
    • StumbleUpon
    • del.icio.us
    • LinkedIn
    • Facebook
    • Twitter
    • MySpace
    • Reddit
    • Google Bookmarks
    • Live
    • Yahoo! Bookmarks
    • RSS
    • E-mail this story to a friend!

    HOW TO: Randomize/Shuffle an array in Flash (AS2)

    January 30, 2010

    I was creating a logo scroller in flash when a client of mine asked me if the logo’s could show up in a random order. This lead me to look to see if Actionscript 2.0 has a built in function to randomize an array. Well, I didn’t find a built in funciton, but i found a great blog entry describing how to build you own. The following code snippets come from:

    http://mrsteel.wordpress.com/2007/06/15/randomize-array-shuffle-an-array-in-flash/

    Prototype function and return function code is :

    1. Array.prototype.mixElements = function() {
    2.  var _length:Number = this.length, rn:Number, it:Number, el:Object;
    3.  for (it = 0; it<_length; it++) {
    4.  el = this[it];
    5.  this[it] = this[rn = random(_length)];
    6.  this[rn] = el;
    7.  }
    8. }
    1. function mixArray(array:Array):Array {
    2.  var _length:Number = array.length, mixed:Array = array.slice(), rn:Number, it:Number, el:Object;
    3.  for (it = 0; it<_length; it++) {
    4.  el = mixed[it];
    5.  mixed[it] = mixed[rn = random(_length)];
    6.  mixed[rn] = el;
    7.  }
    8. return mixed;
    9. }
    10.  

    Share and Enjoy:
    • Print this article!
    • Digg
    • StumbleUpon
    • del.icio.us
    • LinkedIn
    • Facebook
    • Twitter
    • MySpace
    • Reddit
    • Google Bookmarks
    • Live
    • Yahoo! Bookmarks
    • RSS
    • E-mail this story to a friend!

    HOW TO: Creating new users in Ubuntu Linux from the command line

    November 24, 2009

    This how to is written because I have had to look this up like 3 times already, and I wanted a central place where I could return and find the info. I found a good tutorial that I will copy for the most part in this post:

    Creating Linux Users Tutorial

    For this tutorial, I am using Ubuntu 8.04

    To create the user account:

    useradd username

    Set a password for this user

    passwd username

    Important Files (I hope to expand on this later on when I dig into them)

    • /etc/passwd – User account information.
    • /etc/shadow – Secure user account information such as password.
    • /etc/group – Group account information.
    • /etc/default/useradd – Default values for account creation.
    • /etc/skel/ – Directory containing default files.
    • /etc/login.defs – Shadow password suite configuration.
    Share and Enjoy:
    • Print this article!
    • Digg
    • StumbleUpon
    • del.icio.us
    • LinkedIn
    • Facebook
    • Twitter
    • MySpace
    • Reddit
    • Google Bookmarks
    • Live
    • Yahoo! Bookmarks
    • RSS
    • E-mail this story to a friend!

    4 Papercraft Fold-up Toy Websites

    June 20, 2009

    Tubbypaws Blog

    Tubbypaws GTA4 papercraft

    Tubbypaws GTA4 papercraft

    Tubbypaws has some really wierd but awesome drawings and papercrafts. I especially like the lolcat paper dolls on the website. This site is sure to kill the color cartridges in your printer. http://tubbypaws.blogspot.com/

    ReadyMech Paperdolls

    Ready Mech Monster Doll

    Ready Mech Monster Doll

    Readymech makes a set of free paperdolls. I got one in a Computer Arts magazine once on much nicer sturdy paper, and found them really fun. http://www.readymech.com/

    Cubecraft

    Cubecraft Dolls
    Cubecraft Dolls

    Cubecraft has a ton of papercraft dolls for making. From Penny Arcade to Xmen, cubecraft has you covered. http://www.cubeecraft.com/

    Creative Closeup 100 Paper Models

    Creative Closeup 100 Paper Models

    Creative Closeup 100 Paper Models

    Creative closeup has a blog entry displaying 100 paper models. Many of them are just plain amazing. Especially the battletech madcat paper model! http://www.creativecloseup.com/100-exceptional-free-paper-models-and-toys

    Share and Enjoy:
    • Print this article!
    • Digg
    • StumbleUpon
    • del.icio.us
    • LinkedIn
    • Facebook
    • Twitter
    • MySpace
    • Reddit
    • Google Bookmarks
    • Live
    • Yahoo! Bookmarks
    • RSS
    • E-mail this story to a friend!