SMF - Not As Bad As I Thought

Judge Dredd

Old Guy
Joined
Apr 20, 2011
Messages
3,144
He isn't criticizing he just wants to talk about how oop is the best thing ever invented, he hasn't provided any real comparison or even a real suggestion for SMF, all he is doing is preaching about oop, thats not criticism, thats bashing a procedural coding style for the sake of talking about oop.

I don't recall him saying that it's the best thing ever invented. Even without looking at the code, one can state that for a script the size of SMF, it would be more efficient had it been written using OOP. It's simply a fact.
 

Suki

Developer
Joined
Sep 26, 2011
Messages
133
I don't recall him saying that it's the best thing ever invented. Even without looking at the code, one can state that for a script the size of SMF, it would be more efficient had it been written using OOP. It's simply a fact.

It would be more efficient? really, have you actually tried it?

Because I did tried it, I tried to refactor SMF database abstraction layer to a fully object oriented code.

It didn't have the same performance as the original and it used more memory because of the natural overheat of calling a method and instantiate a class.

There are parts that would be best if they were an object, yes, but not everything needs to be a object, specially not if the resulting code is less efficient. Again, one needs to know when and how.

Please, if you are going to talk about efficiency, try to back up your arguments with something more than just words, like actual tangible facts such as benchmarks.

And if you are going to preach about oop been easier for devs to maintain, at least have the courtesy to distinguish been easy to maintain from been efficient, those are 2 totally different aspects of code architecture.

You are confusing those 2 aspects, yes, oop is easier to maintain and develop but that doesn't mean the code is more efficient or the other way around, you can have code that is extremely fast and efficient but hard to maintain, those 2 are different aspects you seem to confuse.

If you truly want to criticize SMF then please try to point out specific features that would be beneficed from an oop point of view, state why and how it would be beneficial and try to avoid making general statements or arguments without any solid ground.
 

Judge Dredd

Old Guy
Joined
Apr 20, 2011
Messages
3,144
It would be more efficient? really, have you actually tried it?

Because I did tried it, I tried to refactor SMF database abstraction layer to a fully object oriented code.

It didn't have the same performance as the original and it used more memory because of the natural overheat of calling a method and instantiate a class.

There are parts that would be best if they were an object, yes, but not everything needs to be a object, specially not if the resulting code is less efficient. Again, one needs to know when and how.

Please, if you are going to talk about efficiency, try to back up your arguments with something more than just words, like actual tangible facts such as benchmarks.

And if you are going to preach about oop been easier for devs to maintain, at least have the courtesy to distinguish been easy to maintain from been efficient, those are 2 totally different aspects of code architecture.

You are confusing those 2 aspects, yes, oop is easier to maintain and develop but that doesn't mean the code is more efficient or the other way around, you can have code that is extremely fast and efficient but hard to maintain, those 2 are different aspects you seem to confuse.

If you truly want to criticize SMF then please try to point out specific features that would be beneficed from an oop point of view, state why and how it would be beneficial and try to avoid making general statements or arguments without any solid ground.

I'm not confusing anything. If anything, you're misinterpreting what I am saying. I am talking efficiency from a developer's point of view. I say performance when I talk about a script's performance.
 

HallofFamer

Habitué
Joined
Sep 6, 2010
Messages
1,345
@HallofFamer Thank you, I least you dropped the "amateurish" mentality.

And yes, you can have a god DB abstraction and MVC pattern on procedural, again, take a look at SMF's code!

An MVC pattern is as simple as keeping the logic outside the view, SMF does that in a fast, pretty simple and efficient way, you don't need oop to keep things organized, for the last time, oop is just a tool.

SMF should have started with oop?

Do you even know what was the state of PHP oop back in 2001 (when SMf started)? php4 was the king back then, you prob don't know that php4 oop capabilities aren't the best and that creating a bog project like SMF for php4 oop would have been a suicide...

Don't take me wrong but again, you don't have any idea about why the script was developed the way it is.

You don't have any idea about code structure either, you keep talking about "unmaintainable project" without even taking a look at the code, you just assume that is unmaintainable because it uses procedural, which doesn't seem very legit or objective to me...

Due to SMFs code architecture, it is relatively easy to maintain the codebase (relatively easy for a project of its size), again, been coded in procedural doesn't mean is a mess or it doesn't mean it has no organization at all.

I don't know where you learned that procedural can't be maintained or that it is mess just because is procedural.

oop can be spaghetti code as well, oop can be a mess as well, again, oop and procedural are just tools, they do not define how good you are.

If you haven't take a look at SMF's own code then we can't really continue to keep arguing since you base your assumptions on things you heard rather than taking a good look at the code.

I really hope for you to pass the "oop is everything" stage soon, took me a while for me to realize but eventually I learned oop is just a tool and I learned when to use oop ad when to use procedural and when to use both. And I really hope you stop bashing SMF without taking a good look at the code first.

