Changeset 908 for trunk/Modules/News/News.php
- Timestamp:
- May 1, 2021, 10:01:34 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/News/News.php
r899 r908 240 240 } 241 241 242 function ModifyContent (string $Content): string242 function ModifyContentPrefix(string $Content, string $Prefix): string 243 243 { 244 244 $Result = ''; … … 246 246 // Make HTML link from URL 247 247 $I = 0; 248 while (strpos($Content, 'http://') !== false)249 { 250 $I = strpos($Content, 'http://');248 while (strpos($Content, $Prefix) !== false) 249 { 250 $I = strpos($Content, $Prefix); 251 251 if (($I > 0) and ($Content[$I - 1] != '"')) 252 252 { … … 266 266 $Result .= $Content; 267 267 return $Result; 268 } 269 270 function ModifyContent(string $Content): string 271 { 272 return $this->ModifyContentPrefix($this->ModifyContentPrefix($Content, 'http://'), 'https://'); 268 273 } 269 274
Note:
See TracChangeset
for help on using the changeset viewer.