emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* xml statement in html and apache error
@ 2011-04-07  3:36 Richard Riley
  2011-04-07  4:48 ` Nick Dokos
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Riley @ 2011-04-07  3:36 UTC (permalink / raw)
  To: Emacs-orgmode mailing list


I cant really give too many details or suggestions as to why it failed,
but the default xml string at the top of export to html files was
causing apache to fail.

,----
| Parse error: syntax error, unexpected T_STRING in
| /home/shamrock/common-files/webs/richardriley.net/projects/emacs/index.html
| on line 1
`----

I simply removed the html xml declaration,

,----
| org-export-html-xml-declaration is a variable defined in `org-html.el'.
| Its value is 
| (("php" . "<?xml version=\"1.0\" encoding=\"%s\"?>"))
`----

reexported my private little web, reloaded apache and all was
well. Which was cool considering I hadnt exported it from the org data
for all of about 2 years!

Far from thought out, almost certainly not "correct" I am sure, but got
my web back working.

Possibly someone else can comment on cause/effect.

regards

r.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: xml statement in html and apache error
  2011-04-07  3:36 xml statement in html and apache error Richard Riley
@ 2011-04-07  4:48 ` Nick Dokos
  2011-04-07  9:18   ` Richard Riley
  0 siblings, 1 reply; 6+ messages in thread
From: Nick Dokos @ 2011-04-07  4:48 UTC (permalink / raw)
  To: Richard Riley; +Cc: nicholas.dokos, Emacs-orgmode mailing list

Richard Riley <rileyrg@googlemail.com> wrote:

