Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
2012/4/28 Rouslan Placella rouslan@placella.com:
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I've used it before, especially when I need to tinker with some layout and css. On my Windows box at work I have the TidyHTML plugin installed, which kicks in when you look at the HTML source. So far this fulfilled my needs, but I guess it will be
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
2012/4/28 Dieter Adriaenssens dieter.adriaenssens@gmail.com:
2012/4/28 Rouslan Placella rouslan@placella.com:
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote: > Hi, > When touching a piece of code, if you see a "\n" generated for HTML, > it's pretty much safe to remove it (if proven otherwise, we'll build a > wiki page documenting those cases). > > The reason was to generate more readable HTML code; now that we > (hopefully) use Firebug to look at the generated HTML, these "\n" are no > longer needed. >
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I've used it before (or something similar), especially when I need to tinker with some layout and css. On my Windows box at work I have the TidyHTML plugin installed, which kicks in when you look at the HTML source. So far this fulfilled my needs, but I guess it will be a usefull tool when reviewing Rouslan's code this summer. ;)
Le 2012-04-28 04:56, Rouslan Placella a écrit :
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote:
Hi, When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
This is not the reason I was thinking of. The main reason is that, because some parts of the code are adding newlines to the generated HTML and some (most?) are not, it's unclear what future development should do.
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
On 28/04/12 12:36, Marc Delisle wrote:
Le 2012-04-28 04:56, Rouslan Placella a écrit :
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit :
On 27/04/12 14:26, Marc Delisle wrote: > Hi, > When touching a piece of code, if you see a "\n" generated for HTML, > it's pretty much safe to remove it (if proven otherwise, we'll build a > wiki page documenting those cases). > > The reason was to generate more readable HTML code; now that we > (hopefully) use Firebug to look at the generated HTML, these "\n" are no > longer needed. >
I'm not sure how good of an idea this is. What about the casual user that might want to have a stab at figuring out where something is going wrong, for example? Such a user may not have firebug.
Bye, Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
This is not the reason I was thinking of. The main reason is that, because some parts of the code are adding newlines to the generated HTML and some (most?) are not, it's unclear what future development should do.
I'd say that devs should make a judgement call on a per case basis. We already have a huge amount of guidelines and rules. If we add another guideline, people will have to remember and/or enforce it. And doing so for something that at the end of the day IMO is pretty irrelevant, is not necessary.
But it's a lot of work to apply it everywhere, so the question is if it's worth the effort. I don't need it, I usually use the Find function to find what I'm looking for in the html output anyway, or read the sourcecode.
Le 2012-04-28 07:52, Rouslan Placella a écrit :
On 28/04/12 12:36, Marc Delisle wrote:
Le 2012-04-28 04:56, Rouslan Placella a écrit :
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven:
Le 2012-04-27 14:55, Rouslan Placella a écrit : > On 27/04/12 14:26, Marc Delisle wrote: >> Hi, >> When touching a piece of code, if you see a "\n" generated for HTML, >> it's pretty much safe to remove it (if proven otherwise, we'll build a >> wiki page documenting those cases). >> >> The reason was to generate more readable HTML code; now that we >> (hopefully) use Firebug to look at the generated HTML, these "\n" are no >> longer needed. >> > > I'm not sure how good of an idea this is. What about the casual user > that might want to have a stab at figuring out where something is going > wrong, for example? Such a user may not have firebug. > > Bye, > Rouslan
It's mostly older parts of the codebase that are using "\n", so this casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
This is not the reason I was thinking of. The main reason is that, because some parts of the code are adding newlines to the generated HTML and some (most?) are not, it's unclear what future development should do.
I'd say that devs should make a judgement call on a per case basis. We already have a huge amount of guidelines and rules. If we add another guideline, people will have to remember and/or enforce it. And doing so for something that at the end of the day IMO is pretty irrelevant, is not necessary.
IMO it's not irrelevant. The main goal of version 4 is to improve code readability and it's confusing to see newlines generated in some parts and not in another.
2012/4/28 Marc Delisle marc@infomarc.info:
Le 2012-04-28 07:52, Rouslan Placella a écrit :
On 28/04/12 12:36, Marc Delisle wrote:
Le 2012-04-28 04:56, Rouslan Placella a écrit :
On 28/04/12 08:52, Marc Delisle wrote:
Le 2012-04-27 16:39, Dieter Adriaenssens a écrit :
Op 27 april 2012 21:11 heeft Marc Delisle marc@infomarc.info het volgende geschreven: > Le 2012-04-27 14:55, Rouslan Placella a écrit : >> On 27/04/12 14:26, Marc Delisle wrote: >>> Hi, >>> When touching a piece of code, if you see a "\n" generated for HTML, >>> it's pretty much safe to remove it (if proven otherwise, we'll build a >>> wiki page documenting those cases). >>> >>> The reason was to generate more readable HTML code; now that we >>> (hopefully) use Firebug to look at the generated HTML, these "\n" are no >>> longer needed. >>> >> >> I'm not sure how good of an idea this is. What about the casual user >> that might want to have a stab at figuring out where something is going >> wrong, for example? Such a user may not have firebug. >> >> Bye, >> Rouslan > > It's mostly older parts of the codebase that are using "\n", so this > casual user already has this problem.
For esthetic reasons I prefer to use the "\n", the produced html looks cleaner and better structured. It's a bit like using a coding style (indentation, ...) to have readable code.
Dieter, aren't you using Firebug to look at the HTML?
I wouldn't call Dieter a casual user, but this kind of proves my point. Also, I don't think that removing all the newlines will give us any noticeable decrease in page load times.
This is not the reason I was thinking of. The main reason is that, because some parts of the code are adding newlines to the generated HTML and some (most?) are not, it's unclear what future development should do.
I'd say that devs should make a judgement call on a per case basis. We already have a huge amount of guidelines and rules. If we add another guideline, people will have to remember and/or enforce it. And doing so for something that at the end of the day IMO is pretty irrelevant, is not necessary.
IMO it's not irrelevant. The main goal of version 4 is to improve code readability and it's confusing to see newlines generated in some parts and not in another.
True, it's not very consistent to have it in some parts and not in others.
If we would choose to use newlines, after which tags should we put one? While adding newlines is still OK, applying indentation in html, would take a lot of time to get right.
Anyway, Having newlines in html makes it look good, and gives a good impression to users who take a peek at the html. A messy html/code looks less attractive and will give the impression that phpmyadmin development is messy as well. I'm not saying that it is, but it's like marketing. If your product looks good, even in the details, it's more likely to attract customers (in our case prospective developers/contributers), the actual quality of the product defines if a customer will continue using the product. But a poor looking product (I'm not talking about our UI), will attract less customers even if the quality of the product is good.
I'm a fan of well structured code and well structured html, but I'm also aware that reaching this goal takes a lot of effort, effort that doesn't go into anything else. The question is of course how important it is for phpmyadmin to have well structured html (I think having well structured code is more important).
Hi
Dne Fri, 27 Apr 2012 09:26:43 -0400 Marc Delisle marc@infomarc.info napsal(a):
When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I don't have strong opinion on this. The preferred solution to this problem for me would be using templates, where the indentation and new lines come basically for free.
When working with HTML, I anyway use Firebug or Firefox built-in inspector, which does better job than any HTML formatting would do.
Le 2012-05-04 07:32, Michal Čihař a écrit :
Hi
Dne Fri, 27 Apr 2012 09:26:43 -0400 Marc Delisle marc@infomarc.info napsal(a):
When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I don't have strong opinion on this. The preferred solution to this problem for me would be using templates, where the indentation and new lines come basically for free.
Since we are not switching to templates for version 4.0, our GSoC students will need a more precise guideline about this.
I continue to think that it's too much work to manually generate proper indenting of generated HTML, and that having proper indentation was more an issue before Firefox / Firebug.
When working with HTML, I anyway use Firebug or Firefox built-in inspector, which does better job than any HTML formatting would do.
2012/5/4 Marc Delisle marc@infomarc.info:
Le 2012-05-04 07:32, Michal Čihař a écrit :
Hi
Dne Fri, 27 Apr 2012 09:26:43 -0400 Marc Delisle marc@infomarc.info napsal(a):
When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I don't have strong opinion on this. The preferred solution to this problem for me would be using templates, where the indentation and new lines come basically for free.
Since we are not switching to templates for version 4.0, our GSoC students will need a more precise guideline about this.
I continue to think that it's too much work to manually generate proper indenting of generated HTML, and that having proper indentation was more an issue before Firefox / Firebug.
I agree that it is too much work to review all the current generated HTML to have clean indentation and line breaks, but if new HTML generating code is added, it's not much effort to add a "\n" in the appropriate places. This will cause of course cause inconsistency in the generated HTML code (some will have line breaks, other will not), but that is the case already.
So the question is, in the long term, do we want properly indented generated HTML code, or completely unindented HTML?
Le 2012-05-04 11:17, Dieter Adriaenssens a écrit :
2012/5/4 Marc Delisle marc@infomarc.info:
Le 2012-05-04 07:32, Michal Čihař a écrit :
Hi
Dne Fri, 27 Apr 2012 09:26:43 -0400 Marc Delisle marc@infomarc.info napsal(a):
When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I don't have strong opinion on this. The preferred solution to this problem for me would be using templates, where the indentation and new lines come basically for free.
Since we are not switching to templates for version 4.0, our GSoC students will need a more precise guideline about this.
I continue to think that it's too much work to manually generate proper indenting of generated HTML, and that having proper indentation was more an issue before Firefox / Firebug.
I agree that it is too much work to review all the current generated HTML to have clean indentation and line breaks, but if new HTML generating code is added, it's not much effort to add a "\n" in the appropriate places.
This would not take care of the indentation, which is very important IMO. At least, in Firebug I watch indentation a lot.
This will cause of course cause inconsistency in the generated HTML code (some will have line breaks, other will not), but that is the case already.
So the question is, in the long term, do we want properly indented generated HTML code, or completely unindented HTML?
I prefer completely unindented HTML (those who want to see it indented only have to use the proper browser(s) ).
2012/5/4 Marc Delisle marc@infomarc.info:
Le 2012-05-04 11:17, Dieter Adriaenssens a écrit :
2012/5/4 Marc Delisle marc@infomarc.info:
Le 2012-05-04 07:32, Michal Čihař a écrit :
Hi
Dne Fri, 27 Apr 2012 09:26:43 -0400 Marc Delisle marc@infomarc.info napsal(a):
When touching a piece of code, if you see a "\n" generated for HTML, it's pretty much safe to remove it (if proven otherwise, we'll build a wiki page documenting those cases).
The reason was to generate more readable HTML code; now that we (hopefully) use Firebug to look at the generated HTML, these "\n" are no longer needed.
I don't have strong opinion on this. The preferred solution to this problem for me would be using templates, where the indentation and new lines come basically for free.
Since we are not switching to templates for version 4.0, our GSoC students will need a more precise guideline about this.
I continue to think that it's too much work to manually generate proper indenting of generated HTML, and that having proper indentation was more an issue before Firefox / Firebug.
I agree that it is too much work to review all the current generated HTML to have clean indentation and line breaks, but if new HTML generating code is added, it's not much effort to add a "\n" in the appropriate places.
This would not take care of the indentation, which is very important IMO. At least, in Firebug I watch indentation a lot.
Yes, I know. But having the newlines would give some kind of structure to the HTML. Getting indentation right is very difficult because you don't always know the level of indentation of the surrounding tags, especially when generating HTML in a function or class, because there is no context. Unless a framework or templating engine is used that generates all the HTML, like Michal mentioned.
This will cause of course cause inconsistency in the generated HTML code (some will have line breaks, other will not), but that is the case already.
So the question is, in the long term, do we want properly indented generated HTML code, or completely unindented HTML?
I prefer completely unindented HTML (those who want to see it indented only have to use the proper browser(s) ).
I prefer structured html (indented or having just newlines), but you have a point about the firebug tool.