Six years ago I wrote an large web application. It was my very first php program, and it grew, and grew. I used a lot of forms, and some very (atrocious) techniques to give an AJAX "look" to the site, and to handle multiple users with various permissions.
I am looking to expand this, and sell it to other companies in the field, but I need to seriously modernize it.
Currently, it loads index.php where you log in. The user can then select from various "students" or "participants" (We work with people with disabilities). From there, you can select different lesson plans or life skills that are being worked on. There are many other branches as well.
At each stage, a different page is served: Sel_Paricipant.php, Sel_Program.php, etc.
Are there any fundamental problems with doing it this way? If so, what are some good techniques for eliminating this, so that people only see the TLD in their address bar?
Thanks in advance. --Dave
It's not really normal practice, because you generally want to allow users the opportunity to bookmark a page if they need to. If you're sure it's the approach you need, to always display the TLD in the address bar, have the index.php
as the default served document in apache
(I assume this is already the case, it's default) and have that page load an iframe. This means the user can navigate around the application without seeing the page they're on. I'd question whether this is really necessary though.
If you are looking to modernise the software, consider migrating the code to a framework and rewrite the application. This will probably only be necessary if you're looking to bring on other programmers, or to extend the application, and you require a maintainable codebase to work with - however if you are, this will be invaluable.
I would write the app from scratch, use a clean lightweight frame work, and develop my app like the lego prinzip, one peace after another. It would take you more time to extend your current application to the "standards" than writing it from scratch.
The way you describe your site, I understand that there is:
The main fundamental problem with this approach as your web site grows is maintenance.
If you really plan something big, I would suggest a strong refactoring using a full-stack framework like Symfony.
If it was your first app and is rather large, then consider re-writing the application and using some sort of framework to pull most of the grunt work for you (why re-invent the wheel?). You'll end up with less bloat, have a more concise program, and less headaches down the road. Not to mention you have probably learned a thing or to since you first wrote it and could probably write it better the second time around.
You should focus on refactoring what you can to make it more maintainable. Put code in manageable modules/classes etc.
You will need to complete feature requests from paying customers soon. This is 1000% more important that having a static location bar for ascetic reasons.