> 
> I cant really give too many details or suggestions as to why it failed,
> but the default xml string at the top of export to html files was
> causing apache to fail.
> 
> ,----
> | Parse error: syntax error, unexpected T_STRING in
> | /home/shamrock/common-files/webs/richardriley.net/projects/emacs/index.html
> | on line 1
> `----
> 
> I simply removed the html xml declaration,
> 
> ,----
> | org-export-html-xml-declaration is a variable defined in `org-html.el'.
> | Its value is 
> | (("php" . "<?xml version=\"1.0\" encoding=\"%s\"?>"))
> `----
> 

This looks wrong (even though unrelated to the problem): in my setup I get

--8<---------------cut here---------------start------------->8---
org-export-html-xml-declaration is a variable defined in `org-html.el'.
Its value is
(("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>")
 ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
--8<---------------cut here---------------end--------------->8---

so deleting the html entry should leave you with the second line. You seem
to have a mash of the two entries instead.

> reexported my private little web, reloaded apache and all was
> well. Which was cool considering I hadnt exported it from the org data
> for all of about 2 years!
> 
> Far from thought out, almost certainly not "correct" I am sure, but got
> my web back working.
> 
> Possibly someone else can comment on cause/effect.
> 

Well, I exported a toy project and despite the presence of the xml headers,
my apache is not complaining at all. I also spot-checked a couple of files
on orgmode.org and they have the xml header, but apache seems to deliver
them without a problem. Which version of apache are you running? Mine is
2.2.16.

Nick

PS. The exercise also uncovered an org bug but I'll post that as a
separate message.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: xml statement in html and apache error
  2011-04-07  4:48 ` Nick Dokos
@ 2011-04-07  9:18   ` Richard Riley
  2011-04-07 14:00     ` Nick Dokos
  2011-06-26 18:15     ` David Maus
  0 siblings, 2 replies; 6+ messages in thread
From: Richard Riley @ 2011-04-07  9:18 UTC (permalink / raw)
  To: nicholas.dokos; +Cc: Emacs-orgmode mailing list

Nick Dokos <nicholas.dokos@hp.com> writes:

> Richard Riley <rileyrg@googlemail.com> wrote:
>
>> 
>> I cant really give too many details or suggestions as to why it failed,
>> but the default xml string at the top of export to html files was
>> causing apache to fail.
>> 
>> ,----
>> | Parse error: syntax error, unexpected T_STRING in
>> | /home/shamrock/common-files/webs/richardriley.net/projects/emacs/index.html
>> | on line 1
>> `----
>> 
>> I simply removed the html xml declaration,
>> 
>> ,----
>> | org-export-html-xml-declaration is a variable defined in `org-html.el'.
>> | Its value is 
>> | (("php" . "<?xml version=\"1.0\" encoding=\"%s\"?>"))
>> `----
>> 
>
> This looks wrong (even though unrelated to the problem): in my setup I get
>
>

You're right. Was late at night. I pasted the wrong value. The working value
is

,----
| org-export-html-xml-declaration is a variable defined in `org-html.el'.
| Its value is 
| (("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
`----

That other value was in my scratch buffer from trying to debug the
situation. Note, I dont export to php, only html (currently).

>
> org-export-html-xml-declaration is a variable defined in `org-html.el'.
> Its value is
> (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>")
>  ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
>
>
>
> so deleting the html entry should leave you with the second line. You seem
> to have a mash of the two entries instead.
>

Sorry! Mea culpa there in my "bug report".

>> reexported my private little web, reloaded apache and all was
>> well. Which was cool considering I hadnt exported it from the org data
>> for all of about 2 years!
>> 
>> Far from thought out, almost certainly not "correct" I am sure, but got
>> my web back working.
>> 
>> Possibly someone else can comment on cause/effect.
>> 
>
> Well, I exported a toy project and despite the presence of the xml headers,
> my apache is not complaining at all. I also spot-checked a couple of files
> on orgmode.org and they have the xml header, but apache seems to deliver
> them without a problem. Which version of apache are you running? Mine is
> 2.2.16.

Two machines, both with Debian Squeeze.

,----
| Server version: Apache/2.2.16 (Debian)
| Server built:   Mar 22 2011 20:56:31
`----

>
> Nick
>
> PS. The exercise also uncovered an org bug but I'll post that as a
> separate message.
>

Let me re-run the scenario and check my publish parameters - its really
been a LONG time since I published but something changed with
apache. Both machines are relatively new installs. Possibly something
third party needs to be instaled on squeeze now to get xml statements
parsed? A google was not so helpful.

Thanks for the prompt reply.

r.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: xml statement in html and apache error
  2011-04-07  9:18   ` Richard Riley
@ 2011-04-07 14:00     ` Nick Dokos
  2011-04-07 17:52       ` Nick Dokos
  2011-06-26 18:15     ` David Maus
  1 sibling, 1 reply; 6+ messages in thread
From: Nick Dokos @ 2011-04-07 14:00 UTC (permalink / raw)
  To: Richard Riley; +Cc: nicholas.dokos, Emacs-orgmode mailing list

Richard Riley <rileyrg@googlemail.com> wrote:

> 
> Two machines, both with Debian Squeeze.
> 
> ,----
> | Server version: Apache/2.2.16 (Debian)
> | Server built:   Mar 22 2011 20:56:31
> `----
> 
> >
> > Nick
> >
> > PS. The exercise also uncovered an org bug but I'll post that as a
> > separate message.
> >
> 
> Let me re-run the scenario and check my publish parameters - its really
> been a LONG time since I published but something changed with
> apache. Both machines are relatively new installs. Possibly something
> third party needs to be instaled on squeeze now to get xml statements
> parsed? A google was not so helpful.
> 

You may be right: I load modxslt on my apache - forgot about that. Not
sure whether the orgmode.org apache uses that as well. If I find some
time, I'll try without it.

Nick

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: xml statement in html and apache error
  2011-04-07 14:00     ` Nick Dokos
@ 2011-04-07 17:52       ` Nick Dokos
  0 siblings, 0 replies; 6+ messages in thread
From: Nick Dokos @ 2011-04-07 17:52 UTC (permalink / raw)
  Cc: Richard Riley, nicholas.dokos, Emacs-orgmode mailing list

Nick Dokos <nicholas.dokos@hp.com> wrote:

> Richard Riley <rileyrg@googlemail.com> wrote:
> 
> > 
> > Two machines, both with Debian Squeeze.
> > 
> > ,----
> > | Server version: Apache/2.2.16 (Debian)
> > | Server built:   Mar 22 2011 20:56:31
> > `----
> > 
> > >
> > > Nick
> > >
> > > PS. The exercise also uncovered an org bug but I'll post that as a
> > > separate message.
> > >
> > 
> > Let me re-run the scenario and check my publish parameters - its really
> > been a LONG time since I published but something changed with
> > apache. Both machines are relatively new installs. Possibly something
> > third party needs to be instaled on squeeze now to get xml statements
> > parsed? A google was not so helpful.
> > 
> 
> You may be right: I load modxslt on my apache - forgot about that. Not
> sure whether the orgmode.org apache uses that as well. If I find some
> time, I'll try without it.
> 

I tried without loading modxslt and I still cannot reproduce the problem that
you see: no errors in the apache log and everything shows up as it should.

Nick

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: xml statement in html and apache error
  2011-04-07  9:18   ` Richard Riley
  2011-04-07 14:00     ` Nick Dokos
@ 2011-06-26 18:15     ` David Maus
  1 sibling, 0 replies; 6+ messages in thread
From: David Maus @ 2011-06-26 18:15 UTC (permalink / raw)
  To: Richard Riley; +Cc: nicholas.dokos, Emacs-orgmode mailing list

[-- Attachment #1: Type: text/plain, Size: 3228 bytes --]

At Thu, 07 Apr 2011 11:18:27 +0200,
Richard Riley wrote:
>
> Nick Dokos <nicholas.dokos@hp.com> writes:
>
> > Richard Riley <rileyrg@googlemail.com> wrote:
> >
> >>
> >> I cant really give too many details or suggestions as to why it failed,
> >> but the default xml string at the top of export to html files was
> >> causing apache to fail.
> >>
> >> ,----
> >> | Parse error: syntax error, unexpected T_STRING in
> >> | /home/shamrock/common-files/webs/richardriley.net/projects/emacs/index.html
> >> | on line 1
> >> `----
> >>
> >> I simply removed the html xml declaration,
> >>
> >> ,----
> >> | org-export-html-xml-declaration is a variable defined in `org-html.el'.
> >> | Its value is
> >> | (("php" . "<?xml version=\"1.0\" encoding=\"%s\"?>"))
> >> `----
> >>
> >
> > This looks wrong (even though unrelated to the problem): in my setup I get
> >
> >
>
> You're right. Was late at night. I pasted the wrong value. The working value
> is
>
> ,----
> | org-export-html-xml-declaration is a variable defined in `org-html.el'.
> | Its value is
> | (("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
> `----
>
> That other value was in my scratch buffer from trying to debug the
> situation. Note, I dont export to php, only html (currently).
>
> >
> > org-export-html-xml-declaration is a variable defined in `org-html.el'.
> > Its value is
> > (("html" . "<?xml version=\"1.0\" encoding=\"%s\"?>")
> >  ("php" . "<?php echo \"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\" ?>\"; ?>"))
> >
> >
> >
> > so deleting the html entry should leave you with the second line. You seem
> > to have a mash of the two entries instead.
> >
>
> Sorry! Mea culpa there in my "bug report".
>
> >> reexported my private little web, reloaded apache and all was
> >> well. Which was cool considering I hadnt exported it from the org data
> >> for all of about 2 years!
> >>
> >> Far from thought out, almost certainly not "correct" I am sure, but got
> >> my web back working.
> >>
> >> Possibly someone else can comment on cause/effect.
> >>
> >
> > Well, I exported a toy project and despite the presence of the xml headers,
> > my apache is not complaining at all. I also spot-checked a couple of files
> > on orgmode.org and they have the xml header, but apache seems to deliver
> > them without a problem. Which version of apache are you running? Mine is
> > 2.2.16.
>
> Two machines, both with Debian Squeeze.
>
> ,----
> | Server version: Apache/2.2.16 (Debian)
> | Server built:   Mar 22 2011 20:56:31
> `----
>
> >
> > Nick
> >
> > PS. The exercise also uncovered an org bug but I'll post that as a
> > separate message.
> >
>
> Let me re-run the scenario and check my publish parameters - its really
> been a LONG time since I published but something changed with
> apache. Both machines are relatively new installs. Possibly something
> third party needs to be instaled on squeeze now to get xml statements
> parsed? A google was not so helpful.

Not sure if you have fixed this problem but

Parse error: syntax error, unexpected T_STRING in on line 1

Was/is an error of the PHP processor.

Best,
  -- David
--
OpenPGP... 0x99ADB83B5A4478E6
Jabber.... dmjena@jabber.org
Email..... dmaus@ictsoc.de

[-- Attachment #2: Type: application/pgp-signature, Size: 230 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2011-06-26 18:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-07  3:36 xml statement in html and apache error Richard Riley
2011-04-07  4:48 ` Nick Dokos
2011-04-07  9:18   ` Richard Riley
2011-04-07 14:00     ` Nick Dokos
2011-04-07 17:52       ` Nick Dokos
2011-06-26 18:15     ` David Maus

Code repositories for project(s) associated with this inbox:

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).