Documentation Index
Fetch the complete documentation index at: https://mintlify.com/ubik69/backEndDevelopment/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The Primary School Management System allows you to update existing records through dedicated update forms. Each update operation requires identifying the record by its ID and providing the new values for the fields you want to change.Accessing Update Forms
Navigate to the Update menu
From the navigation bar, click on the Uptade dropdown button (note the spelling in the source system).
Select record type
Choose the type of record you want to update:
- Student
- Parent
- Teacher
- Class
- Gym Member
- Salary
Updating a Student
To update an existing student record, navigate toUptadeStudent.html.
Student Update Form
The student update form requires:Identify the student
Enter the Student ID (
Sid) of the record you want to update. This is the unique identifier for the student.Provide new values
Fill in the fields you want to update:
- Student Name (
Sname): New first name - Student Surname (
Ssurname): New last name - Student Birthday (
Sbirthday): New date of birth (optional)
Backend Update Logic
TheUptadeStudent.php script processes the update:
The UPDATE statement uses a WHERE clause to identify the specific record by its ID, then sets new values for the specified columns.
Example Update
To update student with ID 5:- Enter Student ID:
5 - Enter Student Name:
Jennifer - Enter Student Surname:
Anderson - Enter Student Birthday:
2015-08-20 - Click Submit
Updating a Teacher
Teacher records can be updated throughUptadeTeacher.html.
To update a teacher, you need to know the Teacher ID and provide the new values for the fields you want to change.
Teacher Update Process
Enter new information
Provide the Teacher ID and the updated values for fields like:
- Teacher name
- Subject field
- Address
- Mobile number
- Email address
- Bonus amount
Updating a Parent
Parent records can be modified viaUptadeParent.html.
Parent Update Fields
Typical fields available for update:- Parent First Name (
Pname) - Parent Last Name (
Psurname) - Parent Address (
Paddress) - Parent Email (
Pemail)
Updating a Class
Class information can be updated throughUptadeClass.html.
Class Update Fields
If you change the Teacher ID for a class, ensure the new teacher ID exists in the Teacher table.
Updating Gym Member Records
Gym member information can be updated viaUptadeGym.html.
Updating Salary Records
Salary information can be modified throughUptadeSalary.html.
Salary Update Process
Identify salary record
Salary records are typically identified by Teacher ID or a unique salary record ID.
How Updates Work
All update operations follow the same pattern:Success and Error Messages
After submitting an update form:- Success: “Record has been uptaded.”
- Error: “Error uptading record.”
The spelling “uptaded” appears in the source code and will be displayed as-is in the system messages.
Best Practices for Updates
Verify the record ID
Before updating, use the View pages to confirm the correct record ID. Updating with the wrong ID will modify the wrong record.
Check foreign key relationships
If updating ID fields that are referenced by other tables (like Parent_ID or Teacher_ID), ensure the new ID exists in the parent table.
Validate data formats
Ensure dates are in the correct format (YYYY-MM-DD), emails are valid, and phone numbers match expected patterns.
Common Update Scenarios
Correcting Student Information
If a student’s name was misspelled during entry:- Go to View > Student to find the student’s ID
- Navigate to Update > Student
- Enter the Student ID
- Enter the correct spelling of the name
- Submit the update
Changing Teacher Contact Details
When a teacher’s phone number or email changes:- Note the Teacher ID from View > Teacher
- Access Update > Teacher
- Provide the Teacher ID
- Enter the new mobile number and/or email
- Save the changes
Adjusting Class Capacity
If a classroom changes and can accommodate more students:- Find the Class ID from View > Class
- Open Update > Class
- Enter the Class ID
- Increase the capacity value
- Submit the form
Troubleshooting Updates
If an update fails:Verify the ID exists
Check that the record ID you’re trying to update actually exists in the database. Use the View pages to confirm.
Check required fields
Ensure all required fields are filled in. The browser will typically prevent submission if required HTML5 fields are empty.
Validate foreign keys
If updating references (Parent_ID, Class_ID, Teacher_ID), verify those IDs exist in their respective tables.
Unlike delete operations, updates are generally safer because they don’t remove data. However, you should still maintain backups before performing batch updates.