When I load pages off my local Apache server in Window Vista, there seems to be a 1-2 sec delay before the browser starts receiving and rendering the page. It is pretty slow considering the fact that it is a local request.
Apparently it has something to do with Windows Vista doing an IPv6 lookup on localhost each time a page is requested. Here’s how I fixed it.
Load up C:\Windows\system32\drivers\etc\hosts in a text editor
Your host file will look something like this
127.0.0.1 localhost
::1 localhost
All you need to do is comment out the “::1 localhost” line
127.0.0.1 localhost
# ::1 localhost
Save the file. This should solve the delay issue.
Thanks to the brilliant guys at apachelounge.
Blackberry phones are known to have very long start-up times. This is especially inconvenient when you’re wanting to swap over to a second battery, or swap a SIM card in a Blackberry phone. Here’s how you can save some time.
- Have a Blackberry/USB charger and the appropriate power source handy.
- Power off the device by pressing and holding on the power button, or selecting the “Turn Power Off” item from the home menu.
- Connect the Blackberry to the charger. You should see the charging indicator come on.
- Swap the battery or SIM card.
- This saves the need for a cold start-up on the phone.
Thanks to powerwind841117 from Blackberryforums.com.au
Before compiling anything from source on Ubuntu, the build-essentials metapackaged is installed by typing
sudo apt-get install build-essentials
On Fedora, the equivalent package is the package group “Development Tools”. This can be installed by typing
sudo yum groupinstall "Development Tools"
When opening big PHP projects in phpDesigner 2008, the CPU usage of the phpDesigner process gets stuck at 45-50% on my Core 2 Duo.
This is accompanied by the word “Parsing…” in the status bar at the bottom of the application window next to the project name. What’s actually happening is that phpDesigner is trying to parse all the files in your project, including any binary files (GIF, JPEG, PNG, etc.).
The way to fix it is to exclude file types from the project parser.
- Project -> Project Manager
- Select your project and click Edit
- Select the Fliters tab
Filter pattern determines the type of files that get included or excluded.
Kind determines the whether the filter operation affects the Project, the Parser or Both.
Here’s a sample of the filters I applied to my project which solved the high CPU usage problem:
Exclude Files
*.gif Parser
*.jpg Parser
*.js Parser
*.css Parser
*.log Parser
After you’re done, click OK. Close the project and re-open it. The “Parsing…” message should come up for a short while before disappearing. If the “Parsing…” message persists, you’ve probably left out some files from the “Exclude files” list (e.g. *.exe, *.bmp, *.pdf, etc.).
I was fiddling around with a friend’s iPhone 3G, looking for undocumented functions and features (it’s a pastime of mine).
I found out that if you press and hold the Home button and press the Sleep/Wake button, the screen flashes, and a screen grab (or screenshot) is taken of what’s currently displayed on the iPhone screen.
- Press and hold the Home button below the screen.
- Press the Sleep/Wake Up button at the top edge of the phone.
- Flash!
The screen grabs are stored in the Camera Roll library in the Photos App.
Apparently this only works on version 2.0 firmware and up.