473,385 Members | 1,693 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Include statements

I am currently using a perl script to process form data. I don't want
to lose the functionality I have with this script but need to output
the data to a mysql db. Someone mentioned that I should use includes
to process the form with a php script. Can one form be processed by
two scripts at the same time. If so is this a bad idea? It sounds like
it would solve my problem if it would work. The problem is that I have
done nothing more than setup a fre script that requires no coding. I
don't even know how to implement an include statement.
Jul 16 '05 #1
1 1908
The Voivod wrote:
I am currently using a perl script to process form data. I don't want
to lose the functionality I have with this script but need to output
the data to a mysql db. Someone mentioned that I should use includes
to process the form with a php script. Can one form be processed by
two scripts at the same time. If so is this a bad idea? It sounds like
it would solve my problem if it would work. The problem is that I have
done nothing more than setup a fre script that requires no coding. I
don't even know how to implement an include statement.


Don't let confuse yourself, if you have Perl and MySQL, you do not need
anything else:

use DBI;

$::db_host = 'localhost';
$::db_name = 'dbname';
$::db_user = 'root';

$::db = DBI->connect(
"DBI:mysql:host=$::db_host;database=$::db_name ",
$::db_user) || die $DBI::errstr;
my $stm= $::db->prepare("SELECT * FROM category ORDER BY category_id");
$stm->execute || die $::db->errstr;
my $LST = $stm->fetchall_hashref('category_id');
Regards,
Ondrej Brablc

Jul 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: wEEdpEckEr | last post by:
Hi, here's the deal: I have a config.php file in which I have set a few var's, to use in the whole site. E.g.: $db_host = "localhost"; Then I also have a class, which is supposed to...
60
by: Derrick Coetzee | last post by:
It seems like, in every C source file I've ever seen, there has been a very definite include order, as follows: - include system headers - include application headers - include the header...
5
by: David Mathog | last post by:
One thing that can make porting C code from one platform to another miserable is #include. In particular, the need to either place the path to an included file within the #include statement or to...
4
by: mglover | last post by:
i have a .html page that uses include statements for a header and footer that i have to rebuild in .net (.aspx pages) i am very new to .net and i do not know how if .net supports include...
14
by: Jon Rea | last post by:
I am currently cleaning up an application which was origainlly hashed together with speed of coding in mind and therefore contains quite a few "hacky" shortcuts. As part of this "revamping"...
5
by: Eric_Dexter | last post by:
I was trying to add this to my project but I must be missing some includes or there is a serius error somewhere Anthra Norell wrote:
12
by: Steve Pope | last post by:
Compiling the following works on my system: file main.cpp: #include <iostream> namespace space { int foo; }
1
by: patelxxx | last post by:
Guy's, The sitution is that I have 3 opions or select statements which the user selects and i need to include the AND operator in them, just in case the user selects all three options, how do I do...
12
by: duzhidian | last post by:
failed to open stream: No such file or directory I have the programs like this structure: a.php is locate at . b.php is located at ./lib c.php is located at ./lib/sublib a.php uses a...
4
by: sales | last post by:
I have used Include pages for a menu bar within a webpage - See below. <!--webbot bot="Include" U-Include="menu-categories.htm" TAG="BODY" -- It works fine when the page is htm format, but when...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.