Php Escaped Control Characters And Windows - they aren't working for me.

free web hosting
Open Discussion > CONTRIBUTE > Computers > Programming Languages > PHP Programming

Php Escaped Control Characters And Windows - they aren't working for me.

jlhaslip
In php coding, when you escape certain characters, they have an impact on the output of an echo'd or printed string. ie "\r\n\t" should give you a new line and a tab before outputting the content for a line of printing. They vary by OS, I know, but I have tried all the variations I can think of and can't seem to control output using them.
Believe me, I have tried multiple variations and nothing works for me.

I have checked the php.ini file for settings but I can't find where you can modify them.

So the question is :

Where do i look to confirm the settings for using these Control Characters in the php parser or config files?

Anyone know? And thanks in advance.

Reply

Spectre
What exactly are you trying to output, and what are you trying to view it in? A web browser simply ignores newlines for formatting in an HTML document, generally treating them simply as a space. Try setting the Content-Type header to text/plain or using the preformatted tag (<pre>), or just add a '<br>' to your string.

Reply

jlhaslip
I hate steortypes, but I was having a 'blonde' moment there.
Thanks, Spectre.
*kicks self*

Reply

vujsa
If that was the answer, I so totally didn't understand the question. The special characters are used for formating text only. They are generally used in PHP to format the outputed HTML like so:

This PHP:
CODE
echo "<body>\n\t<table>\n\t\t<tr>\n\t\t\t<td>\n\t\t\t\tContent Here!<br />\n\t\t\t\tMore content here!\n\t\t\t</td>\n\t\t</tr>\n\t</table>\n</body>";


Would output this HTML:
CODE
<body>
    <table>
        <tr>
            <td>
                Content Here!<br />
                More content here!
            </td>
        </tr>
    </table>
</body>


Which after the browser displays it would look like this:
QUOTE
Content Here!
More content here!


I use this to format my HTML in a way that makes it more organized and easier to read later. Makes debugging much easier.

This is also used for line breaks and tabs in the HTML textarea object.

Hope this helps. cool.gif

 

 

 


Reply



Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

(Maximum characters: 10,000)
You have characters left.

Recent Queries:-
  1. php preg_match windows illegal folder characters - 79.67 hr back. (2)
  2. php5.3 phpinfo.php - 141.63 hr back. (1)
Similar Topics