Looks like you wrote a long post to explain things. I appreciate the fact that you are trying so much to prove something, but thats not the point I am trying to make here. As I've told you, I'd stop criticizing SMF 'cause I come to realize something. Its not that coding is the only thing matters for a quality forumware, I wouldnt say VB4 has worse scripts than VB3 but it just never turned out to be a better solution. I understand that there are other aspects of the software that make you a stand out. The convenience to use, the reliability and security, and even customer support are important factors that should come into play.

After seeing all those customer feedback, Id say your company actually did a nice job making people happy, unlike VB who is way more professional but ends up with a great number of angry customers. For this, I give SMF credits. Id say I was a bit way too cynical and carried away on the codebase discussion. In fact I am still nowhere impressed by SMF's coding style, nor do I see what you are saying as an acceptable justification for a forumware to go pretty much purely procedural when it should have gone with OOP in the very first place. But just like I've pointed out in the previous post, this is supposedly a subforum for clients to discuss their experience playing with the forum, not with the code. For a client's point of view, not from a developer's, it does not matter.

So yeah, I wish you good luck, I actually view you as a respectful coder despite these arguments we had before. Sorry if I used to sound like bashing, its really a religion and philosophy when it comes down to procedural vs OOP and I plan not to expand the topic in a place like TAZ. I cant change my philosophy, but I can come to conclusion that software design is more than just coding itself, thats why I drop my argument.
 

Suki

Developer
Joined
Sep 26, 2011
Messages
133
OK, it seems you don't read anything of what I post and you don't know anything about SMF either.

SMF is not a company. SMF is supported by an NPO organization. Please do search a little before making vague statements.

You don't have to be impressed, SMF wasn't made just for you to be impressed and since you are incapable of seen coding architecture beyond oop it is perfectly reasonable that you aren't impressed at all.

I already told you, do you even know what was the state of PHP oop in 2001? did you even know that at that time it was considered a pretty bad idea to use oop just like right now everyone preaches it?

...and in 10 years theres gonna be a new shiny tool that everyone is gonna use instead of oop and there will be people that will preach that new shiny tool just like you are doing it with oop right now.

And again, you don't seem to have any idea on the amount of work that will be involved in making a re-factor since you happily say "hey you should be oop" but you don't offer specific solutions to specific features that would really be beneficed from re-writing them in oop.

I'm sorry, but vaguely stating "you should be oop" doesn't help at all, doesn't bring anything new and doesn't prove anything other than you are easily impressed by shiny new things.

A refactor is in the way but not because you say so or because we are gonna use the new and latest shiny oop, it was because people involved saw the problems and saw viable solutions, is indeed a well though-out solution that covers all aspects and not only the coding part, of course the re-factor does include oop as the way it should be used, as a tool, the same with procedural, they are tools, TOOLS!

So please, stop making assumptions without knowing the full background and try to respect that not everyone thinks the same way as you, I don't care whats your philosophy or religion in a php context but it would be pretty awesome if you don't try to force it to everyone.
 

HallofFamer

Habitué
Joined
Sep 6, 2010
Messages
1,345
Oh my goodness I thought I told you I already dropped this argument, didnt I? Alright I am sorry its a NPO, not a company. You do not have to get this defensive, I remember I did say that I recognize the positive sides about SMF. Nor am I interested in trying to force my philosophy of PHP on everyone, otherwise Id still be aggressively posting where I used to stand. Clearly you missed out the major point I was trying to make in my last post, but hopefully this time I was being clear enough. Why dont we both take a step back then? Its useless and impossible trying to convince the others of our different ideas, and like I said before it may not be even appropriate to keep digressing from the topic of how the end user experience is with this software.
 
Last edited:

mrjay

Aspirant
Joined
Mar 17, 2013
Messages
26
Yes! SMF is not bad at all, infact you will be amazed when you see my SMF Forum.
 

adbrad

Habitué
Joined
Jun 20, 2010
Messages
1,291
my forum started of using smf, and the one thing that made me switch was the fact that all templates are written in php, which to me is very confusing, where as with it was written in pure html, i would find cutomisation a lot easier.
 

Suki

Developer
Joined
Sep 26, 2011
Messages
133
my forum started of using smf, and the one thing that made me switch was the fact that all templates are written in php, which to me is very confusing, where as with it was written in pure html, i would find cutomisation a lot easier.

There are pros and cons having all your templates in both pure HTML or PHP. This has been a heated debate over the years (in any script, not only forum software) and everyone has their own solution that worked for them. In SMFs case it was pure PHP.

SMF template system uses HTML wrapped in PHP:

echo '<div>', $var ,'</div>';

It has its downsides of course, specially for those who aren't used to PHP syntax, in reality, all you need to know is basic HTML, if you know HTML well, you can read the tags even if they are hidden inside a PHP statement or aren't highlighted by your favorite code editor.

