Edmonds Commerce Logo
  • home
    • blog
  • ecommerce
    • product catalogue
    • order processing
    • customer services
    • stock control
    • human resources
    • management information
  • development
    • oscommerce
    • php
    • mysql
    • open source
    • performance tuning
  • design
  • marketing
  • contact us
    • pricing

Edmonds Commerce Blog

Freelance PHP Ecommerce and SEO Developer in the UK

Latest Posts

Magento Most Popular Extensions
Google Chrome for Linux Beta
Firefox Address Bar Lag + Solution
Custom Buttons for Firefox

Most Popular Posts

Magento Developer UK Freelance osCommerce UK Magento Training CRE Loaded UK

Magento Most Popular Extensions

February 8th, 2010
Read More magento

Over at Magentocommerce.com they have just posted a blog story detailing the top ten most popular Magento extensions of the moment.

There are some great Magento extensions out right now and the selection is growing all the time.

Just another reason to use the most promising ecommerce package available today.

If you are looking for a Magento Developer or Magento Designer to help you get your Magento Ecommerce store online, get in touch today with Edmonds Commerce – UK based Magento and Ecommerce specialist.

Possibly Relevant Posts:

  • Magento How to Change the Favicon
  • Magento Line Up Grid View
  • Magento Leeds
  • Magento Backup Error Filesystem.php on line 234 + Solution
  • Magento Template Path Hints Tutorial
Get in Touch with Edmonds about Magento Most Popular Extensions
Add Comments

Google Chrome for Linux Beta

February 5th, 2010
Read More internet news

Just installed Google Chrome for Linux (Beta), so I could check out this pure CSS3 ATAT (requires a webkit browser).
http://anthonycalzadilla.com/css3-ATAT/index.html

Chrome seems to work fine, nice :)

Possibly Relevant Posts:

  • Google Chrome on Linux (Well Kind Of)
  • Ubuntu Bulk Find And Replace GUI – Regexxer
  • Avoiding 777 Permissions
  • Find Files Modified in the last X Days
  • Make Multiple Directories in One Go – Yes!
Get in Touch with Edmonds about Google Chrome for Linux Beta
Add Comments

Firefox Address Bar Lag + Solution

February 5th, 2010
Read More firefox

If your firefox address bar is getting a bit slow and laggy as it tries to find suggestions, I found one single about:config tweak totally sorted it out for me.

browser.urlbar.search.timeout = 100

change to

browser.urlbar.search.timeout = 10

To do this, open a new tab and type about:config

Then agree to the thing that says you know what you are doing and in the filter bar at the top type:

urlbar.search.timeout

you can then double click on the value (set to 100 by default) and change it to whatever you want. I tried 10 and that seems to work great for me, but you might want to experiment.

Possibly Relevant Posts:

  • Custom Buttons for Firefox
  • Firefox 3 Duplicate Tab Without Extension
  • Building Spiders: Grab Data, Post Forms and Interact with Web Sites Automatically
  • Web Developer Toolbar for Firefox
Get in Touch with Edmonds about Firefox Address Bar Lag + Solution
Add Comments

Custom Buttons for Firefox

February 4th, 2010
Read More firefox

Just discovered another great Firefox Addon

Custom Buttons..

tired or too lazy to use the right click for that frequent action (view source, reload all tabs)

this addon is for you

https://addons.mozilla.org/en-US/firefox/addon/5066

Possibly Relevant Posts:

  • Firefox Address Bar Lag + Solution
  • Firefox 3 Duplicate Tab Without Extension
  • Magento Custom Options Multiple File Upload Problem + Solution
  • Magento Custom Model via Mage::getSingleton()
  • Magento Module Not Working? This Might be Why
Get in Touch with Edmonds about Custom Buttons for Firefox
Add Comments

Douglas Crockford Javascript Videos Available

February 4th, 2010
Read More javascript

Douglas Crockford, author of Javascript the Good Bits and Yahoo’s Javascript architect is delivering his famous lectures.

The first one is now available to download.

Douglas Crockford is Yahoo!’s JavaScript architect and a member of the committee designing future versions of the world’s most popular programming language. In the first three months of 2010, Douglas will be delivering his acclaimed series of lectures on the history of JavaScript, its features, and its use.

