Categories
Computing ios mobile

XCode iOS simulator is case insnsitive. iOS on Device is not.

We have an iPad app. We load images using file paths into the app. Images appear just fine in the iOS simulator. Images do not show up on the device. Fist shaken madly in the air, agony.

Thanks to my colleague Dolphy Fernandes we managed to discover the culprit. The iOS Simulator used by XCode loads file in a case insensitive manner. To it, a file called A55.jpg and a55.jpg are the same. iOS on devices, on the other hand, is case sensitive. Hence, A55.jpg will not load if the file name you are attempting to load is 'a55.jpg'.

Hope it helps…

Share
Categories
Computing Mac OS X

Parallels and Windows 7 really hate Virtual Box

While I am a huge fan of Virtual Box, work supplies us with Parallels and a Windows 7 virtual machine. I find Parallels to be slower but it works overall just fine. Recently I wanted to install a Linux VM so I installed Virtual Box on my Mac. As always, Virtual Box installs virtual network cards (vnic) and makes some modifications to the underlying OS.

My Parallels Windows 7 VM was running using shared networking. I needed to have it be accessible outside the host so I switched it to Bridged Networking using the host's Ethernet device. At that point something weird happened: the VM would connect to the network, get an IP address assigned, but it would report failing to get to the network gateway. It failed to see the outside Internet. Trying all sorts of Windows networking tricks did nothing to alleviate the situation, with Windows reporting that 'unauthenticated domain'. 

The solution: removing Virtual Box using the script that comes on its dmg installer, restarting the Mac host and starting Parallels again. Suddenly I was able to connect to the network just fine. 

Hope it helps others.

Share
Categories
Computing Mac OS X PHP Web Development

Enabling Oracle OCI8 PHP Extension on OS X Snow Leopard

My current project involves using PHP with an Oracle database. Oracle apparently embraces PHP warmly and as such supports an open source database driver for the environment called OCI8. As a Mac user I was looking to use OS X's built-in Apache and PHP setup, which like many PHP installations does not have the Oracle OCI8 driver installed or enabled. It took me some time and research to get it up and running. I was using Oracle Express, a limited capability, free-ish version of Oracle's database. Oracle Express was installed on a separate Windows machine as it cannot run or be installed on Snow Leopard. I also assume that you enabled PHP in your Apache configuration (/etc/apache2/httpd.conf) and have a /etc/php.ini by copying it from /etc/php.ini.default.

OCI8 relies on OS X having several client libraries and tools from Oracle installed on OS X. For most intents and purposes download the 64-bit version of the following files under the title "Version 10.2.0.4 (64-bit)": 

Registration is required for all downloads.

Share
Share