Jump to content

Efficiency


HDFilmMaker2112

Recommended Posts

Just looking for an opinion on which one of these two pieces of code would process faster:

 

 

<tr align="center" class="border">
<td class="border">';
if($copper=="yes"){
$content.= '<span class="strike">Copper</span>';
}
else{
$content.= 'Copper';
}
$content.='
</td>
<td class="border">
';
if($copper=="yes"){
$content.= '<span class="strike">$10 - $35</span>';
}
else{
$content.= '
$10 - $35';
}
$content.='
</td>
<td class="border">';
if($copper=="yes"){
$content.= '<span class="strike">800</span>';
}
else{
$content.= '
800';
}
$content.='
</td>
<td class="border">';
if($copper=="yes"){
$content.='Levels that are crossed out are full.';
}
else{
$content.='Name in end Credits + Nickel Level';
}
$content.='
</td>
</tr>

 

vs.

 

if($copper=="yes"){
<tr align="center" class="border">
<td class="border">
<span class="strike">Copper</span>
</td>
<td class="border">
<span class="strike">$10 - $35</span>
</td>
<td class="border">
<span class="strike">800</span>
</td>
<td class="border">
Levels that are crossed out are full.
</td>
</tr>
}
else{
<tr align="center" class="border">
<td class="border">
Copper
</td>
<td class="border">
$10 - $35
</td>
<td class="border">
800
</td>
<td class="border">
Name in end Credits + Nickel Level
</td>
</tr>
}

Link to comment
https://forums.phpfreaks.com/topic/251081-efficiency/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.