You are here: Re: Pre global configuration « PHP « IT news, forums, messages
Re: Pre global configuration

Posted by "A.J. Brown" on 09/27/05 18:20

It seems the best way to do this would be a predefined constant. You'd just
need to update the constant whenever you move to a new Operating System.
Then, just always append the constant to your strings:

//change for linux or windows
define('CRNL',"\r\n);
//define('CRNL',"\n);

print "foobar".CRNL;


--

Sincerely,

A.J. Brown



"Jake Gardner" <gardner.jake@gmail.com> wrote in message
news:d8a4abc10509270740d95d6c@mail.gmail.com...
This is a stretch and I doubt you can do this very easily, but I was
wondering if there is a way to define behaviors that happen throughout
a script before execution for example if the OS is windows, all
strings are terminated with \r\n, if Linux, then \n without adding
addition ifs throughout the code.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация