You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Engine/tEobject.php
+23-42Lines changed: 23 additions & 42 deletions
Original file line number
Diff line number
Diff line change
@@ -88,7 +88,7 @@ function varFile($file, $fileDepth) {
88
88
else
89
89
$finalValue = true;
90
90
91
-
if ($subStr == tEnTableK && $primaryIn == tEnTableB) { // When we find a table's K value, then we unlock finalValue and change the tPosition.
91
+
if ($subStr == tEnTableK && $primaryIn == tEnTableB && $tPosition == null) { // When we find a table's K value, then we unlock finalValue and change the tPosition.
92
92
$tPosition = $size;
93
93
$tStart = $start;
94
94
$finalValue = false;
@@ -132,66 +132,47 @@ function varFile($file, $fileDepth) {
132
132
}
133
133
134
134
} else { // Tables are treated through special logic due to their crazy two-part complexity. Gotta love it!
// The first half of this is resolving the table filename. In most cases, we don't actually need to do this. That said, who knows what horrors the user has subjected this input to.
137
-
if ($tStart != $position) { // Okay, so we know that this half of the table is actually a chain. Let's resolve it!
if ($resolutionTest == null) // If we've encountered an unsolvable test, abandon the plan.
143
-
break;
144
-
$testingVariable = $resolutionTest;
145
-
$tStart--;
146
-
if (substr($fileString, $start-1, 1) == tEnFile) // If the second to next tag would've been the start tag, then we've reached the end of what we needed to do.
147
-
break;
135
+
// First, we check if this is even worth it. It may not be!
if ($start-1 == ($position+$tPosition+1)) // If the second to next tag would've been the start tag, then we've reached the end of what we needed to do.
if ($resolutionTest == null) // If we've encountered an unsolvable test, abandon the plan.
170
-
break;
171
-
$testingVariable = $resolutionTest;
172
-
$start--;
173
-
if (substr($fileString, $start-1, 1) == tEnTableK) // If the second to next tag would've been the start tag, then we've reached the end of what we needed to do.
<p>As you can see, tables are a <i>very</i> powerful feature which open up many different possibilities.</p>
19
19
<p>Another little interesting factoid is that file tags are first tested relative to the template, then relative to the script, and finally absolute. This means that you can place your templates folder anywhere you damn well please, and have it work just fine. Some examples include [#relativeFile.html], [#test2/relativeFile.html], and [#test3/relativeFile.html].</p>
0 commit comments