vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Can I get DoOutput to not send header? (https://vborg.vbsupport.ru/showthread.php?t=38034)

JoeHarrison 04-29-2002 06:53 PM

Can I get DoOutput to not send header?
 
I am trying to intigrate something with vB, but my headers are being sent twice. (I get something like "Warning: Cannot add header information - headers already sent") I think the headers are being sent by the initial PHP script and again at the end of the program when I call dooutput.

It looks like there is attribute to not send the headers, but I can't seem to get it to work. Here is what I tried:

PHP Code:

eval("dooutput(\"".gettemplate('new_test')."\",0);"); 

If someone could help me out it would be greatly appriciated.

Thanks,
Joe

JoeHarrison 04-29-2002 07:03 PM

Never mind!

I had it right all along!!! I made that change that I had above... and then I uploaded it to the WRONG PLACE!!! So when I tried to run it, it just kept being the old one. Can you believe it?

JoeHarrison 04-29-2002 07:40 PM

OK well, I just tried it again and now it dosn't work again! And I DID upload it correctly. I am getting that "Header Cannot be Sent" error.

Admin 04-30-2002 06:22 AM

Paste the full error here. The headers are probably sent from a different place.

JoeHarrison 04-30-2002 05:19 PM

FireFly,
Here is the full error:
Quote:

Warning: Cannot add header information - headers already sent by (output started at /home/harrison/public_html/newheader/test.php:11) in /home/harrison/public_html/forums/admin/functions.php on line 1545
The weird thing is... this worked fine about an hour ago. No error at all. I cam back and tried it again and I get an error. Is the header automatically sent when I include global.php?

Thank you,
Joe

Admin 05-01-2002 09:56 AM

That line in functions.php sets a cookie, which is just like sending headers (it's exactly like it).

What line 11 of test.php and why are you printing stuff there?

JoeHarrison 05-01-2002 06:27 PM

1 Attachment(s)
FireFly,

First I'll try to explain what I am trying to do. I recently installed vbIndex by el3m3nt to be used for the main page when people come to my site. However, for the non-vb pages of my site, I wanted to include the poll that is used on the vbIndex page. So, I copied the poll section of vbIndex (originally written by wajones) and put it into it's own php file (attached). I replaced the eval's at the bottem with eval dooutput's. Now, I am trying to include this file within the non-vbpages of my site. Sometimes, this works without any problems (like now)... other times, it gives me the error. Here is my test link: http://www.joeharrison.com/newheader/test.php

This file has the follwing to include poll.php:
PHP Code:

<?php include "/home/harrison/public_html/forums/joe_poll.php" ?>

Thank you,
Joe

Admin 05-01-2002 06:49 PM

I'm not sure about this, it's hard without seeing how your whole site is built and using the vB engine, but anyway: Try sticking [minicode]$noheader=1;[/minicode] in poll.php right before you require global.php. It should solve the problem if it's what I'm thinking it is. :)

JoeHarrison 05-02-2002 02:26 AM

FireFly,

I havn't gotten that error again but I'll try what you suggested if I do. Thanks very much for your help. I'm really looking forward to the release of vbHome Full by nakkid ... it should make site intigration much easier!

Thanks again,
Joe

PS. You're no longer the president? haha (new avatar)

Mark Hensler 05-02-2002 05:31 AM

Que pasado al presidente?!
*pánico*
Es él muerte?


All times are GMT. The time now is 12:35 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01015 seconds
  • Memory Usage 1,732KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete