Skip to content

Commit

Permalink
use content cache in TXT
Browse files Browse the repository at this point in the history
  • Loading branch information
qkqpttgf committed Mar 31, 2021
1 parent 449ead4 commit 671481c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions common.php
Original file line number Diff line number Diff line change
Expand Up @@ -2111,11 +2111,10 @@ function render_list($path = '', $files = [])
$html = str_replace('<!--constStr@ClicktoEdit-->', getconstStr('ClicktoEdit'), $html);
$html = str_replace('<!--constStr@CancelEdit-->', getconstStr('CancelEdit'), $html);
$html = str_replace('<!--constStr@Save-->', getconstStr('Save'), $html);
while (strpos($html, '<!--TxtContent-->')) $html = str_replace('<!--TxtContent-->', htmlspecialchars(curl('GET', $files['url'], '', [], 0, 1)['body']), $html);
//while (strpos($html, '<!--TxtContent-->')) $html = str_replace('<!--TxtContent-->', htmlspecialchars(get_content(spurlencode(path_format(urldecode($path) . '/' . $files['name']), '/'))['content']['body']), $html);
//while (strpos($html, '<!--TxtContent-->')) $html = str_replace('<!--TxtContent-->', htmlspecialchars(curl('GET', $files['url'], '', [], 0, 1)['body']), $html);
while (strpos($html, '<!--TxtContent-->')) $html = str_replace('<!--TxtContent-->', htmlspecialchars(get_content(spurlencode(path_format(urldecode($path)), '/'))['content']['body']), $html);
$html = str_replace('<!--constStr@FileNotSupport-->', getconstStr('FileNotSupport'), $html);


//$html = str_replace('<!--constStr@File-->', getconstStr('File'), $html);
} elseif ($files['type']=='folder') {
while (strpos($html, '<!--GuestUploadStart-->')) {
Expand Down

0 comments on commit 671481c

Please sign in to comment.