Пример #1
0
 public function getSwfUrl($raw_only = false)
 {
     $raw = parent::getSwfUrl();
     if ($raw_only) {
         return $raw;
     }
     $root_url = kConf::get("flash_root_url");
     if (!$root_url) {
         return $raw;
     }
     if (strpos($raw, $root_url) === 0) {
         // if the raw url already has the exact prefix of root_url - return the raw - no need to re-append it
         return $raw;
     }
     if (strpos($raw, "http://") === 0) {
         // if the raw url starts with http - don't append to it
         return $raw;
     }
     return $root_url . $raw;
 }