I have a couple of questions at this point.
I found the SVN repository at http://code.google.com/p/opencart/ ... is this the official repository? There does not appear to be any link to it from the home page.
Around the forum, I've seen older posts mentioning URL aliases as being a feature you turn on and off somewhere... But this does not seem to be part of the current version?
I need clean URLs for the site I'm developing, which will run on Apache, so I need some rewrites, at least.
Ideally, I would like to have search-engine friendly URLs, and I examined this add-on, but it appears to be totally outdated? None of the code in the index.php file resembles the code in that file in the current version. The CREATE TABLE statement for the url_alias table used by this contribution isn't even included in that zip file, so it seems pretty useless...
If I decide to put my own rewrites in place somehow, how do I get the system to compose clean URLs? I realize I could just edit system/library/url.php, but I was wondering if there's a cleaner way to do it? - I would like to keep an open upgrade path, and if I start to customize the system code, I might lose that option.
One other very minor thing puzzled me - in the config files, I see define('DB_PREFIX', 'cart_'); ... and the site works, but the tables in the database are not prefixed with "cart_", nor anything else ... I don't need a prefix, but is the prefix used for anything at all? Is it safe to remove? (will future versions start using it?) ... just wondering.
I would like to contribute to the codebase, if possible - I have 12 years of professional experience, and I'm pretty sure I could contribute useful things. I'm very concerned about things like avoiding bloat and overhead, and I understand (and love!) the code style of this project.
For example, I would really like to look into this URL stuff. Aliases really is missing for me, big time.
For starters, I just gave the Url class a quick once-over:
Code: Select all
<?php
final class Url {
private function compose($route, $secure = false) {
return ($secure ? HTTPS_SERVER : HTTP_SERVER) . 'index.php?route=' . str_replace('&', '&', $route);
}
public function http($route) {
return $this->compose($route);
}
public function https($route) {
return $this->compose($route, HTTPS_SERVER != '');
}
}
?>
Just a quick example of my way of thinking. If you'd like to examine my coding style in general, you could take a look at my php template engine...