Welcome Guest, Not a member yet? Register   Sign In
Basic PHP question
#8

(08-08-2019, 09:27 AM)John_Betong Wrote: > @includebeer 
> You're just making the computer work harder for nothing. Static HTML will always render faster.

The PHP script is a single block and I think vastly reduces processing because it eliminates the need to jump in and out of HTML script to insert variables.

I'd be curious to see benchmark and memory usage on this. I'm not convince your method performs better than plain HTML with some PHP variables but I guess it's a matter of personal preferences.

But I must say this is some weird code formatting! 

PHP Code:
PUBLIC function htmlHeader
(
 
 string $title PLATFORM .' - A wonderful book search utility'
 
 string $desc  'Yes we have no description???'
)
:
string // $result 
CodeIgniter 4 tutorials (EN/FR) - https://includebeer.com
/*** NO support in private message - Use the forum! ***/
Reply


Messages In This Thread
Basic PHP question - by ronniebel - 08-06-2019, 04:22 PM
RE: Basic PHP question - by includebeer - 08-06-2019, 05:14 PM
RE: Basic PHP question - by John_Betong - 08-06-2019, 11:12 PM
RE: Basic PHP question - by albertleao - 08-06-2019, 11:20 PM
RE: Basic PHP question - by includebeer - 08-07-2019, 02:57 AM
RE: Basic PHP question - by dave friend - 08-07-2019, 06:28 AM
RE: Basic PHP question - by John_Betong - 08-08-2019, 09:27 AM
RE: Basic PHP question - by includebeer - 08-08-2019, 10:12 AM
RE: Basic PHP question - by dave friend - 08-08-2019, 12:10 PM
RE: Basic PHP question - by kilishan - 08-08-2019, 02:27 PM



Theme © iAndrew 2016 - Forum software by © MyBB