Tuesday, January 27, 2009

iPhone PDF/CHM/DOC/XLS viewer with Safari and Lighttpd



Hi guys,

tonight we finally have a great geeky post!



Once upon a time on my iPhone I had a wonderful package found via Installer that provided a cool directory listing for lighttpd on the iPhone in order to be able to browse some files and use Safari native capabilities to open them.



Unfortunately this package is no more in Cydia and Installer repositories (or I hadn't found it).

So tonight surfed the internet looking for it and I found this page with some information about it and (most important) the php script package.

After some experiments mixing the info with this other tutorial I found the way to get it working on my 1G iPhone with Firmware version 2.1



Here you are the installation in ten steps.





1. Get all the files you need



Download this .zip file containing the php script for cool directory listing on lighttpd





2. Install the packages you need



Install via Cydia these packages:

  • lighttpd
  • PHP




3. Connect to your iPhone via ssh (as root)



$ ssh root@[iphone IP address]

obtaining

[iphone host name]:~ root#

in my case

$ ssh root@192.168.1.xxx

Bilbo:~ root#





4. Create log folder for lighttpd and chown it properly



Bilbo:~ root# mkdir /var/log/lighttpd

Bilbo:~ root# chown nobody:nobody /var/log/lighttpd





5. Create a startup .plist file for lighttpd



Bilbo:~ root# nano /Library/LaunchDaemons/com.http.lighttpd.plist





You can simply use a file manager that supports ssh like Dolphin and Konqueror in KDE4 or simply Konqueror in KDE3. To use the graphical file manager with ssh you should use the fish:// protocol writing this in the address bar:

fish://root@[iphone-IP-address]

for me

fish://root@192.168.1.xxx





6. Create lighttpd config file



Bilbo:~ root# nano /usr/etc/lighttpd.conf



Copy this content in it







As you could notice this file differs from the one contained in the script package.

The first difference is that I chose to use as my data folder /private/var/mobile/Sites instead of /private/var/root/Sites



The other more important difference is the location of the php-cgi binary file, that is placed in /usr/bin in my installation insted of the old /opt/iPhone/bin



After having set the lighttpd.conf file you can check its syntax with this command from the terminal:

Bilbo:~ root# lighttpd -t -f /usr/etc/lighttpd.conf





7. Test your lighttpd and PHP config



Now you can create a file named test.php in /private/var/mobile/Sites to test lighttpd and PHP configuration:

Bilbo:~ root# nano /private/var/mobile/Sites/test.php

Copy this code in it to test PHP support:





Start the webserver manually with this command:

Bilbo:~ root# lighttpd -D -f /usr/etc/lighttpd.conf

Now you can open Safari and point to http://localhost/test.php to view the file.

If you can see the notice in green everything was good.

After the test you can simply stop lighttpd with a CTRL-C stroke in the terminal.





8. Copy the directory listing script folder and rename it



I made this step with Dolphin as I described before, checking later the permissions and the folder owner and group with the terminal. If you can't do the copy with a filemanager you can use scp or sftp from the command line.



After the copy or the dirlist folder into /private/var/mobile/Sites rename it like this

Bilbo:~ root# mv dirlist .dirlist





9. Copy your files on the iPhone



Now it's time to put your favourite file in /private/var/mobile/Sites to take advantage of the powerful capabilites of Safari to open natively those file thank to the proper bindings to the iPhone OS applications and libraries.





10. Enjoy



Now you have your web server ready to go. You have your files in the right place... the last thing to to is to start the system to begin to play!

Bilbo:~ root# launchctl load -w /Library/LaunchDaemons/com.http.lighttpd.plist

This should start the server properly as a daemon.

If you experience problem at this step don't worry you can use also there commands to stop everything before another attempt:

Bilbo:~ root# launchctl unload -w /Library/LaunchDaemons/com.http.lighttpd.plist

and

Bilbo:~ root# killall lighttpd



However the best thing to do now is to reboot to let the server start at boot itself (that is definitely the "right" way to start it).



Once you will have your server up and running you can easily point Safari to http://localhost to view your folder and to be able to open your files







I really hope my effort in making this guide will be useful not only for me as a reference but to some of you too!



Let's see...



As for now, that's all folks!



Keep on hackin'



Andy



5 NEW MODELS I DID WITH SKETCHUP 6...

YOU CAN SEE A DESCRIPTION, A PHOTO AND A 3D COMPLETE VIEW OF EACH MODEL CLICKING ON EACH PICTURE...
MODERN BUILDINGS






TRADITIONAL HOUSE

MODERN LOFT

... news from Gaza ...

Hi all.
today I want to suggest to you this reading, the January 18th post on Vittorio Arrigoni's blog, as an update on the situation in Gaza.


Making love under the bombs. I remember a friend from Nablous once telling me how difficult it was during the occupation to make time to reserve a moment of intimacy with his wife. One evening, while they lay in a tender embrace, a bullet lodged itself into their headboard, inches away from their heads. Canoodling under the bombs these days in Gaza is out of the question, and the conjugal future of young Palestinian couples is shaping up to be quite a challenge. Many have lost their homes and are forced to live amassed in the UNRWA schools, or crammed with as many as 20 people inside a tiny apartment. "Tonight is Saturday and the young couples in Tel Aviv go out and have fun in the clubs or on the beach. Meanwhile, out here we can't even make love in our own beds", says Wissam, who got married in November. "We also have strobe lights, though", he says, while pointing towards a succession of flashes from the South, the evidence of bombings in full swing. Young men like Wissam, nineteen, become fathers very early on in life and are already grandfathers by middle age, being aware as they are that in Palestine, this is the only form of immortality possible.
While on the outside there's talk of a truce, approved by Hamas but as usual rejected by Israel, in the last two days there's been an escalation of bombings with a subsequent boost in civilian deaths - 60 only yesterday. About ten were killed outside a mosque in the hour of prayer. What worries Palestinians the most is a ceasefire being called without a simultaneous reopening of the frontier passes. Firstly, this would serve to let the material and food supplies required for reconstruction, and secondly, to let the seriously wounded out. Hospitals are overwhelmed from over-crowding. In the entire Strip, they can accommodate a maximum of 1,500 beds, but the number of the wounded hovers around 5,320 at the moment. In addition, there's mistrust among Palestinian public opinion towards Egypt, the chosen intermediary for the talks, whose leadership is notoriously obsequious to Israel. "Why not have a European country to mediate? The role of Germany, a truly neutral country, was decisive in the resolution of the conflict between Israel and Hezbollah," says a heavy-hearted Hamza, a university professor.
This morning another UN school, in Beit Lahiya, North of the Gaza Strip, was hit full in the middle by Israeli tanks. There were 14 injured and two little brothers, Bilal and Mohammed Al-Ashqar, aged 5 and 7, were killed. Their mother survived, but she lost both her legs. Along with 42 thousand others, they had sought shelter in the school after Israel had ordered them to evacuate their homes. They believed they'd be safe there, just like the 43 refugees exterminated last 6th January in the UNRWA school massacre in Jabilia. "These two children were without a doubt innocent, just as there isn't the shadow of a doubt that they're now dead", said UN chief in Gaza, John Ging, who tirelessly, albeit in vain, continues to report the war crimes committed by the Israeli soldiers. But the Israeli Generals are still preparing themselves to make the "mission accomplished" announcement to the world.

I went back to what's left of Tal el Hawa hospital, the part still standing after the building was set on fire by the Israelis. It has now started operating as a first aid unit and logistical base for ambulances again. They continue to extract casualties trapped for days under the rubble left around its seriously damaged buildings. Shifa hospital hosts a child called Suhaib Suliman, the only survivor in a family of 25, all of whom are dead. A young girl, Hadil Samony, lost 11 relatives. She'll have no one to take care of her after being discharged from hospital. Excuse me, can someone please explain what kind of mission this is? Straight from collective punishment to mass slaughter.

On his blog, a frustrated Arab called Raja Chemayel sums it all up as follows: "Take a strip of land about 40 km long and only... 5 km wide. Call it Gaza. Then cram in one million four hundred inhabitants. After that surround it by the sea in the West, Egypt with Mubarak in the South, Israel in the North, and dub it "The land of terrorists". After that, declare war against it and invade it with 232 tanks, 687 armoured vehicles, 43 airports for fighter jets, 105 war helicopters, 221 units of ground artillery, 349 mortars, 3 spy satellites, 64 informers, 12 spies and 8,000 assault troops. Then call all of this "Israel defending itself". After that, stop for a minute and state that you will "avoid hitting the civilian population" and call yourself the only democracy in action. Whichever way you look at it, it'll be a miracle to avoid those civilians, or it could simply be a lie, since it's quite simply impossible to avoid hitting them! But once again, just call it "Israel defending itself." Now comes the question: what would happen if the invader turned out to be a liar? What would happen to those unarmed civilians?? With such firepower how could even Mother Theresa, or Mickey Mouse avoid hitting all those civilians, considering the equation/situation/scenario? Call it whatever you like, but Israel knew damn well about those unarmed people out there. It was Israel itself that had put them there! So, go ahead and call it a genocide! It's much more credible."

Aside from a couple of brutally assassinated leaders, Hamas hasn't suffered from this attack, and certainly hasn't lost its popularity - if anything, they've gained some more. Once in a while it would be wise to remember that Hamas aren't a bunch of terrorists, nor a political party, but a movement, and as such they're impossible to neutralise with a storm of cluster bombs. When I ask Palestinians for their opinions on the real agenda behind this brutal massacre, many say it has everything to do with the Israeli elections in February. They make propaganda using their heads, it's always been like this on the eve of all the elections. One head, one vote. Just one month ago, Netanyahu was forecast as the sure winner, but he's now expected to lose when competing with the blood-shot eyes of Olmert and Livni. Avigdor Lieberman is the leader of Yisrael Beitenu, the country's fifth political force, but the polls show that they are gaining consensus after statements like the following: "Gaza ought to be erased from the map with a nuclear bomb, the way the Americans did with Hiroshima and Nagasaki." Yesterday Israeli writer Abraham Yehoshua stated to Haaretz: "We kill their children today to save many more tomorrow". I'm afraid that now, his "Journey to the End of the Millennium" has ended up on board a tank in front of a hospital in flames. Voltaire invited us to respect all opinions. I would suggest to stop sewing the seeds of hatred, which are then sprinkled with blood and feed into a terminal resentment.

Stay human

Vittorio Arrigoni

Monday, January 26, 2009

Membuat Prakiraan Peta dengan Software Windwave-05 dan GIS 3.3

Halo semua,
hari ini kembali hadir setelah sekian lama vakum dari dunia per-blog-an. Kali ini saya mencoba membuat tutorial "membuat peta prakiraan dengan menggunakan software Windwave-05 dan GIS 3.3+spatial analysis"
Silahkan di unduh gratis filenya, di http://www.ziddu.com/download/3311030/LANGKAHwindwave.doc.html

Semoga bermanfaat..

LET'S GO GREEN!!

Friday, January 23, 2009

How to remove manually-installed plasma widgets

Since it was hard form me to find this on the net, I thought that was worth to spread the knowledge.

I did only the 50% I missed the .desktop file in ~/.kde4/share/kde4/services/

To remove non working widgets in the widget list, remove the related desktop files in:

~/.kde4/share/kde4/services/ (Desktop File)
~/.kde4/share/apps/plasma/plasmoids/ (Widget Package)

Tuesday, January 20, 2009

Change can happen



My fellow citizens:

I stand here today humbled by the task before us, grateful for the trust you have bestowed, mindful of the sacrifices borne by our ancestors. I thank President Bush for his service to our nation, as well as the generosity and cooperation he has shown throughout this transition.

Forty-four Americans have now taken the presidential oath. The words have been spoken during rising tides of prosperity and the still waters of peace. Yet, every so often the oath is taken amidst gathering clouds and raging storms. At these moments, America has carried on not simply because of the skill or vision of those in high office, but because We the People have remained faithful to the ideals of our forbearers, and true to our founding documents.

So it has been. So it must be with this generation of Americans.

That we are in the midst of crisis is now well understood. Our nation is at war, against a far-reaching network of violence and hatred. Our economy is badly weakened, a consequence of greed and irresponsibility on the part of some, but also our collective failure to make hard choices and prepare the nation for a new age. Homes have been lost; jobs shed; businesses shuttered. Our health care is too costly; our schools fail too many; and each day brings further evidence that the ways we use energy strengthen our adversaries and threaten our planet.

These are the indicators of crisis, subject to data and statistics. Less measurable but no less profound is a sapping of confidence across our land - a nagging fear that America's decline is inevitable, and that the next generation must lower its sights.

Today I say to you that the challenges we face are real. They are serious and they are many. They will not be met easily or in a short span of time. But know this, America - they will be met.

On this day, we gather because we have chosen hope over fear, unity of purpose over conflict and discord.

On this day, we come to proclaim an end to the petty grievances and false promises, the recriminations and worn out dogmas, that for far too long have strangled our politics.

We remain a young nation, but in the words of Scripture, the time has come to set aside childish things. The time has come to reaffirm our enduring spirit; to choose our better history; to carry forward that precious gift, that noble idea, passed on from generation to generation: the God-given promise that all are equal, all are free, and all deserve a chance to pursue their full measure of happiness.

In reaffirming the greatness of our nation, we understand that greatness is never a given. It must be earned. Our journey has never been one of short-cuts or settling for less. It has not been the path for the faint-hearted - for those who prefer leisure over work, or seek only the pleasures of riches and fame. Rather, it has been the risk-takers, the doers, the makers of things - some celebrated but more often men and women obscure in their labor, who have carried us up the long, rugged path towards prosperity and freedom.

For us, they packed up their few worldly possessions and traveled across oceans in search of a new life.

For us, they toiled in sweatshops and settled the West; endured the lash of the whip and plowed the hard earth.

For us, they fought and died, in places like Concord and Gettysburg; Normandy and Khe Sahn.

Time and again these men and women struggled and sacrificed and worked till their hands were raw so that we might live a better life. They saw America as bigger than the sum of our individual ambitions; greater than all the differences of birth or wealth or faction.

This is the journey we continue today. We remain the most prosperous, powerful nation on Earth. Our workers are no less productive than when this crisis began. Our minds are no less inventive, our goods and services no less needed than they were last week or last month or last year. Our capacity remains undiminished. But our time of standing pat, of protecting narrow interests and putting off unpleasant decisions - that time has surely passed. Starting today, we must pick ourselves up, dust ourselves off, and begin again the work of remaking America.

For everywhere we look, there is work to be done. The state of the economy calls for action, bold and swift, and we will act - not only to create new jobs, but to lay a new foundation for growth. We will build the roads and bridges, the electric grids and digital lines that feed our commerce and bind us together. We will restore science to its rightful place, and wield technology's wonders to raise health care's quality and lower its cost. We will harness the sun and the winds and the soil to fuel our cars and run our factories. And we will transform our schools and colleges and universities to meet the demands of a new age. All this we can do. And all this we will do.

Now, there are some who question the scale of our ambitions - who suggest that our system cannot tolerate too many big plans. Their memories are short. For they have forgotten what this country has already done; what free men and women can achieve when imagination is joined to common purpose, and necessity to courage.

What the cynics fail to understand is that the ground has shifted beneath them - that the stale political arguments that have consumed us for so long no longer apply. The question we ask today is not whether our government is too big or too small, but whether it works - whether it helps families find jobs at a decent wage, care they can afford, a retirement that is dignified. Where the answer is yes, we intend to move forward. Where the answer is no, programs will end. And those of us who manage the public's dollars will be held to account - to spend wisely, reform bad habits, and do our business in the light of day - because only then can we restore the vital trust between a people and their government.

Nor is the question before us whether the market is a force for good or ill. Its power to generate wealth and expand freedom is unmatched, but this crisis has reminded us that without a watchful eye, the market can spin out of control - and that a nation cannot prosper long when it favors only the prosperous. The success of our economy has always depended not just on the size of our Gross Domestic Product, but on the reach of our prosperity; on our ability to extend opportunity to every willing heart - not out of charity, but because it is the surest route to our common good.

As for our common defense, we reject as false the choice between our safety and our ideals. Our Founding Fathers, faced with perils we can scarcely imagine, drafted a charter to assure the rule of law and the rights of man, a charter expanded by the blood of generations. Those ideals still light the world, and we will not give them up for expedience's sake. And so to all other peoples and governments who are watching today, from the grandest capitals to the small village where my father was born: know that America is a friend of each nation and every man, woman, and child who seeks a future of peace and dignity, and that we are ready to lead once more.

Recall that earlier generations faced down fascism and communism not just with missiles and tanks, but with sturdy alliances and enduring convictions. They understood that our power alone cannot protect us, nor does it entitle us to do as we please. Instead, they knew that our power grows through its prudent use; our security emanates from the justness of our cause, the force of our example, the tempering qualities of humility and restraint.

We are the keepers of this legacy. Guided by these principles once more, we can meet those new threats that demand even greater effort - even greater cooperation and understanding between nations. We will begin to responsibly leave Iraq to its people, and forge a hard-earned peace in Afghanistan. With old friends and former foes, we will work tirelessly to lessen the nuclear threat, and roll back the specter of a warming planet. We will not apologize for our way of life, nor will we waver in its defense, and for those who seek to advance their aims by inducing terror and slaughtering innocents, we say to you now that our spirit is stronger and cannot be broken; you cannot outlast us, and we will defeat you.

For we know that our patchwork heritage is a strength, not a weakness. We are a nation of Christians and Muslims, Jews and Hindus - and non-believers. We are shaped by every language and culture, drawn from every end of this Earth; and because we have tasted the bitter swill of civil war and segregation, and emerged from that dark chapter stronger and more united, we cannot help but believe that the old hatreds shall someday pass; that the lines of tribe shall soon dissolve; that as the world grows smaller, our common humanity shall reveal itself; and that America must play its role in ushering in a new era of peace.

To the Muslim world, we seek a new way forward, based on mutual interest and mutual respect. To those leaders around the globe who seek to sow conflict, or blame their society's ills on the West - know that your people will judge you on what you can build, not what you destroy. To those who cling to power through corruption and deceit and the silencing of dissent, know that you are on the wrong side of history; but that we will extend a hand if you are willing to unclench your fist.

To the people of poor nations, we pledge to work alongside you to make your farms flourish and let clean waters flow; to nourish starved bodies and feed hungry minds. And to those nations like ours that enjoy relative plenty, we say we can no longer afford indifference to suffering outside our borders; nor can we consume the world's resources without regard to effect. For the world has changed, and we must change with it.

As we consider the road that unfolds before us, we remember with humble gratitude those brave Americans who, at this very hour, patrol far-off deserts and distant mountains. They have something to tell us today, just as the fallen heroes who lie in Arlington whisper through the ages. We honor them not only because they are guardians of our liberty, but because they embody the spirit of service; a willingness to find meaning in something greater than themselves. And yet, at this moment - a moment that will define a generation - it is precisely this spirit that must inhabit us all.

For as much as government can do and must do, it is ultimately the faith and determination of the American people upon which this nation relies. It is the kindness to take in a stranger when the levees break, the selflessness of workers who would rather cut their hours than see a friend lose their job which sees us through our darkest hours. It is the firefighter's courage to storm a stairway filled with smoke, but also a parent's willingness to nurture a child, that finally decides our fate.

Our challenges may be new. The instruments with which we meet them may be new. But those values upon which our success depends - hard work and honesty, courage and fair play, tolerance and curiosity, loyalty and patriotism - these things are old. These things are true. They have been the quiet force of progress throughout our history. What is demanded then is a return to these truths. What is required of us now is a new era of responsibility - a recognition, on the part of every American, that we have duties to ourselves, our nation, and the world, duties that we do not grudgingly accept but rather seize gladly, firm in the knowledge that there is nothing so satisfying to the spirit, so defining of our character, than giving our all to a difficult task.

This is the price and the promise of citizenship.

This is the source of our confidence - the knowledge that God calls on us to shape an uncertain destiny.

This is the meaning of our liberty and our creed - why men and women and children of every race and every faith can join in celebration across this magnificent mall, and why a man whose father less than sixty years ago might not have been served at a local restaurant can now stand before you to take a most sacred oath.

So let us mark this day with remembrance, of who we are and how far we have traveled. In the year of America's birth, in the coldest of months, a small band of patriots huddled by dying campfires on the shores of an icy river. The capital was abandoned. The enemy was advancing. The snow was stained with blood. At a moment when the outcome of our revolution was most in doubt, the father of our nation ordered these words be read to the people:

"Let it be told to the future world...that in the depth of winter, when nothing but hope and virtue could survive...that the city and the country, alarmed at one common danger, came forth to meet [it]."

America. In the face of our common dangers, in this winter of our hardship, let us remember these timeless words. With hope and virtue, let us brave once more the icy currents, and endure what storms may come. Let it be said by our children's children that when we were tested we refused to let this journey end, that we did not turn back nor did we falter; and with eyes fixed on the horizon and God's grace upon us, we carried forth that great gift of freedom and delivered it safely to future generations.

My Great Day



Its my best picture i take today after breakfast.
Click the images to view the actual size , right click and choose 'Save Image As' to download.




Monday, January 19, 2009

Presidential Transition/Obama '09

Barack Hussein Obama, the next president of the United States of America. Is time to forget 8 years of Bush government, and start again! Go Obama, we believe in you!!!
YES, WE CAN!

Sunday, January 11, 2009

A Song for Gaza

Saturday, January 10, 2009

Temari anime galleries

Temari anime galleries

Nara Shikamaru anime collection

Nara Shikamaru anime collection

Hyuuga Neji the master of byakugan

Hyuuga Neji the master of byakugan

Beautiful Yamanaka Ino anime series

Beautiful Yamanaka Ino anime series

Yamanaka Ino anime collection


About This Blog

About This Blog

  © Blogger template Brooklyn by Ourblogtemplates.com 2008

Back to TOP