I’ve been working on a successful project for 3 years that I am vested in. It is very possible that one day a larger company or competitor will want to acquire us.
In your opinion, if a company hired a tech team to learn about how my site is programmed, what would be the most appealing application design (if any)?
About the site:
The website is a PHP/MySQL database that contains five unique product channels. Some products are a database itself and is searchable, other products are just flat text descriptions that reference a price. I’ve also built a messaging system between users and a live event window we use every 3 months to showcase companies. I’ve built eCommerce hooks into the site and a checkout page. I have a scripts PHP file that contains most of the functions for the website and it is over 6,000 lines. I used a header and footer include as a template VS templating system like Smarty.
I do have a lot of comments for most of my code, I am just trying to look at this from an outside perspective, if I one day ever had to pass off the site to another developer or company.
Just bouncing a few ideas around and I am considering maybe doing a massive overhaul to use OOP to perhaps organize things better (I would have to learn it) and using a templating system like Smarty for page design.
Things could go two ways:
I go through the work of redoing the site using OOP and Smarty, the buyer thinks “wow this is great, its organized and we can work with this easily.”
The buyer thinks “Whether the site is unorganized or OOP, we will just take their products and customers and have our developers migrate it to .NET, etc. anyway”
My site is organized, but it also complex as it has grown from line one, to 6,000
If someone is looking to buy your site, most likely they’ll think how to make the money trough it without actually bothering to extend it or amend it much, which is most likely investing in marketing and such - and that has nothing to do with code.
If I were an outsider who is given a task to look at someone else’s website, I’d pay close attention to how the database is designed and then if I can quickly amend the site or add new features.
Now, whether that is MVC implementation or regular procedural website - it doesn’t matter as long as it doesn’t take more than a few minutes to add functionality, amend the design or fix something that might be broken.
However, if you have the opportunity to restructure your code - by all means, go the OOP way but only if you can do it properly. Adding tons of code and using design methods that aren’t appropriate and you use them only so you can show that you know what the cool kids use - don’t do that
Maybe a good and not to big task could be to split up the code in that file to individual files. Lets say one file for forms handling, one for html rendering etc. And maybe one file per product channel if that is possible.
That could possible give better performance as well as keep things organized …
More likely than anything, they would simply want your customer base. Code is relatively worthless to a large company.
If any company was to consider acquiring your web site and code was a factor, than MVC using a well known framework (Zend, CodeIgnitor, CakePHP) would probalby be what most people want.
They’d simply want something which is documented in detail.
A public framework is a good example of this as Alex pointed out, as they are not only well documented (usually) but there’s a good chance that one of the developers already knows the framework.
But that doesn’t prevent you from creating the site from scratch without a public framework. Just document it well, program it intuitively (I.e. don’t mix techniques - stick to a strict scheme and include a readme file telling the developers how it works) and market the website as much as possible before selling it. A million dollar/pound/$currency framework is pointless if the site it’s actually running is worthless.
And, as pointed out before, the most worthy things that a website holds are customers and services. So if you’re selling items to customers, all the buyer would really need would be the customer and product tables in the database. It’s rare for them to want to keep the code.