tag:help-archives.hannonhill.com,2010-02-09:/discussions/how-do-i/9881-fix-a-php-header-issue-with-the-cascade-calendarCascade CMS: Discussion 2013-12-20T21:11:46Ztag:help-archives.hannonhill.com,2010-02-09:Comment/306718012013-12-20T13:13:09Z2013-12-20T13:13:09ZFix a php header issue with the Cascade Calendar<div><p>Hi,</p>
<p>Thank you for using the Calendar site, we hope you are finding
it to be a useful resource.</p>
<blockquote>
<p>Warning: Cannot modify header information - headers already sent
by</p>
</blockquote>
<p>This error message is typically caused when content it outputted
before a <code>header()</code> call is made. When you have a
moment, can you attach the <strong>index.php</strong> file to this
discussion so I can take a closer look at how the PHP and HTML is
organized.</p>
<p>Thanks!</p></div>Ryan Griffithtag:help-archives.hannonhill.com,2010-02-09:Comment/306718012013-12-20T18:35:10Z2013-12-20T18:35:10ZFix a php header issue with the Cascade Calendar<div><p>Thank Ryan,</p>
<p>The code is actually quite complicated, so I wouldn't ask you to
go through it. We are including php to add our "global menu" to the
top of the page, and there are cookies being added with that.</p>
<p>My question should have just been... are there cookies or other
header data being added within the Cascade Calendar? If there
aren't, then the issue is internal and has nothing to do with the
Calendar and we can look into it on our end further.</p>
<p>Thanks,</p>
<p>Blair</p></div>bkbrookstag:help-archives.hannonhill.com,2010-02-09:Comment/306718012013-12-20T18:49:31Z2013-12-20T18:49:31ZFix a php header issue with the Cascade Calendar<div><p>Hi Blair,</p>
<p>Thank you for following up.</p>
<blockquote>
<p>are there cookies or other header data being added within the
Cascade Calendar? If there aren't, then the issue is internal and
has nothing to do with the Calendar and we can look into it on our
end further.</p>
</blockquote>
<p>The Calendar is all client-side with JavaScript and does not add
any cookie or header information. One thing to note; however, is
that some Configuration Sets have an XSLT Format being applied to
them after the page is rendered. This can sometimes result in code
section comment tags being encoded (eg <code><</code> becomes
<code>&lt;</code>). You may want to check the generated HTML
within Cascade's page preview frame to make sure everything looks
in order prior to publishing.</p>
<p>Please let me know if you have any questions.</p>
<p>Thanks!</p></div>Ryan Griffithtag:help-archives.hannonhill.com,2010-02-09:Comment/306718012013-12-20T20:07:45Z2013-12-20T20:07:45ZFix a php header issue with the Cascade Calendar<div><p>Thanks for your help Ryan,</p>
<p>I actually tracked down the issue. It looks like there ARE some
headers or something being added in one of the formats for the
calendar, and it seems to be in the region called "FULL CALENDAR
SCRIPTS". I removed that region (which contains the format "full
calendar script") and then I was no longer getting the error.
Obviously this stopped the calendar from showing up at all.</p>
<p>However, I decided to try and put that region at the bottom of
the page instead of the top of the page, and voila! The error
stopped happening and the calendar started showing up
correctly.</p>
<p>Here's the working calendar within our template now. It still
needs some style tweaking, but it's getting there:<br>
<a href=
"http://www.uvic.ca:8080/research/centres/capi/calendar/">http://www.uvic.ca:8080/research/centres/capi/calendar/</a></p></div>bkbrookstag:help-archives.hannonhill.com,2010-02-09:Comment/306718012013-12-20T21:11:44Z2013-12-20T21:11:44ZFix a php header issue with the Cascade Calendar<div><p>Thank you for following up, Blair.</p>
<p>Correct, there is a region within the <code><head></code>
that outputs the full calendar's JavaScript. So it sounds like this
was messing with your PHP. I am glad to hear moving the region to
the bottom helped out.</p>
<p>Not sure if this would help you out here, but there's <a href=
"https://github.com/hannonhill/Calendar/releases/tag/v7.6.x">actually
a newer release of the Calendar</a> that has some overhauling,
including outputting the JavaScript at the bottom of the page.
Note: this version does require you to be running Cascade Server
7.6+.</p>
<p>I'm going to go ahead and close this discussion, but please feel
free to comment or reply to re-open if you have any additional
questions.</p>
<p>Have a great day!</p></div>Ryan Griffith