| 4:47 pm on May 11, 2010 (gmt 0)|
Hi, I am developing the admin part of a school management system where the admin can add students, teachers, holidays, notices, etc. Now I have been given a sample website as a reference. In that sample website, on the left hand side there is a list as below:
Now when I put the cursor on 'Manage Students', a submenu appears on its right side. The submenu has the following:
View Student Profile
When I click on Add Student, the page /admin/addstudent.php opens up, whereas on clicking 'View Student Profile', the page /admin/viewstudent.php appears.
As far as I think the menu items can be added by the admin, that is, the menu shows up dynamically. I assume it to be like that...That said, would I be right if I say that the respective submenu items need to be specified while adding each menu item. Can anyone suggest how I get the submenu working?
| 5:47 pm on May 11, 2010 (gmt 0)|
Hey, that's MY system! (Kidding . . . . in mine, it's on the right. :-)
There are about a million and a half ways to do this. :-) I'll suggest the first that comes to mind.
Once it's all working, you have a page template for the administration area, and in this template you specify
In the .js file is all the stuff that assigns the menus and their respective links to the admin menus. I'll leave off there on that part, you can use Ajax or "grow your own" menus, depending on what you find easiest to learn. Likely you will only have to do one thing to the script you've developed, add ID's to the links:
<li><a href="script.php?res=students" id="student_link">Manage Students</a></li>
<li><a href="script.php?res=instructors" id="student_link">Manage Teachers</a></li>
<li><a href="script.php?res=holidays" id="student_link">Manage Holidays</a></li>
(Depending on how you implement your menus, you may NOT need to add the ID's. You may just have to point the JS at a class or ID just the <ul> - as I said, about a million and a half ways . . . )
| 5:44 pm on May 12, 2010 (gmt 0)|
oops . . . in the previous, ID's need to be unique, I have three "student_link" id's, make them student_link, instructor_link, holiday_link . . . hindsight=20/20 and all that, sorry.
| 1:34 pm on May 13, 2010 (gmt 0)|
I'm still in confusion...
I would like to know which is the simplest and best method to do this. Please consider providing helpful links or any tutorial (I'm new to Ajax).