Page tree
Skip to end of metadata
Go to start of metadata

Required phpFox version > 4.8.0


Since phpFox 4.8.0, on top of local file system, asset / static files (JS, CSS)  can be also hosted at the remote storage systems or CDN. By adding this asset handling method, we can help reduce the load of the application server as well as utilize the power of remote static file system to load static assets faster. 

phpFox supports Assets library to help you get asset file Url easily without the necessity to care where asset files are stored in. Here is the sample code to get URL of a certain asset file:

<?php
// return full asset's url
$assetUrl = Phpfox::getLib('assets')->getAssetUrl('PF.Site/Apps/core-egift/assets/autoload.js')
?>
  • No labels