Don't include template styles twice. #17 #18

Merged
merged 1 commit into from Jun 13, 2013

Projects

None yet

3 participants

@samwilson
Collaborator

(Moved from #17.)

style.css is being loaded twice in action.php, once in load_template() and once in load_css(). The former is correct, because it makes use of css_loadfile() which does the proper URL fixing etc. The problem is that then it's overridden in the second inclusion, so things don't work.

Am I correct in this? I've removed the $html .= $template['css']; line in my install and everything's working correctly. I'll send a pull request...

:-) Thanks!

@samwilson
Collaborator

This problem still exists. (I think I've rather messed up this pull request though! Sorry.)

@samwilson
Collaborator

No no, right, I understand... I've rebased it now. All is good?

@Klap-in
Collaborator
Klap-in commented Jun 13, 2013

Is this still merge-able? Seems reasonable for me to apply this PR.

Or does the order of DOKU_PLUGIN.'dw2pdf/tpl/'.$tpl.'/style.css matter with respect to @page css?

'@page { size:auto; '.$template['page'].'}';
@page :first {'.$template['first'].'}';
@splitbrain
Owner

@samwilson @Klap-in I don't have time to properly look at this currently. I gave commit access to both of you. Go, have fun :-)

@Klap-in
Collaborator
Klap-in commented Jun 13, 2013

@samwilson i don't think the order make a difference. So merged.

@Klap-in Klap-in merged commit 4e67f3a into splitbrain:master Jun 13, 2013
@samwilson
Collaborator

Thanks! :-)

Gosh, I'm not sure I'm the fellow to be given such responsibility... hehe... ah well, I shall merge nowt without agreement.

@samwilson samwilson deleted the samwilson:issue-17 branch Jun 21, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment