My first Magento experience

On a fairly recent project I'd been working on a webstore using Magento.

Magento is an open source system using PHP and the Zend Framework.

One thing that we needed in this project was automatic shipping calculation with Canada Post... we found a module that gave that functionality and purchased it.

The installation process seemed pretty straight forward, went through the process and the module was then listed in Magento's configuration.

But the module wasn't working. The author of the module had written a test script which I began using to test with.

This module needed to use port 30000 to connect with the canada post system.. I contacted my technical support with the hosting provider and concluded that the port was open. I then used telnet and got a valid response (from the server).

I had also used another PHP script to connect with the canada post successfully which used stream_socket_client() and had programmed (for my own fun) a small test script in ColdFusion which had successfully connected....

After lot's of lookin' around, reading forum posts on Magento's forums, help from a twitter contact and trying a couple of PHP lists I had nothing. I was suspecting that somehow it was the PHP config or the curl command ... so I spent time looking that up.

After a bit, I was in contact with the module's author who suggested a couple of things. One of these things I had sworn I had tried... but must not of... or made the change in code and hadn't uploaded the file to the server in a tired state of mind....

It was to do with options for the curl command. The original code used was something like this:

// setting the url and port
$url = 'http://sellonline.canadapost.ca:30000';
$port = '30000';
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_PORT, $port);


 So the suggestion was to add the port directly to the url... and get rid of the curlopt_port... which looked something like this:

// basically this is what is being passed to the URL opt
$url = 'http://sellonline.canadapost.ca:30000';
curl_setopt($ch, CURLOPT_URL, $url);
// and comment out the port opt
//curl_setopt($ch, CURLOPT_PORT, $port);


By not using curlopt_port and adding the port to the URL.... it worked beautifully.

I should mention that this was being hosted on CentOS. Not exactly sure why it is that it wouldn't work... but it worked with the little fix.... and since this little fix there has been NO glitch.

Works perfectly!

Thanks to the module's author!

What are you working on?

 The last couple of weeks, after the christmas holidays, I went from finishing a bunch of stuff and getting a little bit "slacker" in terms of how much work I have... to now having work lined up for the next little while.

In the past 2 weeks I've had to upgrade software on a couple of servers... PHP, MySQL.. updates... I got to install and learn about APC for the first time.

I also got to work with Magento for the first time. Magento is an Ecommerce platform. Coded in PHP and using the Zend framework. This has prompted me to try to learn a bit more about PHP. Code it a bit more and I'm gonna learn "how it runs" just a tad more.

I've also got a project where I have to merge 2 existing ColdFusion apps... one using Model-Glue and the other a "home grown" kind of framework. These 2 apps then have to be merged into an existing intranet using another "home grown" framework.... user rights... etc.... should be a bit of a challenge in how it's supposed to work.

Then there's a couple of smaller ColdFusion projects.. which should be pretty straight forward.

And last but not least is something I've been trying to develop for quite some time... which I'm going to upgrade. A re-write. It's a ColdFusion app. The upgrade will use ColdBox or Model-Glue for the administrative section. Most likely keeping it's MySQL 5 DB in the backend.

Possibilities for a couple of things in near future too..... so, I will likely be busy.

Et vous??


RSS

Search

CF_Yves - Flickr

Sabian AAX crash
My Photostream

Calendar

Sun Mon Tue Wed Thu Fri Sat
   1234
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30   

Archives By Subject

A glimpse of the worst (4) [RSS]
Adventures in self-employment (8) [RSS]
Bands (13) [RSS]
Books (1) [RSS]
Business (18) [RSS]
Cars (2) [RSS]
Celebrities (5) [RSS]
ColdFusion (9) [RSS]
Comedy (2) [RSS]
Drums (9) [RSS]
Gigs (1) [RSS]
History (6) [RSS]
Hockey (10) [RSS]
Humour (1) [RSS]
Internet (6) [RSS]
Mac (3) [RSS]
Money $tuff (4) [RSS]
Montreal Canadiens (17) [RSS]
Music (27) [RSS]
Musicians (8) [RSS]
NBA (1) [RSS]
News (71) [RSS]
NHL (9) [RSS]
OpenBD (1) [RSS]
PHP (2) [RSS]
Picture Fun (2) [RSS]
Politics (5) [RSS]
Reading (1) [RSS]
Seventh Stone (7) [RSS]
Software (26) [RSS]
Stuff (2) [RSS]
Technology (72) [RSS]
Toronto Raptors (1) [RSS]
Videos (19) [RSS]
Web Development (1) [RSS]
World Stuff (4) [RSS]
Yves Stuff (66) [RSS]

Subscribe

Enter your email address to subscribe to this blog.

G Ads

Blogroll

The Hallway
Cracked Virtue

Blog sites

Add to Technorati Favorites

Blog Directory, Find A Blog, Submit A Blog, Search For The Best Blogs

Blogarama - The Blog Directory

Blogio.net blog directory

Blog Flux Directory

Tags

bands business hockey montreal canadiens music news software technology videos yves stuff