http://yuiblog.com/crockford/

Possibly Relevant Posts:

  • Jquery 1.4 Released
  • Which Lightbox?
  • Javascript Associate Arrays / Objects with Dynamic Key Access
  • Loving jQuery and Netbeans
  • Handy Easy Javascript
Get in Touch with Edmonds about Douglas Crockford Javascript Videos Available
Add Comments

Zend Framework Error Invalid bind-variable name + Solution

February 3rd, 2010
Read More zend framework

If you encounter the error :

Invalid bind-variable name xxxxxx

When trying to use named bound parameters with Zend Framework, then you are probably using the Mysqli adapter. Unfortunately this doesn't actually support named parameters, but the Exception message isn't really clear on that, despite being thrown in this block of code:

PLAIN TEXT
PHP:
  1. } else if ($val[0] == ':') {
  2.     if ($this->_adapter->supportsParameters('named') === false) {
  3.         /**
  4.          * @see Zend_Db_Statement_Exception
  5.          */
  6.         require_once 'Zend/Db/Statement/Exception.php';
  7.         throw new Zend_Db_Statement_Exception("Invalid bind-variable name '$val'");
  8.     }
  9. }

The Exception should really say:

You are trying to use named parameters with an adapter that doesn't support them

The solution is easy, just switch your adapter from Mysqli to Pdo_Mysql

Possibly Relevant Posts:

  • Zend Framework – Reusing Prepared Zend_Db_Statements
  • Zend Framework UK
  • Zend Paginator – Actually Pretty Painless :)
  • Magento Backup Error Filesystem.php on line 234 + Solution
  • Magento Fatal Error getDbVersion()
Get in Touch with Edmonds about Zend Framework Error Invalid bind-variable name + Solution
Add Comments

mod_rewrite Strip Query String

February 3rd, 2010
Read More mod_rewrite

To make your RewriteRule strip the query string, simply append a ? to the end of the rewrite path, eg:

PLAIN TEXT
CODE:
  1. # redirect all requests to a subfolder to the home page
  2. # strips query string
  3. RewriteEngine On
  4. RewriteBase /
  5. RewriteRule ^subfolder/.*$ /index.php? [L,R=301]

Possibly Relevant Posts:

  • Htaccess Force SSL with Redirect (Non Standard SSL Port Compatible)
Get in Touch with Edmonds about mod_rewrite Strip Query String
Add Comments

PHP Into Compiled C++ – Hip Hop by Facebook

February 2nd, 2010
Read More php

Very interesting this one:

http://developers.facebook.com/news.php?story=358&blog;=1

With HipHop we've reduced the CPU usage on our Web servers on average by about fifty percent

sounds good to me :)

HipHop for PHP isn't technically a compiler itself. Rather it is a source code transformer. HipHop programmatically transforms your PHP source code into highly optimized C++ and then uses g++ to compile it.

Possibly Relevant Posts:

  • Zend Framework UK
  • Symfony Developer UK
  • PEAR not working for you, Open Basedir?
  • Now Teaching Zend PHP Courses
  • Playing with Symfony
Get in Touch with Edmonds about PHP Into Compiled C++ – Hip Hop by Facebook
Add Comments

Magento How to Change the Favicon

February 2nd, 2010
Read More magento

Every Magento based site I seem to look at is still using the default Magento favicon.

Whilst its cool to advertise that you are using Magento, perhaps you should be advertising your own business!

Its actually very easy to do - here's a step by step guide:

1. Create your Favicon.

First create a roughly square image with your logo in it, then upload it here to create your favicon itself:

http://tools.dynamicdrive.com/favicon/

2. Find the path to your Favicon.

All you need to do is go to your home page, view source and look for two lines like this:

PLAIN TEXT
HTML:
  1. <link rel="icon" href="http://www.******.co.uk/skin/frontend/****/****/favicon.ico" type="image/x-icon" />
  2. <link rel="shortcut icon" href="http://www.****.co.uk/skin/frontend/****/****/favicon.ico" type="image/x-icon" />

You now know where your favicon is being stored on your server.