Keywords : php, escaped, control, characters, windows, arent, working

  1. Windows Version History
    (2)
  2. The Best Uninstaller For Windows (42.5 Kb Only!)
    It is the most small and the most complete uninstaller. (6)
    Name of the tool - MyUninstaller Version - v1.42 Homepage: Nirsoft Description: This is a very
    small utility, just like the add/remove programs that comes installed with the windows 2000/xp
    operative systems, but this program is the best, i know because i have been using it for quite some
    time now, at least a year of uninstalling applications, and it works perfectly. Screenshot:
    An utility like this, that you do not have to install it, that it has only 42.5 kb, that you just
    need to double click it and to create a shortcut in your desktop to use whenever you....
  3. Is It Possible To Edit Windows Registry?
    (11)
    i have just started learning c++. i am currently using turbo c++.is it possible to edit windows
    registry in c++(not vc++). i am just a beginner . would be glad if you gave examples.....
  4. Windows Xp Sp2 Restarting After Some Time
    (6)
    Hi , I dont know what happened but My system restarts after a few Minutes (at max an hour). Can
    someone guess what might be wrong. It displays a System Shutdown Timer (initiated by
    Administrator) and then restarts after 60 sec. This is an SP2 so I dont think its a blaster. I
    have a ZoneAlarm Security Suite and it didn't detect anything. I even Scanned my Windows folder
    from Kaspersky using my Second OS (Vista) but that also didn't detect anything . .. Any guesses
    ??....
  5. Reclaim Control Over Your Windows-based Pc
    Part 1 (2)
    QUOTE Important This tutorial contains steps that tell you how to modify the registry.
    However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure
    that you follow these steps carefully. For added protection, back up the registry before you modify
    it. Then, you can restore the registry if a problem occurs. For more information about how to back
    up and restore the registry, click the following article number to view the article in the Microsoft
    Knowledge Base: 322756 How to back up and restore the registry in Windows ....
  6. Access Control
    (4)
    I'm going to make a PHP called add.php?item=example&price=999, that will an item and price to a
    database. I plan to access this page via an external program, but I don't want users to be able
    to add things into the database. I've thought about using cookies to restrict access, but they
    can just look at the headers being sent and imitate that cookie. I've also thought about
    encrypting, which will make it a little harder. Is there an even better way to solve this?....
  7. Creating A Shortcut List Near The System Tray
    Time saver tip for windows (4)
    Are you bored at work today? Here's a small enhancement to your desktop. Hope you like it. I)
    When you have to open any program you have to click "Start" "All Programs" and then choose your
    selection from the programs folder. Now how would it be to achieve the same task in just two clicks?
    You can save all your favourite program shortcuts in a folder and view that through a tiny arrow
    near the system tray. Its very simple. You would tell, "Ya, I almost knew that". Here's how to
    do it. a) First create your folder and add the shortcuts you want to access. The f....
  8. What Is Winpe?
    An introduction to the Windows Preinstallation Environment (4)
    Ever wish that you could legally install an operating system that is as familiar as Microsoft
    Windows, without having to learn the arcane intricacies of Linux, and without having to pay the
    exorbitant licensing that Micro$oft charges? Did I mention doing it legally ? I don't
    mean making use of any form of keygen, serial, crack, etc. Is this possible? How many old Pentium 2
    systems with 64MB of RAM and an 8GB hard drive got stuffed into your back cupboard without an
    operating system license when Microsoft brought in the Microsoft Genuine Advantage program? W....
  9. Windows Vista Installation Fails
    (3)
    Hello. I tried Installing Windows Vista Home Premium today, but when it comes to the part
    of the Installation where it says "Your computer will restart several times" my computer restarts
    more then 40 times, and never loads after that. After like, 10-15 minutes of it being off, I switch
    it back on, and it restores to XP (Witch is good because it wouldn't start up at all). I've
    tried installing this 4 times altogether, and nothing. it keeps restarting continuously more then 40
    times. The only time it restarts is after the BIOS loads, when switching/restar....
  10. How Many Times Do You Reinstall Windows In A Year
    There goes some useful tips about it. (19)
    I reinstall (restore) windows almost every 2-3 months. What about you??? Seeing the title some would
    say "I do it daily" and some others "How to reinstall?". Let's see the poll results. Linuxers,
    see you in other post. Reinstalling windows is a daily chore for the students studying computers.
    They have to switch a lot of softwares, compilers etc etc. Windows as we know, will not tolerate a
    whole lot of (Un)installations and will ultimately slow down the whole system. This is not the case
    with Linux. Just consider this, I installed Red Hat WS 3(the older version whi....
  11. Its's Official Microsoft Is Done With The Windows Operating System
    (13)
    Wow and I thought this one website was joking around that Microsoft plans to do one more Windows
    Operating. I don't know if Windows 7 will be the last one or not but the project goes by the
    code name Midori and it is based on the Cloud computing concept, which by the way Dell is trying to
    copyright this name for. All I know about cloud computer is that it will be internet based
    operating system meaning that buying CD's based software could end. Heck we are already seeing
    it in which yo ucan download full license software without hte use of a CD (legally). Rig....
  12. Windows Xp: Explorer.exe Crashes On Certain Accounts
    (5)
    I share a Windows XP computer with two friends, and we each have our own User Account on the
    computer. Recently whenever my friends use the PC, they begin to have problems with it. For no
    reason whatsoever, Windows Explorer will crash and close all the current folders that are open. I
    went onto their User Accounts to see for myself (with permission, of course), and found that
    Explorer would crash any time I right-clicked a File, and would also crash on occasion if I clicked
    "File" on the Folder Window's Menu Bar with a file selected. It also happened on rare occasion....
  13. Windows 7
    (3)
    One year after the official Vista release , Microsoft is already working on the next Windows
    operating system , Windows 7 , also known as Blackcomb or Vienna . Windows 7 Milestone 1 Build 6519
    , the first working version of windows 7 , has already leaked to the w a r e z community , but it
    doesn't differs much from Vista . The release is set for late 2009 / 2010 . So what do you think
    about Windows 7 . Of course that the work on Vista continues , as it's not yet perfect but will
    soon be.....
  14. Help For My Seagate Sata Hard Drive!
    hard drive stops working randomly, please help! (9)
    I just bought that disk (seagate SATA 500G) half year ago and found it stop working randomly,
    resulting the whole system to be dead. BTW, I am using Win XP. I tried to use seatool, provied by
    seagate, to scan and repair the error, the program stop at the half of the process. I even can't
    format entirely, just do quick format. I don't know what I can do and have been pissed off for a
    few days. hope some people have this kind of experience and give me any idea. I don't want to
    loss my 500G data storeage. thanks in advance.....
  15. Diabetes And Insulin Pump Therapy
    Discussion on diabetes control (5)
    I wanted to make this a Subforum but didnt know how so I posted this here. I have been a diabeteic
    for about 25 yrs. I am now on the inslin pump which seems to be working well. I was basically
    wanting to know if there are otheres diabetices that use the pump or discuss any other ways others
    could share to help other diabetices control ther sugar levels.....
  16. How Do I Change The Default Windows Font Size?
    Without changing DPI, of course. (5)
    I know there's an option in Ubuntu to change all the font sizes of the general system, the
    windows, and etc. Now I'm trying to do this in Windows. I've changed everything about
    the windows except for the general system size. How do I do this?....
  17. Birth Control Recommendations?
    (10)
    Everything in my gut (and coming from my doctor) tells me I really need to stick to a birth control
    pill, but during my one month experience on it I began feeling depressed and decided to quit.
    I'm assuming the hormone in-balance was too much for my body to handle, and many of my peers
    told me to wait it out for another couple months to see what would happen. Is there anyone with
    similar experience that has found a pill that works for you that did not affect you in that way?
    Or just generally what have you found to be a successful method of birth control?....
  18. Linux Or Windows Hosting Os?
    (9)
    Okay i recently bought a godaddy hosting account. Now my question is whats the difference between
    the Linux OS hosting, and the Windows OS hosting?....
  19. Disabling Safe Boot On Windows Xp
    Learn how to do it (3)
    I know that there has been many at times, when for some reason or the other, people would want to
    disable the ability of Windows XP to boot into safe mode. Even though that this is not a very thing
    advisable thing to do, but still, people, due to some reasons best known to them would always want
    to do this. The other day, a friend of mine who works in (manages is the right word) a cyber cafe
    was heads over toes, trying to figure out to to disable the safe mode boot in Windows XP. His
    reason..... customers are hacking into their computers and browsing free of charge by b....
  20. Sonic Style Characters/drawing Requests
    (2)
    Can anybody tell me some websites that have to get some sonic style charries or if anybody is any
    good at drawing their own charcaters like this one for instance... ....
  21. Wmp (windows Media Photo) - The New Image File Format From Microsoft
    windows media photo WMP - could replace JPGs and GIFs? (33)
    Microsoft have decided to come up with a new image format to add to the common JPGs, GIFs and PNGs
    of today. It is to be called Windows Media Photo format or WMP for short. It is said to
    "Surpass the limitations of existing file formats" and here is what it'll offer: Numerous
    colour formats for printing and displaying High-quality lossy or even lossless compression
    Really efficient decoding for numerous resolutions For more features, visit
    http://www.microsoft.com/whdc/xps/wmphoto.mspx Presumeably, the JPEG2000 format or JP2 was
    ....
  22. Windows Xp Clock
    (3)
    How can I make the clock in the system tray display seconds as well as hours and minutes?....
  23. Slow Connection With Linksys Wrt54g Router
    working fine until few months ago (8)
    Hey there everybody! I need some help. Here's the problem. I have a Linksys Wireless WRT54G
    v5 router, which, I think, is acting up. First of all, I can't get port forwarding to work!
    About three month ago my port forwarding was working flawlessly, I could use download clients like
    DC++, or BitComet, or have an ftp server running, etc... Now, whichever ports I use, nothing seems
    to work. Plus, in clients like DC++ where you're connected to several hubs, the connection to
    the hubs is constantly dropped. On top of that, the joke's on me actually....
  24. Ipod Not Working, Need Help
    (20)
    Not sure if this is the right forum, but I didn't see anywhere else for it... Ok, my girlfriend
    got a 4 GB iPod Nano about a month ago. She had about 100 songs on it and one day they just
    disappeared. Her normal PC won't recognize that she has the iPod plugged in, and her
    stepdad's laptop will recognize it... But after she transfers all the songs, and she unplugs the
    iPod from the laptop, she loses all of her songs again... She talked to an apple guy, but they said
    she needed to do a system restore on it, but they didn't tell her how... And she can't ....
  25. Is There An Adium-like Im Client For Windows?
    (19)
    Recently I've been getting sick of connecting to so many accounts on so many different clients.
    It's troublesome to maintain so many accounts/programs. I liked using Trillian for a while but
    it took too much processor memory and it can't connect to Skype or Googletalk (which I
    haven't downloaded, but will do so when I find a suitable Adiumlike program). Does anyone know
    of an IM client which supports all the major IM protocols? That would be MSN, Yahoo, AIM,
    Jabber/Google (well, Skype too but I guess it's optional). I've looked around the plac....
  26. Mice With Only One Botton At Apple, Finished.
    Compatibility with: MacOS X & windows. (20)
    - I am going to tempt to wake up the memory of oldest among you. You remember
    the exit of the first Macintosh, at Apple . How could you have forgotten this funny mouse,
    "innovante" for the time, dressed of only one thick button on its superior part, who produced a
    small particular click (whose sound reasons again in my ears)? This revolution
    that Apple had introduced in the world of the data processing has the house was going to become the
    contraption of your daily, and to arrange itself as a matter of course to quote them of th....
  27. Windows Xp Freezes At Welcome Screen
    (41)
    today i start my pc in windows xp and found that xp freezes at welcome screen. then i try to boot in
    safe mode but the problem persisits then i again try in last good configuration setting but it
    doesn't help so i hav to reinstall my xp plz any body hav solution for this so that i do not hav
    to reinstall my xp for this problem as i get this problem oftenly. thanks....
  28. MCP Windows XP exam dumps
    (9)
    I am planning to take Microsoft certification exam (70-270) on Windows XP for an MCP. I already have
    some dumps with me but not sure about its correctness. Does anyone have a new TestKing dumps? It
    will be a great help if you can email me them... My email is vineethmohan@gmail.com....
  29. Windows Xp And Dos Multiboot
    how?? (10)
    Question to you all, I have a computer running windows XP, now I want to add a "real" DOS
    enviroment on the computer (not cmd or dosbox or something like that). So I thought dualboot will
    do the trick, but the problem is, if I go on and install dos on my free harddisk, I will have a
    problem cause it f*cks up my boot process and windows xp will not start anymore. That I dont
    want! Anyone got an idea on how i can install dos so I can multiboot between windows xp and dos
    without formatting my windows drive, install dos and then reinstall windows? Any help would be gr....
  30. Windows Nt Therapy Institute
    (2)
    /laugh.gif' border='0' style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0'
    style='vertical-align:middle' alt='laugh.gif' /> /laugh.gif' border='0' style='vertical-alig....

    1. Looking for php, escaped, control, characters, windows, arent, working

*RANDOM STUFF*





*SIMILAR VIDEOS*
Searching Video's for php, escaped, control, characters, windows, arent, working

*MORE FROM TRAP17.COM*
Similar
Windows Version History
The Best Uninstaller For Windows (42.5 Kb Only!) - It is the most small and the most complete uninstaller.
Is It Possible To Edit Windows Registry?
Windows Xp Sp2 Restarting After Some Time
Reclaim Control Over Your Windows-based Pc - Part 1
Access Control
Creating A Shortcut List Near The System Tray - Time saver tip for windows
What Is Winpe? - An introduction to the Windows Preinstallation Environment
Windows Vista Installation Fails
How Many Times Do You Reinstall Windows In A Year - There goes some useful tips about it.
Its's Official Microsoft Is Done With The Windows Operating System
Windows Xp: Explorer.exe Crashes On Certain Accounts
Windows 7
Help For My Seagate Sata Hard Drive! - hard drive stops working randomly, please help!
Diabetes And Insulin Pump Therapy - Discussion on diabetes control
How Do I Change The Default Windows Font Size? - Without changing DPI, of course.
Birth Control Recommendations?
Linux Or Windows Hosting Os?
Disabling Safe Boot On Windows Xp - Learn how to do it
Sonic Style Characters/drawing Requests
Wmp (windows Media Photo) - The New Image File Format From Microsoft - windows media photo WMP - could replace JPGs and GIFs?
Windows Xp Clock
Slow Connection With Linksys Wrt54g Router - working fine until few months ago
Ipod Not Working, Need Help
Is There An Adium-like Im Client For Windows?
Mice With Only One Botton At Apple, Finished. - Compatibility with: MacOS X & windows.
Windows Xp Freezes At Welcome Screen
MCP Windows XP exam dumps
Windows Xp And Dos Multiboot - how??
Windows Nt Therapy Institute
advertisement



Php Escaped Control Characters And Windows - they aren't working for me.



 

 

 

 

ADD REPLY / Got an Opinion! a humble request :-) RAPID SEARCH! Free Hosting [X]
Express your Opinions, Thoughts or Contribute your information that might help someone here.
Ask your Doubts & Queries to get answers.. "Together, We enlight each other!"
Register FREE for AD-FREE forum, Create your own topics, Ask Questions, track topics, setup subscriptions & notifications and Get a Free Website w/ Email and FTP.
500MB Space *No Ads*, CPanel, FTP, PHP, MySQL, EMails - 100% FREE