For you Java developer who wants to develop iPad/iPod Touch/iPhone apps, you can read Objective-C for Java Developer slide. You can read it from Slideshare, based on Bob Mc Cune Works.
Happy reading.. Happy coding..
This entry was written by gandaadmin, posted on February 22, 2011 at 1:13 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
I had write this small program, a few months ago. Here I wanna share mine with you.
function getWeather()
{
$requestAddress = "http://www.google.com/ig/api?weather=Jakarta";
$xml_str = file_get_contents($requestAddress,0);
// Parses XML
$xml = new SimplexmlElement($xml_str);
echo "Suhu Jakarta pada saat ini adalah : ";
foreach($xml->weather as $item)
{
foreach($item->current_conditions as $temp)
{
echo $temp->temp_c['data'];
}
}
echo " °C (derajat celcius).";
}
getWeather();
Change the Jakarta with your preferred city in this URL["http://www.google.com/ig/api?weather=Jakarta"]. For example, http://www.google.com/ig/api?weather=Medan or view-source:http://www.google.com/ig/api?weather=Bandung.
The more complex feature can be read from Gilang Chandrasa’s blog about Showing the Weather using PHP and Google Weather API.
This entry was written by gandaadmin, posted on February 19, 2011 at 3:10 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
Here I put some Java reading resource that would be helpfull for Java developer or who have any interest in Java programming languange.
This entry was written by gandaadmin, posted on February 17, 2011 at 3:00 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
It has been more than a week I continued my study in Universitas Indonesia. It was a tough and hard to do. After working since 09:00AM to 17:00PM, I have get my head back in the class to improve my skills at IT area.
What I really like is, when the lecturer not present at the day the class be. It give me more time to take power nap, rest as much as I can. LOL
What makes my headache gotten horrible is I will teach someday and also during my work time. For now I have prepared four(4) modules consist of three(3) PHP modules, and one(1) Drupal module. My head will blow instantly if I have to teach CodeIgniter, Java and Android at the same time.
My power is limited I need to take some rest when any “free” day is available, never working.
Its gonna be a hardest time ever..
This entry was written by gandaadmin, posted on February 14, 2011 at 10:55 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
Fad after come home from college, too kill my time before go to bed, I developed this small tools, enable me to encode-decode from text to binary, octal, hexadecimal, base64 … and vice versa. It took almost one hour to develop this small tools accompanied by my turtles and PHP Manual.
Features:
- Text,
- Binary,
- Octal,
- Hexadecimal,
- Decimal/Char,
- Base64,
- Digest including MD4, MD5, SHA1-SHA512, Checksum, Ripemdl-160
Note: This tools for educational / fun only. If you have criticisms or suggestions, please drop it to ganda.[mylastname]@gmail.com
This entry was written by gandaadmin, posted on February 8, 2011 at 10:31 am, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.