3. Upload your Icon

Fire up your favourite FTP client, connect to your server, browse to the path you go from above skin/frontend/****/****/

Now rename the favicon that is up there to favicon.ico.backup

Now upload your custom one.

4. Check it out

Just reload your page. Note you may need to clear cache for the new favicon to display properly.

Possibly Relevant Posts:

  • Magento Most Popular Extensions
  • Magento Line Up Grid View
  • Magento Leeds
  • Magento Backup Error Filesystem.php on line 234 + Solution
  • Magento Template Path Hints Tutorial
Get in Touch with Edmonds about Magento How to Change the Favicon
Add Comments

Zend Framework – Reusing Prepared Zend_Db_Statements

February 2nd, 2010
Read More zend framework

If you use Zend_Db_Statements directly as well as using the Zend_Db_Table family of classes for Active Record et al then you might find the following little tip useful.

By default, if you run a query using something like

PLAIN TEXT
PHP:
  1. public function query($sql, $params=false) {
  2.     if(empty($params)) {
  3.         $stmt = $this->getAdapter()->query($sql);
  4.     }else {
  5.         $stmt = $this->getAdapter()->query($sql, $params);
  6.     }
  7.     return $stmt;
  8. }

then every time you call your query method, you will be preparing the statement again.

Of course that's not really a good idea if you are repeating the same query multiple times simply changing the parameters to be passed in.

In that kind of scenario you can do something like this:

PLAIN TEXT
PHP:
  1. $stmt = $db->query($sql, $params);
  2. $result1 = $stmt->fetch();
  3. $stmt->execute($params2);
  4. $result2 = $stmt->fetch();

Heres an example of a chunk of code that is working out a category path from an ecommerce system for a particular category id.

PLAIN TEXT
PHP:
  1. $stmt = $db->query("select c.parent_id, cd.categories_name from categories c join categories_description cd using(categories_id)
  2. where categories_id = ?", array($categories_id));
  3. while(false!==($r=$stmt->fetch())){
  4.     $categoryString[]=$r['categories_name'];
  5.     if($r['parent_id']==0){
  6.         break;
  7.     }
  8. //Note this bit - we are just re executing the statement with some new parameters.
  9.     $stmt->execute(array($r['parent_id']));
  10. }

This tip alone can add a lot of speed if you are doing repetitive statements

Possibly Relevant Posts:

  • Zend Framework Error Invalid bind-variable name + Solution
  • Zend Framework UK
  • Zend Paginator – Actually Pretty Painless :)
  • Magento Can’t Save Customer + Solution (Zend Framework)
  • Zend Framework Easy SQL Info
