Link to home
Start Free TrialLog in
Avatar of Roger Gill
Roger GillFlag for United States of America

asked on

Trying to convert MS ACCESS features in WEB APP

Hello Experts,

I am trying to convert access to web app using PHP. Having some issues . Attached you will find MS ACCESS FILE.

1st... How to make  CONTINUOUS FORM like access in PHP. ( In attached MS ACCESS file you will see adding trip, when I add some data in first row, then new row is automatically added/generated)

2nd. Auto populate after update of Combo/Dropdown box. ( In attached file you will see when DRIVER is selected then the PHONE field is auto populated. How I can get it done this in PHP.

3rd. I have PARENT form and SUB form, when I open SUB FORM name ADD FUEL by clicking ADD FUEL button, new form is open with same [IDTrip] as parent [IDTrip] also sum of GALLONS & MILES sumsup in PARENT FORM.

Please let me if its possible thorough PHP or JAVASCRIPT./Jsquery.

Thanks million in advance.



Thanks
JB.accdb
Avatar of Scott Fell
Scott Fell
Flag of United States of America image

Your best bet is to take this in steps and work on one thing at a time.

Your first step is to just make a connection with the database.  In PHP using PDO is a good option http://php.net/manual/en/book.pdo.php and to find the right connection string https://www.connectionstrings.com/access/ 

I would suggest moving your data to sql server express https://www.microsoft.com/en-us/sql-server/sql-server-editions-express but you can make this work using your access db https://www.sitepoint.com/using-an-access-database-with-php/
$dbName = $_SERVER["DOCUMENT_ROOT"] . "products\products.mdb";
if (!file_exists($dbName)) {
    die("Could not find database file.");
}
$db = new PDO("odbc:DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=$dbName; Uid=; Pwd=;");

Open in new window


Like I said, just get this part to work for now, then move on.

Your next step will be learning how to update, insert and delete records.  After that you will want to learn some basic html, css and javascript/jquery.  If you are new to web development, then I find https://www.codecademy.com/learn/learn-html to be a good start.  Learn HTML, then CSS, then Javascript/jquery.

In short, what you call a continuous form is going to be looping through records and potentially using paging if there are a lot of records (more than 100).
Avatar of Roger Gill

ASKER

Thanks for the tip,  I am beginner but so far i learned  CONNECTION, INSERT , UPDATE, DELETE, DISPLAY. So I am to next level. I made this ACCESS database file just for explanation purposes. All I want to know is how to make CONTINUOUS FORM like access and how to open subform with same [ID] as parent form. Also how I can use AFTERUPDATE event on dropdown so I auto populate another fields.

Their are alot of experts with tons of knowledge I am sure someone will come up with their expertise and share the knowledge.
ASKER CERTIFIED SOLUTION
Avatar of Scott Fell
Scott Fell
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks Mr. Scott, Currently out of country on vacation that's why could not get back to you in timely manner. Soon as I am back from vacation I will try this.
Again thanks for your time and knowledge.