Jump to content

Is it possible? form in php


MartinPL

Recommended Posts

Hi guys,

I have got a question to you. I'm wondering about form but not in html. I'm talking about php form. I have reasons why I'm going to do it.

Please, let me try explain.

 

I have got a database and I take values from column and my script put them

into <select> - it works.

Next, I have to insert this values into different table in my database.

 

Is it possible to code html form in php?

As I know that is no way to put values from database into html form. So, it is why I did it in php.(take a look at the picture)

It is very important to put selected values(php) with other infrotmation(from html form) into database.

Any tutorial, information or whaever?

thanks and sorry for my English. I hope that you understand :)

 

checkthisoutj.th.jpg

 

 

Link to comment
https://forums.phpfreaks.com/topic/167757-is-it-possible-form-in-php/
Share on other sites

yes, it is possible to use HTML in php.

There are different ways, like echoing the HTML within php or write HTML outside php.

 

exmaple:

<?php echo "<table width='800' ....................>"; ?>

You have to know the use of quotes in this case.

 

example-2:

<?php $width = 800; ?>

<table width="<?php echo $width?>" >

thanks for your advice but in my opinion it leads to the same.

I have to insert values from 'php part' with values from html form and than insert everything into database.

At this moment they are seperated.

 

I will think about this and I will come back later with better description of this problem :)

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.