Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cpan DBD::mysql
- #!/usr/bin/perl
- BEGIN {
- use Exporter ();
- @ISA = "Exporter";
- @EXPORT =
- (
- $DBname, $DBhost, $DBuser, $DBpassword
- );
- }
- $DBname='dbdbdbdbdb';
- $DBhost='127.0.0.1';
- $DBuser='roger';
- $DBpassword='xxxxxx';
- #!/usr/bin/perl
- use DBI;
- my $dbh=DBI->connect("DBI:mysql:$DBname:$DBhost",$DBuser,$DBpassword, , { RaiseError => 1 }) || die($!);
- $dbh->do("SET NAMES UTF8");
- лалала $$params{TMPL_VARS}{MENU}=$dbh->selectall_arrayref("SELECT * FROM menu where type=$$USER_INFO{type} ", {Slice=>{}});
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement