mirror of
https://github.com/friendica/friendica
synced 2025-04-25 03:10:11 +00:00
OEmbed and parse_url are now cached in dedicated tables
This commit is contained in:
parent
c4ba035ee3
commit
d5e1f33506
6 changed files with 49 additions and 13 deletions
|
@ -968,12 +968,7 @@ function add_page_info_data($data) {
|
|||
function query_page_info($url, $no_photos = false, $photo = "", $keywords = false, $keyword_blacklist = "") {
|
||||
require_once("mod/parse_url.php");
|
||||
|
||||
$data = Cache::get("parse_url:".$url);
|
||||
if (is_null($data)){
|
||||
$data = parseurl_getsiteinfo($url, true);
|
||||
Cache::set("parse_url:".$url,serialize($data), CACHE_DAY);
|
||||
} else
|
||||
$data = unserialize($data);
|
||||
$data = parseurl_getsiteinfo_cached($url, true);
|
||||
|
||||
if ($photo != "")
|
||||
$data["images"][0]["src"] = $photo;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue