This topic is locked

automatic fields

7/19/2008 2:27:22 PM
PHPRunner General questions
W
webimmagine author

hi guys,
can you help me plz,
how can i fill automaticlly 2 fields depending on another field value , <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=question&id=9039&image=1&table=forumtopics' class='bbc_emoticon' alt=':)' /> let me explain i have a table called agents table and another called a time agent table .
in my add page i add start time and end time for each agent the relation between the 2 tables is agent_id
how can i have the first name and last name filled automaticly if i enter the agent id on the adding page , can i add a new boutton to validate after entering the

agent id ?
let me know if i not clear enough ,
by the way the master table on list page works fine and show me all the informations from the agent table
thank you so much for your help, you guys are the best

J
Jane 7/21/2008

Hi,
to fill first and last names use dependent dropdown boxes on the add/edit pages.

Here is "How to setup dependent dropdown boxes on Edit/Add pages" PHPRunner tutorial:

http://xlinesoft.com/phprunner/php-database.htm

W
webimmagine author 7/22/2008

hi jane,
thanks for your help but i use already dropdown boxes for selecting other values , also i have many records on my table to list them by dropdown, i was thinking about adding a bouton with a request like :
select last_name from table where id = [post_id] but i tell you this is my real issue that i dont koow really how to add such sql code in my applications with php runner, last time i tried to calculate in the add page the
between 2 fields time because i have a third field wich supposed to show me the diff but ...
however you effort and help are more than appreciated and i really like a lot this forum , thank you thank you thank you thank you

J
Jane 7/23/2008

Hi,
you can add custom button and custom onchange JavaScript event on this page (on the Visual Editor tab in HTML mode) manually.

However we don't have a ready to go solution for this.

W
webimmagine author 7/23/2008

actually i have a real problem with the visual editor i tried even to add forms directly in the add.htm template, why i cant add a link or a text or even a pictures in the visual editor, i swear i tried everything do you guys had an issue like that ,
i dont get smarty error i just get the default template without my texts
please help, and i m really sorry to disturb you again .

W
webimmagine author 7/23/2008

now i m able to do some changes but directly in the templates after building the project

just to let you konw thanks <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=reply&id=31338&image=1&table=forumreplies' class='bbc_emoticon' alt=':)' />