Welcome Guest, Not a member yet? Register   Sign In
New project released with CodeIgniter
#11

[eluser]TheFuzzy0ne[/eluser]
[quote author="yannyannyann" date="1241538119"]Well my website is based on WORDPRESS unfortunately for you guys.[/quote]

I have recently been working with Wordpress, and it might just be me, but I felt the code under the bonnet was a mess, and the documentation was seriously lacking. The docs themselves are in abundance, but the structure is terrible. I was wondering whether I should consider porting Wordpress over to CodeIgniter in a future project in an attempt to make it cleaner, faster, and easier to extend. I haven't really put any more thought into it than that - just thought I'd see what everyone else thought.
#12

[eluser]yannyannyann[/eluser]
I agree with you

From a coding point of view Wordpress can easily become a Huge Mes, because you have to deal with :

- theme files
- plugins usually contain a lot of shiiiiiiit

I used Wordpress for my site because I had no time to go into CI and because a bit of tweaking you can achieve great things. (for the visitor)
#13

[eluser]Dam1an[/eluser]
I've not looked too much at the cource code for WP, but find the CI source seems much more natural and logically structured, not to mention amazingly commented!!

@Fuzz: You plan on basically replicating all of wordpress using CI? I'd have thought you have enough on your plate with your custom forum?

Quick stats
Wordpress
Code: 102347
Comments: 34649

CI (just the core, not the application directory)
Code: 19480
Comments: 14699

Anyone else shocked by the comment to code ratio?
#14

[eluser]TheFuzzy0ne[/eluser]
I do have lots on my plate. I was just thinking about this as a future project.

I had no idea that more than 75% of the CodeIgniter core was comments! I can't help thinking that stripping those comments, new lines and unnecessary indentation will make CodeIgniter go even faster!

I think people's views on comments vary. I think that each function/method should be commented without fail, and this can be used to generate docs also, but your code should document itself, and you should only need to document the areas that aren't straight forward.
#15

[eluser]Dam1an[/eluser]
Fuzzy, I think you got the wrong idea with those stats
They where generated using cloc
It gives a count for code, comments and blank lines
Code:
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
PHP                            117           5860          14699          19359
CSS                              1             22              0            121
-------------------------------------------------------------------------------
SUM:                           118           5882          14699          19480
-------------------------------------------------------------------------------
So the total line count is ~40,000 lines

But you do make a point, maybe CI should release a compressed and a dev version of the core (like jQuery does).

The dev version would be as it currently is, but the compressed version could have all the comments and blank lines stripped out (and indentation)
#16

[eluser]TheFuzzy0ne[/eluser]
I quick Google search reveals that the majority of programmers are of the opinion that it will make very little difference, it any at all. They say that opcode caching is the way to go. Is there such a thing as a standalone opcode cacher that's free and doesn't require installation on the server (Just upload, configure and go)?
#17

[eluser]Dam1an[/eluser]
I also had a quick google to see if removing comments/whitespace would make much difference, and as you say, the general verdict is negligable.
I also found out that php -w will output the file with comments/whitespace removed... so I might loop that over the CI core and run some benchmarks later... I'll post my findings (if I get round to it lol)
#18

[eluser]TheFuzzy0ne[/eluser]
Looking forward to it. Smile




Theme © iAndrew 2016 - Forum software by © MyBB