Forum Moderators: coopster

Message Too Old, No Replies

Hidden Value

         

outdoorxtreme1

6:35 pm on Nov 7, 2005 (gmt 0)

10+ Year Member



How to I make a hidden value and what do I need to do so that it will post to MySQL every time I post something new?

NomikOS

7:01 pm on Nov 7, 2005 (gmt 0)

10+ Year Member



what? this?

<form method="post" action="<?php echo LOADER?>" name="postForm">
<input type="hidden" name="var" value="<?php echo $value?>" />

---

directrix

12:52 am on Nov 8, 2005 (gmt 0)

10+ Year Member



Do you mean a MySQL auto_increment field?

This is a MySQL feature that you can use on integer columns. You can leave the field null when inserting rows into the table, and MySQL will automatically populate it with a unique value that is one greater than the maximum in the column already.

So if you had...

create table custmast (
custno int unsigned not null auto_increment primary key,
name char(50) not null,
address char(200) not null
);

... then for the first record you insert, thus...

insert into custmast values (null, 'Acme Corp.', 'Main Street');

... MySQL will substitute the value 1 for null. For the second insert it would be 2, and so on.

Is that what you meant?

NomikOS

1:18 am on Nov 8, 2005 (gmt 0)

10+ Year Member



your post is totally obscure.-

outdoorxtreme1 you must give more information and finally say us if you already got the solution. In this way we can leave the threads answereds for continue with others.-

outdoorxtreme1

2:38 pm on Nov 8, 2005 (gmt 0)

10+ Year Member



oh, ok. sorry. Yes I solved this with the first post. I'm kind of new here. Now I know.

jatar_k

3:09 pm on Nov 8, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



no worries outdoorxtreme1, it is sometimes hard to describe things when you are new as you often aren't really sure what you need

otherwise you wouldn't to ask ;)

NomikOS, don't be so hard on folks, we're all just trying to figure things out together :)

NomikOS

3:09 pm on Nov 8, 2005 (gmt 0)

10+ Year Member



terrific outdoorxtreme1! glad for you!
cheers.-

[edited by: NomikOS at 3:22 pm (utc) on Nov. 8, 2005]

NomikOS

3:20 pm on Nov 8, 2005 (gmt 0)

10+ Year Member



OK.
I'm very serious, but I'm very lovely too ;)
Peace and good vibrations for all programmers.

---

jatar_k

3:28 pm on Nov 8, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



>> I'm very serious, but I'm very lovely too

just checking ;)

NomikOS

3:35 pm on Nov 8, 2005 (gmt 0)

10+ Year Member



All right! This is totally cool! I'm glad for stay here. This is the best community.-

---