SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Enthusiast
    Join Date
    Aug 2008
    Posts
    49
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How do I get rid of the "¬" character that I'm getting in the output of my php code?

    I'm adding text to a very simple PHP site, and for some reason, it's adding an "¬" at the end of some words in the text. There does not seem to be a pattern as to when it adds it, but maybe you can see one that I'm not seeing, as although I know HTML, I am a novice at PHP.

    Here is an excerpt of the coding:

    PHP Code:
    <div>ABOUT OUR AMAZING VOLUNTEERS</div>
    <
    br />
    <
    div>It's only right to add here that*several traveled hundreds of miles to Volunteer.</div>
      <div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Chuck Bramwell,*our Leader of California Triple Crown & Frank Neal the Stat*Man*for CTC</div> 
    And here is the results that you see on the web page in a browser:

    ABOUT OUR AMAZING VOLUNTEERS

    It's only right to add here that¬ several traveled hundreds of miles to Volunteer.
    Chuck Bramwell,¬ our Leader of California Triple Crown & Frank Neal the Stat¬ Man¬ for CTC
    Suggestions?

    UPDATE: I just noticed that when I copied and pasted the code into this post, it added an "*" in the same place where the "¬" was added in the output, even though, in the code, neither an "*" or an "¬" appeared. So I went back to the code, and even though I didn't see an "*" or an "¬", I deleted that space and hit the spacebar to replace the space, saved it, refreshed the page and VOILA! The ¬ is gone! Not sure what happened, but I'm glad it was an easy fix.

  2. #2
    Non-Member mali28's Avatar
    Join Date
    Nov 2006
    Posts
    19
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BBCMember View Post
    I'm adding text to a very simple PHP site, and for some reason, it's adding an "¬" at the end of some words in the text. There does not seem to be a pattern as to when it adds it, but maybe you can see one that I'm not seeing, as although I know HTML, I am a novice at PHP.

    Here is an excerpt of the coding:

    PHP Code:
    <div>ABOUT OUR AMAZING VOLUNTEERS</div>
    <
    br />
    <
    div>It's only right to add here that*several traveled hundreds of miles to Volunteer.</div>
      <div>**********Chuck Bramwell,*our Leader of California Triple Crown & Frank Neal the Stat*Man*for CTC</div> 
    And here is the results that you see on the web page in a browser:



    Suggestions?

    UPDATE: I just noticed that when I copied and pasted the code into this post, it added an "*" in the same place where the "¬" was added in the output, even though, in the code, neither an "*" or an "¬" appeared. So I went back to the code, and even though I didn't see an "*" or an "¬", I deleted that space and hit the spacebar to replace the space, saved it, refreshed the page and VOILA! The ¬ is gone! Not sure what happened, but I'm glad it was an easy fix.

    It seems like you have a virus in your PC. Please scan your PC with a good antivirus software.

  3. #3
    SitePoint Enthusiast
    Join Date
    Aug 2008
    Posts
    49
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mali28 View Post
    It seems like you have a virus in your PC. Please scan your PC with a good antivirus software.
    Thanks for your suggestion, but I have a Mac, for which there have been no known viruses written. I think it was caused by copy and pasting the code from one program to another instead of typing it in manually.

  4. #4
    Non-Member mali28's Avatar
    Join Date
    Nov 2006
    Posts
    19
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can try adding following code in the <head> tag of your web page:

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">

  5. #5
    SitePoint Enthusiast
    Join Date
    Aug 2008
    Posts
    49
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mali28 View Post
    You can try adding following code in the <head> tag of your web page:

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    Thanks. I've already fixed it via the above method, but I'll keep that in mind for the future.

    Here is what is currently in the <head> tag of that page:

    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252" />

  6. #6
    SitePoint Wizard silver trophybronze trophy Cups's Avatar
    Join Date
    Oct 2006
    Location
    France, deep rural.
    Posts
    6,869
    Mentioned
    17 Post(s)
    Tagged
    1 Thread(s)
    This subject came up a few times over the last week or so, try following some of the links in this post.

    http://www.sitepoint.com/forums/show...ian-characters

  7. #7
    Keeper of the SFL StarLion's Avatar
    Join Date
    Feb 2006
    Location
    Atlanta, GA, USA
    Posts
    3,748
    Mentioned
    69 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BBCMember View Post
    Thanks for your suggestion, but I have a Mac, for which there have been no known viruses written.
    While strictly true, 'virus' is too narrow a definition. When people say "there have been no known viruses"... the caveat that you dont often get to read is "excluding worms, trojan horses, spyware, adware, or spam, because they arn't viruses". Inqtana-A (worm). RSPlug (trojan). Lamzev (trojan). iBotNet (trojan botnet). MacSweeper (adware/spyware). Pwn2Own (classed as a 'browser vulnerability', it broke Safari's security in less than 10 seconds...). All arnt 'viruses', but they can still infect macs.

    Antivirus software exists on macs for a reason. Malicious code for macs has existed for years - the examples above come from 2005-2009 alone, and are by no means an exhaustive list. Do not assume you are immune.
    Never grow up. The instant you do, you lose all ability to imagine great things, for fear of reality crashing in.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •