Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #11891
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!takemy.news.telefonica.de!telefonica.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail |
|---|---|
| Content-Type | text/plain; charset="UTF-8" |
| Message-ID | <2142920.u9UtNiUPjK@PointedEars.de> (permalink) |
| From | Thomas 'PointedEars' Lahn <PointedEars@web.de> |
| Reply-To | Thomas 'PointedEars' Lahn <php@PointedEars.de> |
| Organization | PointedEars Software (PES) |
| Date | Thu, 21 Nov 2013 21:27:39 +0100 |
| User-Agent | KNode/4.10.5 |
| Content-Transfer-Encoding | 8Bit |
| X-Face | %i>XG-yXR'\"2P/C_aO%~;2o~?g0pPKmbOw^=NT`tprDEf++D.m7"}HW6.#=U:?2GGctkL,f89@H46O$ASoW&?s}.k+&.<b';Md8`dH6iqhT)6C^.Px|[=M@7=Ik[_w<%n1Up"LPQNu2m8|L!/3iby{-]A+#YE}Kl{Cw$\U!kD%K}\2jz"QQP6Uqr],./"?;=4v |
| Face | iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAGFBMVEXTxa4RFk5dUWANED8PFEfy7+MGBiW+n3ZNF/QuAAACaElEQVQ4jVXUwVOcMBQG8Dc7Rc4PUntdWV2uxjDpGaGeozOp1woar4jd5t/v9wLstMwsA/ntlxdCAgUc1hjTc9/JCZfGoo3wG3HdmdAWrIJRHe7GM/TmpY5VFefuVcAkkPbLIaN8rmPmjloyZxgyR3GuJ4K0AGtJ2htz8o7yqikm759fldQXaMpbDzjKAG+8v+AugVTOPO5DOjLvGtUYQwh0CPjnVMyGd+8/GfUB5nLKJDD2aLDh5HYyMDJGDwQIo2ZmZcKbowNmAdB/AzyFhrmF2MHRb0QJJfaAnwGB6orZhoykLzJtGwF/xpYxI1dswomiUj3gTuAIqCn/4C7cULwGNBtwMTk3Y4LfKB5YUaOKBKYtpplm7u0vip8tU1NWWyI/7XdcSuIDoMt6rVHMWT0DbjHPGqDqZVSa6zleLcUTcIKLoMv3ueJluALtAo9B302zPPlrtiVScRdCjXvVh3e3JpYa/jjkuC9N+LrBMlz/eAN4eQijX2EdLo6c5tGGHwLyHFtXk89dDGHwCVhG9T0S/j55AhRZgkMCmUQXJ49TnS1wnQDvw0eAh9ICeMmEFbCnPMFzjAvsWoEWEFdYEx+S0MoUZ1gT1wId8+AF3Bl2OoEu906AUHx5VLw/gXYg/x84loOah/2UYNrgiwSwGO7RfUzVBbx/kgpckumGOi6QirtD6gkLTitbnxNol47S2jVc2vsN5kPqaAHT8uUdAJM4v/DanjYOwmUjWznGfwB7sGtAtor5BgofDuzaRj4kSQAqDakTsKORa3Q3xKi3gE1fhl71KRMqrdZ2AWNNg/YOhQyrVBnb+i+nEg4bsDA+egAAAABJRU5ErkJggg== |
| Subject | Re: PHP functions to convert markup efficiently |
| Newsgroups | comp.lang.php |
| References | <l6ljfj$fue$1@dont-email.me> |
| MIME-Version | 1.0 |
| Lines | 30 |
| NNTP-Posting-Date | 21 Nov 2013 21:27:40 CET |
| NNTP-Posting-Host | 9c607e85.newsspool2.arcor-online.net |
| X-Trace | DXC=FdV_Fj?am62lIh70@<QIE7A9EHlD;3Yc24Fo<]lROoR18kF<OcfhCO;9oB1OC=45T<DZm8W4\YJN<YUVHKH;GI^7FiG0>ad[_6;\0e1dDEd]M5 |
| X-Complaints-To | usenet-abuse@arcor.de |
| Xref | csiph.com comp.lang.php:11891 |
Show key headers only | View raw
James Harris wrote:
> I am looking for a way to mark up text in a way that PHP would be able to
> efficiently and quickly convert to HTML.
You are probably looking for a template engine like <http://www.smarty.net/>
then.
> […]
> For example, it looks like I could choose between PHP's expand(), fgets()
> and regular expression handling.
There is no built-in expand() function in PHP. fgets() reads files line by
line; HTML converts whitespace outside of attribute values to one space –
not what you want. Regular expressions are used for pattern matching; I do
not see how they would be applicable here.
> Of course, implemenations may differ slightly but, on average, are there
> certain PHP approaches that could be expected to be faster than others?
> What is the accepted wisdom?
Depends on what you *really* want to do.
PointedEars
--
realism: HTML 4.01 Strict
evangelism: XHTML 1.0 Strict
madness: XHTML 1.1 as application/xhtml+xml
-- Bjoern Hoehrmann
Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-21 18:30 +0000
Re: PHP functions to convert markup efficiently The Natural Philosopher <tnp@invalid.invalid> - 2013-11-21 18:39 +0000
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-21 18:57 +0000
Re: PHP functions to convert markup efficiently Christoph Michael Becker <cmbecker69@arcor.de> - 2013-11-21 20:10 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-21 19:29 +0000
Re: PHP functions to convert markup efficiently Christoph Michael Becker <cmbecker69@arcor.de> - 2013-11-21 21:18 +0100
Re: PHP functions to convert markup efficiently Salvatore <sal@yojimbo.hack.invalid> - 2013-11-21 19:03 +0000
Re: PHP functions to convert markup efficiently Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-11-21 21:27 +0100
Re: PHP functions to convert markup efficiently Arno Welzel <usenet@arnowelzel.de> - 2013-11-22 11:33 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-22 12:48 +0000
Re: PHP functions to convert markup efficiently Jerry Stuckle <jstucklex@attglobal.net> - 2013-11-22 08:53 -0500
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-23 06:21 +0000
Re: PHP functions to convert markup efficiently Jerry Stuckle <jstucklex@attglobal.net> - 2013-11-23 06:59 -0500
Re: PHP functions to convert markup efficiently Christoph Michael Becker <cmbecker69@arcor.de> - 2013-11-23 13:12 +0100
Re: PHP functions to convert markup efficiently Arno Welzel <usenet@arnowelzel.de> - 2013-11-22 16:42 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-23 16:38 +0000
Re: PHP functions to convert markup efficiently Richard Yates <richard@yatesguitar.com> - 2013-11-23 13:24 -0800
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-23 22:07 +0000
Re: PHP functions to convert markup efficiently Arno Welzel <usenet@arnowelzel.de> - 2013-11-24 17:09 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-24 18:11 +0000
Re: PHP functions to convert markup efficiently Arno Welzel <usenet@arnowelzel.de> - 2013-11-24 23:18 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-24 23:44 +0000
Re: PHP functions to convert markup efficiently Arno Welzel <usenet@arnowelzel.de> - 2013-11-25 08:11 +0100
Re: PHP functions to convert markup efficiently "James Harris" <james.harris.1@gmail.com> - 2013-11-23 19:21 +0000
csiph-web