Ubuntu / GRUB2 bootloader on Asus N90s

The system won’t boot with the normal default configuration that GRUB assigns. The APIC or something related causes the system to go to a blank screen and stay there. Manually change these settings at boot time, or permanently change them in /etc/default/grub

GRUB_CMDLINE_LINUX=”nolapic nohz=off”

Posted under Linux, Operating System

This post was written by Content Curator on September 16, 2012

Tags: , , , , , , , , , , , ,

WordPress Goodies

A few tidbits for WordPress I picked up this week working on Psychic Coupons and a couple other sites.

===============================================

This is an oldie but goody, helps a lot: http://codex.wordpress.org/Template_Hierarchy
and the PNG: http://codex.wordpress.org/images/1/18/Template_Hierarchy.png

===============================================

Here’s one from equalmark and banago at http://wordpress.org/support/topic/query-if-on-front-page-home-index :
If you’re on the front page, conditional statements:

<?php if(is_front_page() ) { ?> //do stuff <?php } ?>
— or --
<?php if(is_home() ) { //do stuff } else { //do stuff } ?>

Mvied notes: I’d just like to point out that the is_home() function is true if you’re on the main blog page, and the is_front_page() function can be the same page unless you have a static front page set, then it will only be true on that page.

============================================

Passing variables in the URL, by stvwlf from http://wordpress.org/support/topic/passing-variables-using-the-permalink-structure :

Step 1:
Create and save PHP file in plugins directory:
<?php
/* Plugin Name: Parameter
Plugin URI: http://webopius.com/
Description: A plugin to allow parameters to be passed in the URL and recognized by WordPress
Author: Adam Boyse
Version: 1.0
Author URI: http://www.webopius.com/
*/
add_filter('query_vars', 'parameter_queryvars' );

function parameter_queryvars( $qvars )
{
$qvars[] = ' myvar';
return $qvars;
}
?>
Step 2:
Pass var in URL href:
if (isset($wp_query->query_vars['myvar']))
{
print $wp_query->query_vars['myvar'];
}

=============================================

Find and show related posts by tag: http://wordpress.org/support/topic/variables-through-get_posts-query_posts

=============================================

elseloop offers a simple way to implement a “Post template based on category”: http://wordpress.org/support/topic/post-template-based-on-category-or-tag

=============================================

I just want to pass my thanks to the many talented people who take the time to share their expertise on the WordPress community forum. They are adding value to the world, so, KUDOS to all you geniuses!

Posted under WebDev, WordPress

This post was written by Content Curator on April 10, 2012

Tags: , , , , , , , , , , , , , , , , ,

How to Find Large Files in Ubuntu Linux

If you want to find files above a certain size, or find files between certain sizes, then you may use the +size x and -size x switches to the find command.

For example:

find /etc -size +100k -size -150k

This command will find all files inside the /etc directory that are between 100k and 150k in size.

Source: http://www.unixtutorial.org/2008/03/find-large-files-and-directories/

Posted under Linux

This post was written by Content Curator on May 25, 2011

Tags: , , , , , , , , ,

How To Install Picasa on Ubuntu or Debian

Google makes the really neat program Picasa 3 for managing and editing photo/image collections. Since Microsoft Windows it a travesty and I therefore use Linux as much as possible, I was in need of a better and more stable photo management software to replace the buggy unstable F-Spot program. To my glee I found that Google releases a Debian version suitable for using under Ubuntu’s flavor of Debian Linux. I love you Google. Anyway, it was still a 2-step process, which would frighten most Windows users, but this bit of work in the beginning assures that I am using reputable sources for software that can be installed without visiting a website or downloading anything from a web server, as I would have to do if using Windows. Not to mention that by being forced to the wild web in order to download all applications and software just opens up a computer to problems because the user must decide which software makers to trust, not a good situation for casual users who aren’t in touch enough with the current “scene” to be able to make an educated decision about which company’s software is trustworthy and which are not. Alas, I digress…

To install Picasa on Ubuntu:

  1. Create a backup copy of your file: /etc/apt/sources.list
  2. Edit /etc/apt/sources.list using “sudo” and the editor of your choice e.g. vi, vim, gedit.
  3. Add the following line:
    deb http://dl.google.com/linux/deb/ testing non-free
  4. Save the file.
  5. Update apt-get’s repository list using: sudo apt-get update
  6. Try to install Picasa now: sudo apt-get install picasa
  7. If it installs, then Hooray! You’re done! However, if you get an error like the following, then proceed to the next steps:
    W: GPG error: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 1234567890123456
    W: There is no public key available for the following key IDs:  1234567890123456
  8. The long number will be different for you, and you’ll need it for the next step.
  9. Run the following commands, substituting 1234567890123456 with the number from your error messages:
    gpg –keyserver pgpkeys.mit.edu –recv-key  1234567890123456
    gpg -a –export 1234567890123456 | sudo apt-key add –
  10. Assuming that you get success, and you should as long as there’s no typos, try again to install Picasa directly with Ubuntu apt-get:
    sudo apt-get install picasa
  11. Picasa will download and install, you may be required to verify that process before it proceeds, though.

Check put these for a bit more info, and the source of the steps needed for this process:
[Debian] Apt-get : NO_PUBKEY / GPG error
Howto Install Picasa 3.5 in ubuntu

Google makes the really neat program Picasa 3 for managing and editing photo/image collections. Since Microsoft Windows it a travesty and I therefore use Linux as much as possible, I was in need of a better and more stable photo management software to replace the buggy unstable F-Spot program. To by glee I found that Google releases a Debian version suitable for using under Ubuntu’s flavor of Debian *nix. I love you Google. Anyway, it was still a 2-step process, which would frighten most Windows users, but this bit of work in the beginning assures that I am using reputable sources for software that can be installed without visiting a website or downloading anything from a web server, as I would have to do if using Windows. Not to mention that by being forced to the wild web in order to download all applications and software just opens up a computer to problems because the user must decide which software makers to trust, not a good situation for casual users who aren’t in touch enough with the current “scene” to be able to make an educated decision about which company’s software is trustworthy and which are not. Alas, I digress…  To install Picasa on Ubuntu:     1. Create a backup copy of your file: /etc/apt/sources.list    2. Edit /etc/apt/sources.list using “sudo” and the editor of your choice e.g. vi, vim, gedit.    3. Add the following line:       deb http://dl.google.com/linux/deb/ testing non-free    4. Save the file.    5. Update apt-get’s repository list using: sudo apt-get update    6. Try to install Picasa now: sudo apt-get install picasa    7.        If it installs, then Hooray! You’re done! However, if you get an error like the following, then proceed to the next steps:   The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 010908312D230C5F

Posted under Freeware, Graphic, Linux, Software

How To Create a Multiplayer Online Flash Game

One of our most important clients asked for an assessment of Adobe Flash multiplayer online game development and its viability.

Our researchers took a look at the current landscape of the MMO Flash world, and their findings may be of interest to anyone wanting to know how to create a multiplayer online Flash game. For the moment, though, let’s cut to the chase for those who don’t want to read too far; Making a multiplayer online game, for mass usage, is a huge undertaking with the potential to require significant amounts of money to get up-and-running… i.e. it is not a venture for the weekender or the kid who made one Flash animation and now wants to take on Club Penguin or the likes. If, however, you are a brave and tenacious soul, with a thirst for knowledge and huge challenges, and the ability to follow through on a project that does not pay a penny for years, then you might want to start with deciding on a server technology.

Servers for multiplayer online games using Flash are essentially XML socket servers. This means that it allows the gamer’s interface (i.e. client) to make socket connections, via the Internet network, into the server. You might want to look at ElectroServer 4, or if you know Microsoft C# (c-sharp) try this page: http://playerio.com/documentation/tutorials/building-flash-multiplayer-games-tutorial/

Beyond a server, you’ll need some very solid AcrionScript 3 and Flash animation skills.

If you just want to tinker, or get involved with making games with minimal effort, but still requiring some Flash skills, try spogg.com where you can can get help and documentation for getting started from day 1, and find an atmosphere of encouragement for the beginning multiplayer game developer who is leaning toward Adobe Flash as the medium.

Posted under Uncategorized

How to Make a Backup Script for Shell in Linux

For those who hack a lot of Linux at the command line interface, backing up files such as config files before editing is a good habit to have. IMHO anyway. So to save time, a little script can be written, chmod +x, and placed into /usr/local/bin or some other that users have in their executable shell PATH. I name mine “bu” to make it easy, and it takes one command line argument which is the filename of the file you want to make a backup copy of. It is called by running something like $ bu myfile

Here’s the code. Comments welcome ;) The code creates a timecode based on today’s date and the current time to the second, and appends that to the original filename. The a copy is saved with this new “timestamped” backup filename, right in the same directory. Easy-peasy! 

#!/bin/bash
OLDFILENAME=$1
DATECODE=$(date +%Y%m%d)
TIMECODE=$(date +%H%M%S)
NEWFILENAME="${OLDFILENAME}_backup${DATECODE}-$TIMECODE"
cp $OLDFILENAME $NEWFILENAME
SUCCESS=$?
if [ $SUCCESS -eq 0 ];then
 echo "OK! Copied \"$OLDFILENAME\" to \"$NEWFILENAME\""
else
 echo "FAIL! You'll need to try again!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
fi

Posted under Linux

How To Make a Shiny Rounded Button in Adobe Illustrator

Using Adobe Illustrator CS4 (this procedure may also apply to CS3 and earlier versions, please let me know if it does) you can make a neat little object that looks like it is curved, rounded, and shiny, with a light shine highlight and edge darkening effect to get the full depth.

  1. Start with an image layer, containing the image that will be the skin of the object (which is in our case a round convex button).
  2. Put a new layer under it.
  3. On the new layer create a circle (Ellipse (L) tool and hold Shift to force circular, hold Alt to anchor center point of ellipse while manipulating the size) that encompasses the part of the image that whall be visible on the final “button” to be created.
  4. Create a radial gradient in the circle. Make it lighter in the center.
  5. Create a new layer between the image layer and the circle layer.
  6. Create another circle on this layer, a bit smaller than the last one, and shifted down a bit so it almost touches on the lower boundary of the circles.
  7. On the same layer create an ellipse that is larger than the circle, but leaves a crescent at the top of the button, for the shine.
  8. Using the layers box, and holding Shift, select both these layers. Then click Pathfinder > Subtract From Shape. This trims out all but the crescent.  (If it does the opposite, Undo (Ctrl-Z) back and reverse the order stacking order of the circle and ellipse on this layer, and try this step again.)
  9. Create a new layer between the image layer and the original circle layer.
  10. On this layer create a rectangle that covers the entire crescent.
  11. In the rectangle, create a white-down-to-black gradient (at -90 deg.) using the standard black and white color pair.
  12. Using the layers box again, select both the rectangle and crescent layers.
  13. On the Transparency panel dropdown (located in the right-corner of the panel) menu selet Make Opacity Mask.
  14. Select the original circle and copy it.
  15. Select the image layer, and paste the circle using Ctrl-F.
  16. Select the pasted circle. Remove the fill and stroke from it.
  17. Select the entire image layer (which selects all sublayers too) and do Ctrl-7 to create a clipping mask. Now your button looks round.
  18. Create a new layer above the image layer, but under the shine layer.
  19. Paste the circle again into this new layer.
  20. Convert the fill to a B&W gradient.
  21. On the gradient, move the center nugget toward the black as far as it will go. This creates a domed shadow effect.
  22. In the Transparency panel, select Mode of Multiply, then select Opacity of 20%.

Viola! Now you have a round  button that looks roundy and shiny.  Rotate the crescent layer to change the direction of light in the shine.

Great Adobe Illustrator tutorial I got this metod… thank you Veerle!

Posted under Graphic, Uncategorized, WebDev

Stats on Browsers, Operating Systems, used in browsers

I found some nice information on which browsers are being used, which resolutions and operating systems are running them, what desktop resolutions they have, etc. Very nice. See how fast Vista is losing usership…

Info courtesy W3Schools

Posted under Browsers, Network, Operating System, WebDev

This post was written by Content Curator on February 2, 2010

Tags: , , , , , , , , , , ,

How to make Windows “forget” network share login

Sometimes in testing network settings and authentication ( for instance when setting up a Samba server and users on a CentOS, Ubuntu, or Feroda Linux system) I often find it useful to force my Windows PC client to “forget” the login username and password that it has on record, for the current session, so that I may login again with another username/password combo. Easily accomplished, this Windows trick works on all modern Microsoft operating systems.

The situation: You need to login again to a network share on a Windows file server, or a Linux server,  without rebooting the client computer.

The fix: Disconnect from the shares using the NET command.

  1. Open a command prompt. (My favorite way is: Win-R, type cmd, press Enter)
  2. Type NET USE * /DELETE
  3. It will prompt you for verification, type Y and Enter.

That’s it! Enjoy, and may your login be forgotten!

Courtesy, Microsoft: http://support.microsoft.com/kb/308582

Posted under Microsoft, Network, Software, Windows

WordPress Template Start

Start the PHP file with this:

<?php
/*
Template Name: Snarfer
*/
?>

Posted under WebDev, WordPress

This post was written by Content Curator on December 8, 2009

Tags: , , , , , , , , , ,