( ′∀`)σ≡σ☆))Д′)レ(゚∀゚;)ヘ=З=З=Зε≡(ノ´_ゝ`)ノ
<?php
include("includes/limittext.php");
include('Connections/videoondemand.php');
require("DbSql.inc.php");
require("NewsSql.inc.php");
ini_set('max_execution_time', 300); //300 seconds = 5 minutes
$db = new NewsSQL($DBName);
error_reporting(1);
$url = "http://localhost/thebrand/assets/fonts/google-fonts.json" ;
$json = file_get_contents($url);
$characters = json_decode($json,true);
/*echo $characters[3]->left->desktop;*/
/* $image = $characters[11]->image_url;*/
$weight = "50";
$style = "normal";
$isdisplay="1";
foreach ($characters as $row) {
$name = $row['variants'][$style][$weight]['local'][0];
if(!empty($name))
{ $category = $row['category'];
$name = str_replace("'","","$name");
$name = str_replace("'","","$name");
$filename = $row['variants'][$style][$weight]['local'][1];
$filename = str_replace("'","","$filename");
$db->Insert_Font($category,$weight,$style,$name,$filename,$isdisplay);
}
}