Category: Articles

Articles on various topics

  • Rounded Corners Part 2 – No images

    For this ‘tutorial’ i decided to simply link to a nifty page with instruction on creating a box with rounded corners without using images.

    But how then ? Simply by using CSS and javascript. I remember i used this method on my simple website back in the dawn of time and it worked wonders. Since then the method from this site has been redone not once, but twice!

    So head on over to Nifty Corners Cube by Alessandro Fulciniti and find a new method to produce those lovely rounded corners.

  • Rounded Corners – Solution 1

    Rounded corners on websites and in webdesign are fairly popular. I think that the move from traditional square and technical design to a more organic design is part of the popular trend now a days. A device (or website) that breaks the expected pattern forces us to make new associations with the device. iPods are a great example i think were curved surfaces and smooth design is important but somehow appeals more to most people.

    Regardless of the reason of rounded corners and curves, they are popular but can be a pain to make. Though it has gotten increasingly easier to create and the next CSS3 even provides support for easily creating rounded corners 🙂

    Here is method number 1 for making rounded corners, and in the following posts i will be providing several other ways of making this effect.

    Making corners in Photoshop

    First off we need to make the four corners in a graphics editor such as Photoshop. Which editor you use is of no consequence, but the end result should be 4 images, one for each corner.

    First create a new image about 50 x 50 pixels. Size depends on the curve you want. 1
    Then make a circle selection on the whole image and fill with your foreground color. 2
    Using the ‘guides’ in photoshop slice the image into 4 seperate corners. 3
    Finally save each corner to its own file. ltoprtop
    lbottomrbottom

    Note that you can create the corners in several ways and this is just a simple way to do it. How you get your corner graphics does not affect the rest of the tutorial.

    Now that we have our corner graphics we can create a simple html table that includes the graphics and places them were we need it 🙂

    HTML Template with rounded corner graphics

    What we need here is a simple 3 x 3 table, with corner graphics in each corner cell, and leaving the middle cell for content. We can also insert a title for the rounded corner box in the first row, second cell (between the corners).

    Here is sample html that does exactly this:

    <html>
        <head>
            <title>Rounded Corners Solution 1</title>
        </head>
        <body bgcolor="#47444f">
            <table width="200" border="0" cellspacing="0" cellpadding="0" bgcolor="#6a6af2">
                <tr>
                    <td width="25"><img src="ltop.jpg" width="25" height="25"></td>
                    <td><!-- Insert optional headline here --></td>
                    <td width="25"><img src="rtop.jpg" width="25" height="25"></td>
                </tr>
                <tr>
                    <td></td>
                    <td>
                    Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Donec odio.
                    Quisque volutpat mattis eros. Nullam malesuada erat ut turpis.
                    Suspendisse urna nibh, viverra non, semper suscipit, posuere a, pede.
                    </td>
                    <td></td>
                </tr>
                <tr>
                    <td width="25"><img src="lbottom.jpg" width="25" height="25"></td>
                    <td></td>
                    <td width="25"><img src="rbottom.jpg" width="25" height="25"></td>
                </tr>
            </table>
        </body>
    </html>

    Rendered result looks like this:

    final

    Example files to download:

    [download#11#image]

  • Cold remedies

    Yesterday evening i felt the onset of a small cold. Sneezing, bit runny nose and generally a bit more tired than usual. As pr usual i made some hot tea to drink, and made sure to stay warm. But though the night it got worse in the manner i could not fall a sleep. Luckily the worst was handled during the night of torture, but i decided to make a quick collection article about common cold remedies that could prove usefull.

    Exercise

    This one is my own. I had a set goal of running my daily route this morning to get an early start. Even though i was still fighting my cold and mostly felt like staying under the covers i pushed myself into some running clothes, put on an extra shirt and hooked up the iPod (and my Nike+). Out the door!

    After the run i felt great, and didnt notice my cold that much except the runny nose. Really helped me to feel energized. So some exercise is at least not bad. Also exercising regularly helps prevent getting sick according to all i have read.

    Vitamin C

    Vitamin C is important, and helps combat the cold. Get an extra dose if you start getting cold symptons. Make sure to not only take pills, but actually get the vitamins naturally. Orange Juice should give you a good healthy dose.

    Hot Shower/Bath

    Taking a hot shower, or bath, will help relieve the symptoms. The steam helps clear up the airways and thin out mucus. Also while you are getting refreshed try getting your airway as clear as possible by blowing your nose thouroughly. A common way to relieve symptons is also to hold your head over a warm bowl of water with a tower over your head to simulate a small steam cabin.

    Stay well hydrated

    Drink lots of fluids. I personally prefer to drink warm fluids like tea when i have a cold. Mainly because the varm liquid helps relieve a soar throat. Also its simply cozy to cudde up on the sofa, with a blanket, a movie and a nice hot cup of tea! But in general stay extre well hydrated when fighting a cold.

    Get some sleep!

    Relax and get some sleep. Your body needs the energi to combat the cold infection. So one of the easiest ways to get over a cold fast is to cuddle up under a warm blanket/cover and sleep it out! This might contradict advice number one about excersise. But 10 minutes out running getting your system going isnt alot, but suffecient to both get your body going out of the groggy state associated with illness, but also provies you with a nice mental note that you acheived something despite of the illness.  Reward ourself with a day relaxing afterwards 🙂

    All the above mentioned remedies and tips are from various articles i have found and read. A cold consists of a strain of the rhino virus. There are alot of different strains and your body will get imune to a certain strain after you have fought it off.  Normally this takes 2-7 days to do and medical attention should not be needed. Nasal sprays could help in some cases though.

    Stay healthy!

  • Get Tortoise SVN to remove files from control

    Everybody who has been programming on any large scale, or decent sized project involving several people will be at least familiar with revision control systems such as SVN and CVS.

    One of the most popular systems at this time is Subversion (SVN), and if you are using Windows the Tortoise SVN client will most likely be your svn client of choice.

    However a little know feature is the extended context menu for tortoise. Most evident if you need to remove a file from revision control but keep the file locally on your computer. Normally if you use svn delete the file will be marked for deletion, and upon next commit the file will be removed from the reposiroty AND your local machine.

    Luckily there is a quick little trick to simply remove it from revision control but still keep your local copy. If you press and hold shift while right clicking the file(s)/directory(s) a new command under the TortoiseSVN menu is available called “Delete (Keep local)”.

    This marks your selection to be removed from the repository upon next commit, but retains your local copy. This is especially usefull for files that should not have been added in the first place, but where you still need a copy of the file locally e.g. for building a project.

    To sum up you can extend the capabilities of TortoiseSVN using your shift button! Great little tip! 😀

    Extended SVN menu
    Extended menu

    source:
    http://tortoisesvn.net/node/347

  • My favorite Firefox Extensions

    Here is a list of my currently installed, and most beloved, Firefox extensions. Not all of them are currently out-of-the-box compatible with Firefox 3.0 RC but using the Nightly Tester Tools i can override the compatiblity check, and install them anyway. To my knowledge all of the extensions are working perfectly with Firefox 3.

    Hope you can use some of them and let me know if you have trouble with the links, or getting them running.

  • Restoring Dual Boot funtionality

    Okay i had to format my windows partition on the laptop. No big deal.. just pop in the old windows disc, and do a fresh install (after proper backup of course :p) to the correct partition.

    However i like to use my laptop for Ubuntu also, and thus have dual boot. But windows insists on having control over the whole MBR. Hmm so this install lost me my dual boot functionality. Technically all i lost was the GRUB install that allowed me to boot from Ubuntu’s partitions.

    Normally i would do a complete reinstall of the whole machine, taking me about a whole day considering all the programs i use, and backups to restore. However i didnt feel like this grand gesture, and was pressed for time.

    A quick search gave me the quick fix for restoring dual boot functionality thus saving me some time. So here is the solution to re-install GRUB after installing Windows or in some other messing up your MBR

    1. Boot into Ubuntu using the Live CD. I used Ubuntu 8.04 currently.
    2. Open a terminal. Applications -> Accessories -> Terminal
    3. In the terminal type the follwing steps:
    4. sudo grub
    5. This should result in a GRUB Prompt with grub>
    6. find /boot/grub/stage1
    7. Remember this information
    8. root (hd0,4)
    9. setup (hd0)
    10. And you are done!

    The above is a simple rewrite of the instructions found on the official Ubuntu help.

    After following the steps you restart and everything should be working normally again 😀

    source:
    Recovering Ubuntu after installing Windows

  • Ubuntu 8.04 First Look

    Okay I immediately downloaded and backed my Ubuntu partition up on Dustpuppy (my loving laptop). Takes a while to make the backup, but i was exited through the whole process to get a clean, new, fresh and hopefully faster Ubuntu install.

    Gparted

    First off I resized my NTFS partition to be a bit bigger. Been using my windows partition heavily for Photoshop and development (side effect of being away from home alot due to heavy university load). The whole process of deleting the old Ubuntu partitions, resizing the NTFS leaving me with about 70 GB free unpartitioned space went like a breeze with Gparted from the live cd.

    Install

    The installation went easy as ever. No problems, easy to install and extremely fast. My backup took way longer than the install did. After install i was greeted by the Grub bootloader and without a hitch could choose both Windows XP and my Ubuntu 8.04 install. A short bootload later and the brown welcome screen greets me.

    First impressions

    I love it! Its running smoothly, 3d was easy to install… basically everything just works! I immediately fired up Synaptic and started typing in my commonly used applications. Here i hit my first snag.. overload on the repositories. A download speed of about 20kb/sec wasn’t that fine when i had a ton of stuff to download. But a pleasant surprise was in store as i under the “repositories” dialog for Synaptic could select “other” for the server i wanted to use. I expected to be greeted with a dialog asking for a specific server URL, but was extremely pleasantly surprised when i see a precompiled list of servers. Further more a button allows me to quickly test all servers to find the fastest one. I select that fastest and a minute later im flying the downloads at 1 Mb/sec !

    Screenshot-Software Sources

    Screenshot-Choose a Download Server

    Screenshot-software-properties-gtk

    No Automatix

    I was sad to find that Automatix (homepage) was no longer in development. apparently some of the key developers were busy with normal life and at the same time got hired by the company behind a new distro. So no more automatix for now.

    However this was easily fixed as most of the packages i used from Automatix were available through Medibuntu.

    Conclusion

    I like it 😉 Fast, more stable and so far a lot of small improvements that i really like. Especially love the whole world clock applet, with weather forecast included.

    Links

  • Just say No-To-All !

    When copying files in windows you are normally given 3 options when there is a name conflict. Namely if you want to replace “Yes“, “Yes to All” and “No“.

    no-to-all-windows-thumb

    Thus if you are copying a large amount of files you will be forced to select “No” for each unless you want to replace it with the one being copied. Where is the “No to All” Button Microsoft ?

    However there is a hidden “No to All” option included. Just press SHIFT when clicking “No” and you will only be asked once about the replacement strategy. Very useful for copying larger amount of files were it is simply not fun to click “No” 1000 times :p

    Source: online-tech-tips.com

  • Windows Live Writer

    Okay so one of my mates introduced me to Windows Live Writer. Normally I prefer open source software but lately I have noticed an increasing tendency to use proprietary software that is freely available.

    Lately I have also been using my Windows install increasingly as I have been coding XNA and C# and simply love coding in Visual Studio. I found that for day to day tasks my Linux install does most things better than Windows. Small stuff like multiple desktops makes my day easier as I use alot of multitasking.

    However heavy specific tasks such as Painting (Photoshop), programming (Visual Studio) and gaming in general. I also use windows only applications for my random html coding’s (I prefer an IDE above pure text editors).

    So why not give Windows Live Writer a shot. Also it provides me with the option of inserting nicely formatted code into my posts. I have been searching for a code insertion feature for WordPress for a while, but nothing works the way it should or simply does not work at all :s

    So for a while I will be testing out Live Writer to post on the blog. Hopefully it will make my postings easier for me, more frequent and nicely formatted as usual!

    By the way; I’m Awesome! :p

    Example code:

       1: namespace HelloWorld2
       2: {
       3:     static class Program
       4:     {
       5:         /// <summary>
       6:         /// The main entry point for the application.
       7:         /// </summary>
       8:         [STAThread]
       9:         static void Main()
      10:         {
      11:             Application.EnableVisualStyles();
      12:             Application.SetCompatibleTextRenderingDefault(false);
      13:             Application.Run(new Form1());
      14:         }
      15:     }
      16: }

     

    Links:

  • NextGEN Gallery for WordPress

    Today I discovered an amazing gallery plugin for WordPress. Simply amazing. It is simple, does everything i need and does it with flair! NextGEN Gallery.

    Features:

    • Sortable Albums : Create your own sets of images
    • Upload a Zip-File with pictures : Upload pictures in a zip-file (Not in Safe-mode)
    • Watermark function : You can add a watermark image or text
    • JavaScript Effect : Use any available popular image effect : Thickbox, Lightbox or Highslide
    • Multiple CSS Stylesheet : Use a nice shadow effect for your thumbnails with your own CSS file
    • Slideshow : Full integrated flash slideshow
    • TinyMCE : Button integration for easy adding the gallery tags
    • Sidebar Widget : Show a slideshow, random or recent picture at your sidebar
    • Language support : Translated in more than 15 languages
    • Upload tab integration : You have access to all pictures via the upload tab
    • Tag support for images : Append related images to your post
    • Meta data support : Import EXIF, IPTC or XMP meta data
    • Sort images feature

    Installation:

    1. Upload the files to /wp-content/plugins/nextgen-gallery/
    2. Go to the web page JW Image rotator and download the JW Image Rotator and unpack the conent
    3. Upload the file imagerotator.swf to the /wp-content/plugins/nextgen-gallery/ folder
    4. Activate the plugin
    5. Create a /wp-content/gallery/ folder and CHMOD to 777 or 775
    6. Add a gallery and upload some images (the main gallery folder must have write permission, thus the 775 or 777 chmod)
    7. Go to your post/page and use the gallery quickbutton to add content

    Comments:

    Personally i love this plugin. Easy install. Works right away with options to upload images from zip files as well as single uploads. Meta tags, sorting thumbnail generation. Fluid transistions and lightbox showing.
    I particularly love the slidewhow transistion effects. So if you need even a simple gallery on your website try out NextGEN Gallery!

    Links:

    NextGEN Gallery WordPress Plugin

    JW Image rotator (needed download)