• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

PHP Item Parser (DBV 1~3)

Junior Spellweaver
Joined
Jul 11, 2006
Messages
188
Reaction score
184
Old library of mine that I used on my old (unreleased) webshop.
This might be useful for someone, so I'm releasing it.



I'll add my container library (to be able to insert/remove items, space checking, blablabla...) once I find it.

Enjoy.

Pull requests accepted if it makes any sense. :eek:tt1:
 
Last edited:
Junior Spellweaver
Joined
Apr 14, 2007
Messages
111
Reaction score
2
Hey, just looked a little bit more at the code, I`ll edit my post as I go trough it (btw if I make grammatical mistakes it is because English is not my native language)

- your class names should follow at least psr4 for those who use your library with an autoloader
- let`s say that I use a method of one of the classes without looking into the code too much
in this case your methods throws exceptions but there is no phpDOC stating that, at least at the methods I`ve looked at
- @Item.php -> public function isExcellent()
this could be simplified to a simple return in_array(true, $this->excellent);

P.S: I know that most of the people here don`t give a .... at what I just said but maybe you`ll find this interesting on improving your skills if you want to work in a group of people you must always make sure that your code is fully documented and standardized
 
Last edited:
Junior Spellweaver
Joined
Jul 11, 2006
Messages
188
Reaction score
184
Hey, just looked a little bit more at the code, I`ll edit my post as I go trough it (btw if I make grammatical mistakes it is because English is not my native language)

- your class names should follow at least psr4 for those who use your library with an autoloader
- let`s say that I use a method of one of the classes without looking into the code too much
in this case your methods throws exceptions but there is no phpDOC stating that, at least at the methods I`ve looked at

P.S: I know that most of the people here don`t give a .... at what I just said but maybe you`ll find this interesting on improving your skills if you want to work in a group of people you must always make sure that your code is fully documented and standardized

This is realy old tho (Sep 2012), but don't take this as an excuse.

I'm more worried about standards these days too and it's a shame to release something like this. But hey, thats why I released it on github, so I can remember updating it from time to time as people use it.

Before releasing I had the autoloading in place, but I removed it since it wasn't going to work without the rest of the files (which were incomplete), and reworking everything to use namespaces was going to break support for old versions (which yes, people still use it and I don't really know why). So I decided to leave it as it was, just adding the Load.php file.

But I'll update the the code with inventory/warehouse, better standards/docs and maybe a composer package (why not?) as soon as I get some free time to do it.

If you want to make some PR, I'll be glad to accept it.

;)
 
Last edited:
Junior Spellweaver
Joined
Apr 14, 2007
Messages
111
Reaction score
2
There is no shame in releasing anything man, it`s nice that those like you still release stuff, I`ve downloaded a couple of 97d stuff to study c++ on it (left the language on pause because I got employed as a php developer) so as I work on it I`ll use your library at that point everything that I add/edit I`ll suggest as a PR.

p.s: people still use old versions because of nostalgia, I have lots of memories back in the day with my friends on older versions.
 
Junior Spellweaver
Joined
Jul 11, 2006
Messages
188
Reaction score
184
There is no shame in releasing anything man, it`s nice that those like you still release stuff, I`ve downloaded a couple of 97d stuff to study c++ on it (left the language on pause because I got employed as a php developer) so as I work on it I`ll use your library at that point everything that I add/edit I`ll suggest as a PR.

p.s: people still use old versions because of nostalgia, I have lots of memories back in the day with my friends on older versions.

Older PHP versions I mean.
For the game yes, I know. For example, I still maintain my old 97d MuServer project.
 
Junior Spellweaver
Joined
Apr 14, 2007
Messages
111
Reaction score
2
Ohhh well they keep using older versions of PHP because a lot of them don`t know how to config the new sqlserv extension, and probably don`t know how to make an upgrade or don`t care of the benefits of a newer version...
 
Back
Top