87 users online (0 members and 87 guests)  


  Results 1 to 2 of 2

Related

  1. Replies: 0
  2. Code Help.    Forum: Myspace Forum
    Replies: 0
  3. I need help with this code.    Forum: HTML Forum
    Replies: 1
  4. Ignore code and link greeting note code    Forum: HTML Forum
    Replies: 3
  5. need code.    Forum: HTML Forum
    Replies: 1
  1. #1
    vivekkimi's Avatar
    New User

    Status
    Offline
    Join Date
    Nov 2008
    Posts
    2

    this is the code

    #!g:/perl/bin/perl.exe

    use Win32::ODBC;
    use CGI qw(:standard);
    print"content-type:text/html\n\n";

    print"<html>";
    print"<title> PROGRAM-5</title>";
    print"<body bgcolor=pink text=white size=2>";
    print"<font face=Pristina size=6>";

    print"<font face=Verdana color=black>";
    print"Program:5<br><br>";
    print"</font>";
    print"hi";

    use Win32::ODBC;
    $dsn= "dsn=insurance;uid=root;pwd=passwd;";

    if(!($con=new Win32::ODBC($dsn)))
    {print"CONNECTION FAILED";
    die"con failed";
    }
    $qry="select * from person;";
    $con ->sql($qry);

    while($con -> FetchRow())
    {
    %list=$con -> DataHash();
    $drid=$list{"drid"};
    print" Driver id=$drid";
    $name=$list{"name"};
    print" Name=$name";
    $ad=$list{"ad"};
    print" Address=$ad<br>";
    }


    print"</body>";
    print"</html>";
    Last edited by vivekkimi; 11-19-2008 at 11:43 AM.

  2. #2
    xmassey's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Apr 2007
    Posts
    100

    Re: this is the code

    Whats the problem?

    Just a quick tip. You should print chunks of html like this...

    Code:
    print <<"HTML Code";
    <p>test</p>
    <p>test2</p>
    HTML Code
    Chris



Tags for this Thread