Jump to content

add values into class file


jason213123

Recommended Posts

hi,

i have a class file that have all values from a database fields.

for example:

 

 

class mospedidos extends mosDBTable {

id = null;

date =null;

}

 

class mosunder extends mosDBTable {

id = null;

name =null;

}

 

each time i creat a new field in the database i need add the same field in the

class file, what i want is a way using  php to add that new field to the class file.

i just need a way to open the file and the class name that i give and add the value

and save the file.

how can i do this?

thanks for your help

:)

Link to comment
Share on other sites

hi,

yes but i also need the default value for example

 

date =null; or date =1; etc

so i think in use a form in the script that can creat in same time a field in the database and the same value in the class.

in that form i can define the type of the field and the default value that i will be stored in the class file :)

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.