Web Images Videos Maps News Shopping Gmail more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Blank Lines before DOCTYPE
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  4 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
PaulV  
View profile  
 More options Apr 8 2007, 7:38 pm
From: "PaulV" <silvers...@gmail.com>
Date: Sun, 08 Apr 2007 16:38:46 -0700
Local: Sun, Apr 8 2007 7:38 pm
Subject: Blank Lines before DOCTYPE
Hi,

I am using cake 1.13 and I am getting 1 blank line before the DOCTYPE
on all my pages. I have checked my layout file and there is no blank
line there,

Any suggestions how I track down where the extra line is coming from?

   Paul


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
PaulV  
View profile  
 More options Apr 8 2007, 8:19 pm
From: "PaulV" <silvers...@gmail.com>
Date: Sun, 08 Apr 2007 17:19:40 -0700
Local: Sun, Apr 8 2007 8:19 pm
Subject: Re: Blank Lines before DOCTYPE

On 9 Apr, 00:38, "PaulV" <silvers...@gmail.com> wrote:

> Hi,

> I am using cake 1.13 and I am getting 1 blank line before the DOCTYPE
> on all my pages. I have checked my layout file and there is no blank
> line there,

Cake version 1.1.13

I have also checked all my model files, controller files which do not
have blank lines outside the enclosing <?php and ?> tags.

If I add html comments at the beginning and end of app_controller,
app_model and pages_controller, they appear before the blank line and
the DOCTYPE.

If I add an HTML comment before the doctype in the layout file, the
blank line appears before the html comment.

Which bit of cake code runs between loading all the models and the
particular controller, and the rendering of the layout?

   Paul


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
PaulV  
View profile  
 More options Apr 9 2007, 9:41 am
From: "PaulV" <silvers...@gmail.com>
Date: Mon, 09 Apr 2007 06:41:57 -0700
Local: Mon, Apr 9 2007 9:41 am
Subject: Re: Blank Lines before DOCTYPE
I've sorted it now with the help of Matti.

I had extra lines at the end of a helper. I never thought to check
those.

   Paul


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chris Lamb  
View profile  
(1 user)  More options Apr 9 2007, 10:02 am
From: Chris Lamb <ch...@chris-lamb.co.uk>
Date: Mon, 9 Apr 2007 15:02:30 +0100
Local: Mon, Apr 9 2007 10:02 am
Subject: Re: Blank Lines before DOCTYPE

PaulV wrote:
> I've sorted it now with the help of Matti.

> I had extra lines at the end of a helper. I never thought to check
> those.

Let's try a bit of magic:

$ find -name "*.php" | xargs sed -i -e :a -e '/^\n*$/{$d;N;ba' -e '}'

Removes all trailing newlines from PHP files under the current
directory -- run from app/. Would have fixed your problem straight away.

Regards,

--
 Chris Lamb, Cambridgeshire, UK                          GPG: 0x634F9A20

  signature.asc
< 1K Download

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google