<?php

if (!defined('BASEPATH'))
    exit('No direct script access allowed');

/**
 * @param string $url
 * @return boolean
 */
if (!function_exists("check_img_url")) {

    function check_img_url($img_url) {
        $ch = curl_init($img_url);
        curl_setopt($ch, CURLOPT_NOBODY, true);
        curl_exec($ch);
        $code = curl_getinfo($ch, CURLINFO_HTTP_CODE);

        if ($code == 200) {
            $status = true;
        } else {
            $status = false;
        }
        curl_close($ch);
        return $status;
    }

}
/* End of file sql_assets_helper.php */
/* Location: ./system/helpers/sql_assets_helper.php */