Page 1 of 1

html text box taking data from database

Posted: Tue Sep 27, 2005 5:45 am
by rami
i have page which connected to database which retrives the datastored in the database...

and i have my index page as index.html which has navagation buttons and scrollbox in the side(whole page).

i want to feed the data from database to that textarea how can i do it....
i cannot copy all codes from html to php page...
or i am not being able to use php inside html
(i even use front page)
which has
<textarea rows="2" name="S1" cols="20">intial value</textarea>
for textarea
how can i do it
i think it can be done with those include....

the live example is
http://www.dmcinsights.com

Posted: Tue Sep 27, 2005 8:17 am
by Buddha443556
If you are able to use .htaccess then you could try adding:

Code: Select all

AddType application/x-httpd-php .php .html
This would let you embed <?php ?> in .html files. There's a cost to this, all your .html file will now go through PHP before being output. So consider your .html traffic load though this is usually not a problem on new sites.

Could also make a index.php file and redirect.