FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Writing double-prime to file?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Writing double-prime to file? [message #184780 is a reply to message #184775] Sat, 01 February 2014 12:40 Go to previous messageGo to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 2/1/2014 6:37 AM, Adrian Tuddenham wrote:
> I am trying to write a series of programs which create a file from a
> string which has been Copied from a spreadsheet. It is Pasted into an
> HTML Form and passed through various checking routines. Finally it is
> written to a file.
>
> If the string contains a double-prime character (double quotes) the
> character and the rest of the string after that point do not appear to
> be written to file.
>
> The program displays the string just after the "write to file" lines
> and it is still unchanged. Either a problem is occurring during the
> writing phase or that character is making the rest of the file
> unreadable. (I view the file contents in Fetch v3.0.3)
>
> The data string is held in the variiable '$txt' and the write command
> is:
>
> ~~~~~~~~
> $fh = fopen($fileURL, 'w') or die("<FONT
> COLOR=\"#CCFFFF\"><B>PayFileGen2 can't open file $fileURL</B></FONT>");
> fwrite($fh, $txt);
> fclose($fh);
>
> ~~~~~~~~
>
> Is that character known to cause a problem and is there a
> straightforward way around this?
>
>

I've never seen a problem writing double quotes to a file. What does
the file look like if you open it with an editor on the server (or, more
simply, just list it to the terminal) instead of retrieving it with an
ftp program?

--
==================
Remove the "x" from my email address
Jerry Stuckle
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Phonegap upload issue with PHP server
Next Topic: RE: Seeeking Windows PHP IDE for USB Stick
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 20:23:32 GMT 2024

Total time taken to generate the page: 0.04158 seconds