Click here to read about this example in my blog

Polylines in Google maps

Polylines encoded server-side

On this map the coordinates are encoded dynamically on the server using a PHP-script.

This map should have shorter load time than the one doing the encoding with Javascript in the browser..