On Mon, 2 Feb 2004, Shanta McBain wrote:

> Hi
> 
> I have searched the archives but found no more information that is in the docs
> 
>     [% USE DBI( database = 'dbi:mysql:forager',
>                 username = 'user',
>                 password = 'pw' )
>     %]
> 
> returns 
> 
> DBI error - data source not defined in ContactView.ttml
> 
> How do you pass the host name ie localhost?
> Dose anyone has a working example I can hack?

I'm not sure the lack of hostname is the problem, as I think DBI
defaults to localhost.  But since the database argument is just a
regular DBI dsn, you could do this:

  [% USE DBI( database = 'dbi:mysql:forager;host=localhost',
              username = 'user',
              password = 'pw' )
  %]

I haven't tested that, but I think it should work.  However, I'm not
convinced it will solve your problem.

Take care,

Dave

/L\_/E\_/A\_/R\_/N\_/T\_/E\_/A\_/C\_/H\_/L\_/E\_/A\_/R\_/N\
Dave Cash                              Power to the People!
Frolicking in Fields of Garlic               Right On-Line!
[EMAIL PROTECTED]                                  Dig it all.


_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to