| @@ 324-336 (lines=13) @@ | ||
| 321 | public function ResolveCssHref($cssArray, $type = 'custom', &$hrefs) |
|
| 322 | { |
|
| 323 | switch ($type) { |
|
| 324 | case'libs': |
|
| 325 | foreach ($cssArray as $css) { |
|
| 326 | if (is_array($css)) { |
|
| 327 | $this->ResolveCssHref($css, $type, $hrefs); |
|
| 328 | continue; |
|
| 329 | } |
|
| 330 | if (strpos($css, '//') !== false) |
|
| 331 | $href = $css; |
|
| 332 | else |
|
| 333 | $href = ($this->app->type != 'app' ? '/' . $this->app->name : '' ) . $css; |
|
| 334 | $hrefs[$href] = $href; |
|
| 335 | } |
|
| 336 | break; |
|
| 337 | case'template': |
|
| 338 | foreach ($cssArray as $css) { |
|
| 339 | if (is_array($css)) { |
|
| @@ 337-349 (lines=13) @@ | ||
| 334 | $hrefs[$href] = $href; |
|
| 335 | } |
|
| 336 | break; |
|
| 337 | case'template': |
|
| 338 | foreach ($cssArray as $css) { |
|
| 339 | if (is_array($css)) { |
|
| 340 | $this->ResolveCssHref($css, $type, $hrefs); |
|
| 341 | continue; |
|
| 342 | } |
|
| 343 | if (strpos($css, '://') !== false) |
|
| 344 | $href = $css; |
|
| 345 | else |
|
| 346 | $href = $this->app->templatesPath . "/{$this->template->name}/css/{$css}"; |
|
| 347 | $hrefs[$href] = $href; |
|
| 348 | } |
|
| 349 | break; |
|
| 350 | case 'custom': |
|
| 351 | foreach ($cssArray as $css) { |
|
| 352 | if (is_array($css)) { |
|
| @@ 350-362 (lines=13) @@ | ||
| 347 | $hrefs[$href] = $href; |
|
| 348 | } |
|
| 349 | break; |
|
| 350 | case 'custom': |
|
| 351 | foreach ($cssArray as $css) { |
|
| 352 | if (is_array($css)) { |
|
| 353 | $this->ResolveCssHref($css, $type, $hrefs); |
|
| 354 | continue; |
|
| 355 | } |
|
| 356 | if (strpos($css, '//') !== false) |
|
| 357 | $href = $css; |
|
| 358 | else |
|
| 359 | $href = ($this->app->type != 'app' ? '/' . $this->app->name : '' ) . $css; |
|
| 360 | $hrefs[$href] = $href; |
|
| 361 | } |
|
| 362 | break; |
|
| 363 | } |
|
| 364 | } |
|
| 365 | ||
| @@ 495-507 (lines=13) @@ | ||
| 492 | $resultArray[] = $href; |
|
| 493 | } |
|
| 494 | break; |
|
| 495 | case'template': |
|
| 496 | foreach ($jsArray as $js) { |
|
| 497 | if (is_array($js)) { |
|
| 498 | $this->genScriptArray($js, $type, $resultArray); |
|
| 499 | continue; |
|
| 500 | } |
|
| 501 | if (strpos($js, '//') !== false) |
|
| 502 | $href = $js; |
|
| 503 | else |
|
| 504 | $href = $this->app->templatesPath . "/{$this->template->name}/js/{$js}"; |
|
| 505 | $resultArray[] = $href; |
|
| 506 | } |
|
| 507 | break; |
|
| 508 | case 'custom': |
|
| 509 | foreach ($jsArray as $js) { |
|
| 510 | if (is_array($js)) { |
|