I think I found a bug. I'm checking with everyone here before I submit it.
Gallery 2.0RC1
File:Modules/ImageFrame/template/containers/ImageFrame.tpl
Find: <td rowspan="{$data.rowspan}" colspan="{$data.colspan}" class="IMG"
You will notice that the closing ">" is on the next line. This is causeing a BR / to be entered when rendered. So, the line ends up being "class="IMG" br />". This causes the shadow to extend above the image on the page when embedded using certain themes. Although I have corrected it on my personal sight, I can add it back to show someone upon request.
Solution: I just moved the > up one line right after the class entry. This immediately corrected the error.
Brian
Posts: 16501
I don't see any "class="IMG" br /> But I do see this:
Notice where the line break is. It's not adding a 'br', but there is a line break in the code.
Posts: 51
When I updated to RC2, the error reappeared. I submitted to the bug tacker, since it is a very simple fix. I also left uncorrected on my site so someone can see it.
Brian
Posts: 51
This is still an issue in the 1.0 release.
Posts: 16501
Can you provide a link to your site?
As I mentioned before, I see that the closing > is on a new line, but there is no br /> there. I agree that's something that should be fixed so it's easier to look at the source code, but it's not causing any problems with image frames on my site since there is no br /> generated.
Posts: 51
I corrected it on my site already. I don't think that it is that there is a BR />, it is that the > on the next line is being translated into br />. Not sure why, but it is. As soon as I fix it, it displays fine. It could be Wordpress adding the br, as I have gallery embedded in it. However the fix is very simple and seems to solve the problem.
http://www.kathiandbrian.com
Posts: 51
This still seems to be a bug in G2 2.0.2. It is a simple fix. Just move the ">" to the previous line, as mentioned above. Is it possible for someone to edit the file so future distributions are correct? Thanks! I love Gallery and I want to see it the best it can be!
Posts: 32509
but it ain't a g2 bug. it's valid HTML.
you can confirm that it looks ok in standalone G2, right? just when embedded in WP, WP translates it to a <br />, right?
if so, then it is a WP bug. it shouldn't do that.
Posts: 51
It looks fine standalone. I realize that it is probably a bug in WP. However, if you look at the file, I believe it is actually the only line break (and I don't mean BR, I mean line break in the text) in a spot like that. WP does seem to be misinterpretting the line. However, I didn't think it was that big a deal to correct it in G2.
Also, on a follow-up. The line break in the file, what kind of linebreak is it? Aren't there several different kinds? (I'm having a flashback to doing imports into MySQL). Perhaps the kind of break that it is is being interpretted as transposed to a BR. I realize that it isn't a bug, but it seems that it might be easy to correct. Just a thought.
Posts: 32509
in g2, all .inc / .class files should have maximally 100 characters.
in .tpl files, we try to nicely format too and only keep long text on a single long line.
thus we have a linebreak there.
@linebreaks: there are \n \r\n and \r dependending on the platform. in g2, we only use \n (unix style).
it's not a big issue and it's not worth discussing. fixed in cvs
Posts: 51
Thanks! I'm going to bring this over on the Wordpress boards as well. I agree totally that it is a Wordpress issue, so I wanted to thank you very much for making the change....sorry if I seemed a pain in the ass, but I also didn't know if it would affect other CMS/Blog systems out there as well. I doubt it, as I am sure you would have heard about it now.
Thanks again.
Brian