+ Reply to Thread
Results 1 to 5 of 5

Thread: PHP Help Needed

  1. #1
    Christopher's Avatar
    Christopher is offline Retired Christopher is an unknown quantity at this point
    Join Date
    Jun 2006
    Location
    USA
    Posts
    7,330

    PHP Help Needed

    I have this odd thing appearing in some php code I'm using. Anyone know how to get rid of it? Below is what is appearing.

    Odd thing:


    Here is the code.
    PHP Code:
    <?php

    define
    ("IN_MYBB"1);
    define("KILL_GLOBALS"1);
    define("NO_ONLINE"1);

    // The Directory to the forum you are using this on. 
    // You do not need a beggining or trailing slash
    $directory_to_forum "forums"

    require 
    dirname(__FILE__)."/".$directory_to_forum."/global.php";

    $plugins->run_hooks("site_news_plugin_run");

    ?>
    Last edited by Christopher; 10-15-2007 at 07:45 PM.

  2. #2
    WoWChat is offline x10Hosting Member WoWChat is an unknown quantity at this point
    Join Date
    Oct 2007
    Posts
    62

    Re: PHP Help Needed

    O_O Sorry chou, I don't know what to tell you, I have never seen that before.

  3. #3
    flinx is offline x10Hosting Member flinx is an unknown quantity at this point
    Join Date
    Oct 2007
    Posts
    68

    Re: PHP Help Needed

    This piece of script doesn't output anything. The problem might be in this function:
    $plugins->run_hooks("site_news_plugin_run");
    Is it in global.php?

  4. #4
    Christopher's Avatar
    Christopher is offline Retired Christopher is an unknown quantity at this point
    Join Date
    Jun 2006
    Location
    USA
    Posts
    7,330

    Re: PHP Help Needed

    I don't need help with this anymore. I think it was something with the mybb plugin. I tried a different method and that wierd thing is gone.

  5. #5
    mattura's Avatar
    mattura is offline x10 Elder mattura is an unknown quantity at this point
    Join Date
    Oct 2007
    Posts
    563

    Re: PHP Help Needed

    Don't know how you solved it, but I can tell you what it was:
    a byte order mark (http://en.wikipedia.org/wiki/Byte_Order_Mark)

    It was probably the result of saving in UTF encoding using a microsoft editor such as notepad. They tend to put the mark at the start of the files even though it is not necessary.

    I had that problem when I tried to use some special characters in my webpages, changed everything to UTF-8 for multilingual character compatibility, resulting in your problem.

    It has nothing to do with your php code!

+ Reply to Thread

Similar Threads

  1. [PHP] Variables in PHP
    By Bryon in forum Tutorials
    Replies: 15
    Last Post: 01-29-2009, 09:46 AM
  2. tons of PHP Resources
    By Chris S in forum Scripts & 3rd Party Apps
    Replies: 10
    Last Post: 01-16-2009, 10:07 AM
  3. Unstand PHP?
    By o0slowpaul0o in forum Tutorials
    Replies: 8
    Last Post: 01-07-2008, 09:16 PM
  4. "PHP Startup: Invalid Library" - Interesting error
    By javaguy78 in forum Free Hosting
    Replies: 5
    Last Post: 03-27-2007, 02:33 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers