@font-face in your Face

I got this jewel of an error this morning while checking a site in IE10 that I hadn’t run across before.

CSS3117: @font-face failed cross-origin request error

Of course, it was glaringly obvious that the site hadn’t loaded the fonts I intended for it to load so the connection wasn’t being made. I did some quick searching and the “cross-origin” request in this case was that I hadn’t yet specified whether or not the site was to be only ‘www’ or non-www so the discrepancy apparently was enough to flag a security problem in IE. After adjusting the .htaccess file to route all traffic to the ‘www’ subdomain, all is working fine.

Hope that helps someone else out there.

Apple Goes “Flat”

I watched the blog ticker yesterday of the Apple Worldwide Developers Conference to see what all will be coming down the pipe for iOS and Mac OS. I have to admit that lately I’ve been less than impressed with the lack of seeming innovation coming from Apple. The last couple of years have seemed like more of the same – nothing too special on the UI or functionality standpoint of the line of Apple products. After all, Apple is supposed to be leading the industry, right? With Windows 8’s complete overhaul on design to a “flat”, blocky grid I was mildly impressed with the effort they put into their style guide.

The new “Control Center” in iOS7

So, coming into the conference with a somewhat jaded viewpoint (from a true Apple fanboy), I wasn’t expecting to be too excited. But, lo and behold it appears that Apple has done what it does best once again … mash super-simplicity with highly refined elegance. The new “flat” UI kicks the skeuomorphism to the curb and brings a vibrant, polished look to the stage – complete with parallax depth and scrolling effects that are tied to position of the phone, giving the home screen much more depth. I’m actually quite impressed. As people are now more intuitively understanding how buttons, swiping etc. work on a smart phone or desktop the need for hyperrealistic imagery like leather stitching, ripped notepads etc. is no longer a need to guide people in how to use a device. This idea of flat design is kind of a next step into a maturing user base of device users and it creates the flexibility to get super-clean with design and let it “get out of the way” so to speak.

Apple design guru, Jony Ives, described their philosophy of design as taking complex functionality and making it beautifully simple. Booyah! Check out the video here. That’s the challenge all designers face and I think from this first peek it looks like Apple has done it well.

One of the best features of the new iOS 7 is the task-switching feature. This always makes me crazy with my iPhone. I hate that I can’t quickly switch between apps without one closing down and another opening up. Having two apps running concurrently and rapidly switching between them should just work!

In summary, I’ve been a long-time Apple junkie and after a couple of years of feeling a bit “bored” by the lack of excitement I’m pretty excited to see how the new OS (Mavericks) and iOS 7 work in real life.

Drupal Views PHP and Text Values

Man, after much tinkering and frustration I have finally realized that when using Views PHP to construct fields you cannot print actual text values out. Instead it will produce the entity number in your output code.

So, in case you are trying to get a Global PHP field to write out an actual value from your database using a $row variable it’s not going to work. You’ll end up with the entity number instead of the text you’re retrieving. Either you have to use a Global text field and available tokens or retrieve the raw text like this using $data:

<?php print ‘<p>This is the text here. And, here is your ‘ .$data->field_field_yourvalue[‘0’][‘raw’][‘value’]. ‘</p>’; ?>

Here’s some more detail on this if anyone is interested. http://drupal.org/node/1140896