Get in Touch with Edmonds about Zend Framework – Reusing Prepared Zend_Db_Statements
Add Comments
Next Articles »
Next Page »
  • RSS Feed
  • Categories

    • adwords
    • apache
    • barcode
    • business
    • creloaded
    • css
    • curl
    • customer services
    • debugging
    • drupal
    • eclipse
    • ecommerce
    • edmondscommerce
    • email
    • excel
    • firefox
    • flash
    • gd
    • git
    • graphs
    • hosting
    • icecat
    • internet news
    • javascript
    • jquery
    • link building
    • linux
    • mac
    • magento
    • management
    • misc
    • mod_rewrite
    • mysql
    • netbeans
    • open suse
    • oscommerce
    • php
    • plesk
    • portfolio
    • product catalogue
    • product feed
    • programming
    • regular expressions
    • ria
    • scraping
    • search engine optimisation
    • security
    • seo
    • spidering
    • symfony
    • twitter
    • ubuntu
    • Uncategorized
    • usability
    • vps
    • web design
    • web development
    • Windows
    • xampp
    • zend framework
    • zip
  • Archives

    • February 2010
    • January 2010
    • December 2009
    • November 2009
    • October 2009
    • September 2009
    • August 2009
    • July 2009
    • June 2009
    • May 2009
    • April 2009
    • March 2009
    • February 2009
    • January 2009
    • December 2008
    • November 2008
    • October 2008
    • September 2008
    • August 2008
    • July 2008
    • June 2008
    • May 2008
    • April 2008
    • March 2008
    • February 2008
  • Tags

    bulk course cre loaded creloaded css custom developer development directories drupal error find firefox git google hosts file html jaunty javascript leeds links linux magento mysql netbeans oscommerce performance php plesk ppc problem replace search engine optimisation seo server symfony table training ubuntu uk virtualbox web web design xml zend framework
  • Random Posts

    • Saving a File or Webpage using PHP
    • Git Ignore All Files Except PHP etc + Solution
    • Magento Multistore Setup in a Nutshell
    • Freelance osCommerce UK
    • Advanced PHP Debug Function
    • Get Name from Email Address
    • Playing with Symfony
    • PHP 301 Redirect Function with Headers Check and Javascript Fallback
    • Plesk phpMyAdmin Copy Database Bug + Workaround
    • Magento Natively Supports Google Website Optimizer
  • Recent Comments

    • admin on Magento Backup Error Filesystem.php on line 234 + Solution
    • admin on Magento Leeds
    • Matthew Dolley on Magento Leeds
    • kash on PHP Email Attachment Function
    • Hussein on PHP Save Images Using cURL
  • Category Specific RSS

    • adwords Feed for all posts filed under adwords
    • apache Feed for all posts filed under apache
    • barcode Feed for all posts filed under barcode
    • business Feed for all posts filed under business
    • creloaded Feed for all posts filed under creloaded
    • css Feed for all posts filed under css
    • curl Feed for all posts filed under curl
    • customer services Feed for all posts filed under customer services
    • debugging Feed for all posts filed under debugging
    • drupal Feed for all posts filed under drupal
    • eclipse Feed for all posts filed under eclipse
    • ecommerce Feed for all posts filed under ecommerce
    • edmondscommerce Feed for all posts filed under edmondscommerce
    • email Feed for all posts filed under email
    • excel Feed for all posts filed under excel
    • firefox Feed for all posts filed under firefox
    • flash Feed for all posts filed under flash
    • gd Feed for all posts filed under gd
    • git Feed for all posts filed under git
    • graphs Feed for all posts filed under graphs
    • hosting Feed for all posts filed under hosting
    • icecat Feed for all posts filed under icecat
    • internet news Feed for all posts filed under internet news
    • javascript Feed for all posts filed under javascript
    • jquery Feed for all posts filed under jquery
    • link building Feed for all posts filed under link building
    • linux Feed for all posts filed under linux
    • mac Feed for all posts filed under mac
    • magento Feed for all posts filed under magento
    • management Feed for all posts filed under management
    • misc Feed for all posts filed under misc
    • mod_rewrite Feed for all posts filed under mod_rewrite
    • mysql Feed for all posts filed under mysql
    • netbeans Feed for all posts filed under netbeans
    • open suse Feed for all posts filed under open suse
    • oscommerce Feed for all posts filed under oscommerce
    • php Feed for all posts filed under php
    • plesk Feed for all posts filed under plesk
    • portfolio Feed for all posts filed under portfolio
    • product catalogue Feed for all posts filed under product catalogue
    • product feed Feed for all posts filed under product feed
    • programming Feed for all posts filed under programming
    • regular expressions Feed for all posts filed under regular expressions
    • ria Feed for all posts filed under ria
    • scraping Feed for all posts filed under scraping
    • search engine optimisation Feed for all posts filed under search engine optimisation
    • security Feed for all posts filed under security
    • seo Feed for all posts filed under seo
    • spidering Feed for all posts filed under spidering
    • symfony Feed for all posts filed under symfony
    • twitter Feed for all posts filed under twitter
    • ubuntu Feed for all posts filed under ubuntu
    • Uncategorized Feed for all posts filed under Uncategorized
    • usability Feed for all posts filed under usability
    • vps Feed for all posts filed under vps
    • web design Feed for all posts filed under web design
    • web development Feed for all posts filed under web development
    • Windows Feed for all posts filed under Windows
    • xampp Feed for all posts filed under xampp
    • zend framework Feed for all posts filed under zend framework
    • zip Feed for all posts filed under zip

Edmonds Commerce related questions? Send us a message or call us on 0844 357 0201.

Freelance PHP Web Design UK Commercial Web Design