Wall-E. My precious action figure.
This entry was written by gandaadmin, posted on February 1, 2011 at 10:05 am, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
For months I’ve switched from Windows to Ubuntu Linux. I enjoy a lot of coding stuff on Linux, enables me to gain more knowledge at open source.
Recently I have begun digging to SpringFramework, Hibernate, Java Enterprise, and Tomcat Application server. But for the products that in development by my company, Tomcat App Server is not enough. Need a better Java EE application server and we decide to use JBoss application server.
Things not always happen smoothly. No JBoss available on Ubuntu repositories. So I have to install it manually. I have it done I’ll write it down here for free.
Ubuntu version I used in this case is Ubuntu Maveric Meerkat (10.10)
Step 1: Install Sun Java SDK
sudo apt-get install sun-java5-jdk
If you want to install Java version 6, here is the command.
sudo apt-get install sun-java6-jdk
For my case, I am using Java 6.
Step 2: Download JBoss
Go to JBoss download page and get the latest stable version of JBoss. I was using JBoss 4.2.2.GA)
Step 3: Install unzip
sudo apt-get install unzip
Step 4: JBoss Installation
Move the JBoss file to any folder you desired. I was put it to my /home/ganda/. To make a future upgrade of JBoss a little easier, create a symlink to JBoss directory. When you decide to upgrade your JBoss server, you only need to modify the symlink pointing to your new JBoss version.
sudo mv jboss-4.2.2.GA.zip /home/<your-username>/jboss-4.2.2.GA.zip
cd /home/<your-username>/
unzip jboss-4.2.2.GA.zip
ln -s jboss-4.2.2.GA jboss
Step 4: Install JBoss as daemon
Copy the JBoss red hat init script to init.d directory and rename it.
sudo cp /home/jboss/jboss/bin/jboss_init_redhat.sh /etc/init.d/jboss
Change the script that has copied to init.d directory. Edit some variables for JBoss that need to be set correct.
#define where jboss is - this is the directory containing directories log, bin, conf etc
JBOSS_HOME=${JBOSS_HOME:-"/home/ganda/jboss"}
#define the user under which jboss will run, or use 'RUNASIS' to run as the current user
JBOSS_USER=${JBOSS_USER:-"ganda"}
#make sure java is in your path
JAVAPTH=${JAVAPTH:-"/usr/lib/jvm/java-6-sun"}
#configuration to use, usually one of 'minimal', 'default', 'all'
JBOSS_CONF=${JBOSS_CONF:-"default"}
#the host where jboss should answer. o.o.o.o means answer all calls. set this to yourhost.com
JBOSS_HOST=${JBOSS_HOST:-"0.0.0.0"}
# Uncomment this line to store the console output, otherwise it's sent to /dev/null
# JBOSS_CONSOLE=${JBOSS_CONSOLE:+"$JBOSS_HOME/server/$JBOSS_CONF/log/console.log"}
Save the file.
Step 5: Install the init script
sudo chown root:root /etc/init.d/jboss
sudo chmod ug+x /etc/init.d/jboss
sudo update-rc.d jboss defaults
Start the JBoss server.
sudo /etc/init.d/jboss start
Point your browser to http://localhost:8080/. You should see a JBoss default page.
Reference: Installing JBoss Server on Ubuntu: Source Ubuntu Forums.
This entry was written by gandaadmin, posted on January 31, 2011 at 10:50 am, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
I am a big fan of this tools. I can handle many MySQL tasks using SQLYog in order to simplify my work to create tables, databases, managing table permissions, creating database’s schema, sheduled backups, or any administrative tasks in MySQL.
But since I moved to Ubuntu, I searching for SQLYog alternatives on Ubuntu, since Webyog corporation who developer SQLYog did not create any binary nor source code for Linux environtment.
Then I was thinking of : “Why I didn’t use Wine to settle this problem?”. After a few clicks on Google, I found the solution. You can read it here how to install SQLYog on Ubuntu.
Thats it. Work like a charm.
This entry was written by gandaadmin, posted on January 26, 2011 at 2:30 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
Take a deep breath, think well. What is the output would be printed if this code is executed? Solve this one without compiling the code. Enjoy your time.
public class Rekursif
{
public static void main(String[] parameter)
{
System.out.println(f(100000));
}
static int f(int x)
{
if(x<=0) return 0;
return 1 + f(x/2);
}
}
This entry was written by gandaadmin, posted on January 23, 2011 at 10:05 pm, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
I’ve been told by my subordinate to use Ajax at our products. So I ask him what good Ajax is, what the advantage of using Ajax, what is the point of using Ajax, why do you like Ajax so much.
Then he answer.
- We can speed up the products performance for add/edit/delete function. User only need request the page only once.
- This Ajax will excite the users how the application looks and feel.
- This Ajax will increase user interaction.
Then I ask him again.
- How good are you with Ajax?
- Do you know about XSS(Cross Site Scripting) attack?
- Do you know how to handle it?
- Do you know how many possibilites of XSS attack?
- Can you overcome the XSS attack?
- Do you about eval() evil function?
- About user interaction, do you want to create another page without Ajax function if the javascript feature at the user’s browser is disabled?
- How do you know the user is a novice one that he/she know to configure web browsers?
- Do you want to spare your free time at home to do cross browser debugging?
This is not to prevent you too look at Ajax and use it. Ajax is good. I also like it. But be aware, be a smart programmer. If you are using Ajax, you are opening another hole for attacker to cracked your web/application. If you are expert with Javascript/Ajax/Security, nothing to be feared. Do not use Ajax because you like it, or you like to follow the trends.
This entry was written by gandaadmin, posted on at 12:44 am, filed under Uncategorized. Leave a comment or view the discussion at the permalink and follow any comments with the RSS feed for this post.
« Previous Entries