mirror of
https://github.com/kuaifan/dootask.git
synced 2026-01-20 16:08:14 +00:00
no message
This commit is contained in:
parent
39cca6ec99
commit
f45ebb5dd2
@ -677,8 +677,8 @@ class WebSocketDialogMsg extends AbstractModel
|
|||||||
preg_match_all("/<a[^>]*?href=([\"'])(.*?)\\1[^>]*?>(.*?)<\/a>/is", $text, $matchs);
|
preg_match_all("/<a[^>]*?href=([\"'])(.*?)\\1[^>]*?>(.*?)<\/a>/is", $text, $matchs);
|
||||||
foreach ($matchs[0] as $key => $str) {
|
foreach ($matchs[0] as $key => $str) {
|
||||||
$herf = $matchs[2][$key];
|
$herf = $matchs[2][$key];
|
||||||
$title = $matchs[3][$key] ?: $herf;
|
$title = $matchs[3][$key] ? strip_tags($matchs[3][$key]): $herf;
|
||||||
preg_match("/\/single\/file\/(.*?)$/i", $herf, $match);
|
preg_match("/\/single\/file\/(.*?)$/i", $title, $match);
|
||||||
if ($match && strlen($match[1]) >= 32) {
|
if ($match && strlen($match[1]) >= 32) {
|
||||||
$file = File::select(['files.id', 'files.name', 'files.ext'])->join('file_links as L', 'files.id', '=', 'L.file_id')->where('L.code', $match[1])->first();
|
$file = File::select(['files.id', 'files.name', 'files.ext'])->join('file_links as L', 'files.id', '=', 'L.file_id')->where('L.code', $match[1])->first();
|
||||||
if ($file && $file->name) {
|
if ($file && $file->name) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user