Skip to content

Category: Thoughts

Symfony and My Network Configuration

I’ve been trying to learn the Symfony framework on my local test environment. Symfony provides a lot of the same skeletal generation of code in PHP as Rails does to Ruby, thus making the process of coding a bit faster. Plus, it creates a cleaner, easier-to-read alternative to straight PHP coding.

When trying to test my pages in the Symfony’s development environment, I get the following error: You are not allowed to access this file. Check app_dev.php for more information.

After some research I found the problem had to do with my network configuration. In my case my test server is not on my workstation, but a separate test server that I had set up on my network. The default code generated by Symfony only allows individuals to access the development environment pages from locally on the server. Since I’m accessing my web server from an outside machine on my network, Symfony will not let that fly. At least not with the code it has generated.

To remedy the situation I had to to edit my app_dev.php file underneath the web folder. The IP address of my workstation is 192.168.1.100 and I added it to the script like so:

// this check prevents access to debug front controllers that are deployed by accident to production servers.
// feel free to remove this, extend it or make something more sophisticated.
if (!in_array(@$_SERVER[‘REMOTE_ADDR’], array(‘127.0.0.1’, ‘::1’, ‘192.168.1.100’)))
{
die(‘You are not allowed to access this file. Check ‘.basename(__FILE__).’ for more information.’);
}

require_once(dirname(__FILE__).’/../config/ProjectConfiguration.class.php’);

$configuration = ProjectConfiguration::getApplicationConfiguration(‘app’, ‘dev’, true);
sfContext::createInstance($configuration)->dispatch();

4 Comments

iPhone iTems

Today, one of our student workers showed me a little-known feature with the iPhone. If you hold down the squarish “Home” button and press the power button, the iPhone will take a screenshot of your current screen. I think this could be a handy thing for blogging and works nicely with my WordPress app.

1 Comment

The Wait is Over…Kinda

I had almost expected that my M-Audio Delta PCI sound card was not going to work when I chose to install the 64-bit version of Vista on my new machine, but I did it nonetheless. And guess what? I’ve been waiting for months now for M-Audio to release a 64-bit driver for this old sound card that I have a strangely close kinship with.

It’s been good to me in the XP days, providing 24-bit/96kHz sound and low-latency recording possibilities. The ASIO support interfaced nicely with Fl Studio which allowed me to add software reverb and other effects while recording on the fly. I bought the card about 3 years ago and M-Audio is still selling the same thing.

Unfortunately, the company has left a lot of it’s customers in the pits of hell. We were stranded on the lonely desert island called Vista, waiting for them to develop a driver that allows their card to do what it was made to do. They released a private beta of the driver; this I thought was unfair because they selected who could do the beta testing and who couldn’t. When I submitted my request the outcome was pretty bleak.

The good new is that the public beta driver is now open for testing. M-Audio has the driver download hosted here. Note that it is still in the beta stages of development. To actually get the driver working I had to instill it, uninstall it and then reinstall it again. So far it’s been working nicely for me and I’m looking forward to doing some more recording at home. Now it’s just waiting for them to come out with a completely stable release.

Leave a Comment