As for advantages, since its pure PHP, it would be faster than any other template engine out there, it follows an extremely simple and effective way to deal with MVC, this helps a lot when writing modifications since the coder don't have to edit any template file, sadly, a lot of coders in SMF take the easy route (for them) and create template edits for their modifications, making it difficult for the regular user to manually install a mod.
 

Andrew B.

Fan
Joined
Jan 30, 2005
Messages
902
I had an SMF forum when I first joined here. I consider it in the top 3 free (MyBB/SMF/PHPBB).

The ugliest-looking forum script out there is without doubt FUDforum. And you can't even customize it !
That's the one I use. I must be some kind of pervert :biglaugh:

I could not help but chuckle. I tried to set up a FudForum community that was going to house a departing CompuServe community. It's an experience I don't care to relive. The Fud (as we called it) has some very good features. But it was torture to set up and customize, and it looked like it would never be easy to use. We ended up buying vBulletin instead.
 
Last edited:

eldritch1969

Adherent
Joined
Dec 24, 2012
Messages
495
I had an SMF forum when I first joined here. I consider it in the top 3 (MyBB/SMF/PHPBB).



I could not help but chuckle. I tried to set up a FudForum community that was going to house a departing CompuServe community. It's an experience I don't care to relive. The Fud (as we called it) has some very good features. But it was torture to set up and customize, and it looked like it would never be easy to use. We ended up buying vBulletin instead.

Yeah, only people with masochistic tendencies choose this script :creeper:
More seriously, it is perfect for us as the messages' layout enables users to get near full-screen or very detailed close-ups of their machines, and that's what they need.
Hopefully, the script is improving, really easy to set up, but forget about customization. ;)
 

adbrad

Habitué
Joined
Jun 20, 2010
Messages
1,291
There are pros and cons having all your templates in both pure HTML or PHP. This has been a heated debate over the years (in any script, not only forum software) and everyone has their own solution that worked for them. In SMFs case it was pure PHP.

SMF template system uses HTML wrapped in PHP:

echo '<div>', $var ,'</div>';

It has its downsides of course, specially for those who aren't used to PHP syntax, in reality, all you need to know is basic HTML, if you know HTML well, you can read the tags even if they are hidden inside a PHP statement or aren't highlighted by your favorite code editor.

As for advantages, since its pure PHP, it would be faster than any other template engine out there, it follows an extremely simple and effective way to deal with MVC, this helps a lot when writing modifications since the coder don't have to edit any template file, sadly, a lot of coders in SMF take the easy route (for them) and create template edits for their modifications, making it difficult for the regular user to manually install a mod.

i'm not saying it was a bad thing, just that it confused the hell out of mei find the htmltemplates easier to work with.
 

CMOBOSS

All About Da-Cookies.
Joined
Sep 14, 2006
Messages
2,701
Gerry your website is ... well... not functioning.
 

Steve

Fanatic
Joined
Apr 17, 2009
Messages
3,743
I don't think we need thread bumps just to say the associated site isn't working...
 

CMOBOSS

All About Da-Cookies.
Joined
Sep 14, 2006
Messages
2,701
If you've known me for a while or seen my posts in this SMF section then you know that I've long been highly against SMF, but have never really been able to give reasons to why I thought it was so bad.

Judge, How do you feel about SMF now that you have had a few more years to use it?

I don't think we need thread bumps just to say the associated site isn't working...

My apologies... I would have gone out of my way to include far more thoughtful content or inquiry, but I figured a simple bump would alert Gerry to the activity, and if he had replied I would have then put forth the efforts to post in greater length.

I'll make sure not to bump without clear expression of my reasons or intended interest for bumping. ;) .
 

wEbAddEr

Enthusiast
Joined
Oct 26, 2010
Messages
169
I did try a few days SMF out for a new site i want to build, but i feel that the hook system needs more fine tuning, when i did install about 20 hooks, ok i used from v2.0.7 to 2.0.13, there where some that gives conflict when uninstalling, others you can't install or you need to install them first on a fresh install, by the way i love that battle mod :tup:
 

vbgamer45

Adherent
Joined
Sep 22, 2005
Messages
292
I did try a few days SMF out for a new site i want to build, but i feel that the hook system needs more fine tuning, when i did install about 20 hooks, ok i used from v2.0.7 to 2.0.13, there where some that gives conflict when uninstalling, others you can't install or you need to install them first on a fresh install, by the way i love that battle mod :tup:
In SMF 2.1 it is way more hook focused and then probably 100+ hooks added to make it easier to customize.
 

wEbAddEr

Enthusiast
Joined
Oct 26, 2010
Messages
169
Cool, i will take a look again when SMF 2.1 have a stable release.
I use on a xf site 168 plugins, i LOVE plugins :)
 
Top