Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Something somewhere before session start and session regenerate id is putting something on the page. If you are sure you're not echoing or printing anything to the page, it's probably a blank space at the top of one of the files. </p> <p><strong>EDIT 1</strong></p> <p>Some text editors/word processors save files with extra invisible characters at the top due to encoding. Try copying and pasting the text of the files into new files in a plain text editor or text editor recommended for coding, such as Notepad++.</p> <p><strong>EDIT 2</strong></p> <p>So, those were the most likely solutions.... It says </p> <pre><code>output started at /home2/mysite/public_html/mysubsite/index_3.php:7 </code></pre> <p>which means that it's line 7 of index_3.php where the output starts at. There is probably a space there or maybe some kind of error that causes output to be sent.</p> <p>If you really can't find that invisible output, you can use buffering with <a href="http://php.net/manual/en/function.ob-start.php" rel="nofollow">ob_start</a> etc. to catch all output. Put ob_start before your session start and use ob_end_flush later to display the page. But that's not a real fix for the fact that you're sending output without knowing it.</p> <p><strong>EDIT 3: "No output" includes any and all HTML.</strong> </p> <p>If there's something in any file that is not inside PHP brackets &lt;?php ?&gt; then that counts. Your index_3.php file starts with HTML. That is output. You have to do get_opwire.php first.</p> <p><strong>EDIT 4</strong></p> <p>Concerning how get_opwire.php has both page-start stuff and the table printout, it's an example of why it's a good idea to separate your display code from your functionality code. You have three options:</p> <ol> <li>Have separate files. You would have a file like page_start.php that does includes and session_start that you include at the very top of index_3.php, and a file like display_table.php that displays your table that you include where the table goes. </li> <li>Turn the table into a function. You would wrap the table output inside a function, include get_opwire.php at the very top of index_3.php, then call the function down where you want the table. </li> <li>Use output buffering. Output buffering catches the stuff printed out so that you can use it later. It would go like this:</li> </ol> <p>top of index_3.php:</p> <pre><code> ob_start(); include get_opwire.php; $table = ob_get_contents(); ob_end_clean(); </code></pre> <p>where the table goes:</p> <pre><code> echo $table; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload