• Home
  • Demo
  • Buy Now
RISE - Ultimate Project Manager & CRM
    RISE - Ultimate Project Manager & CRMInstallation & MaintenancePersonalizationSettingsClient ManagementAI AssistantInvoices & PaymentsProjects & TasksTeam & CollaborationProductivity ToolsSales & ServicesRISE ReportsPluginsFAQChange logs
Mailbox PluginLanding Page Builder PluginEasy Backup PluginSquare Payment Method PluginLogin as Client PluginAsset Management Plugin2 Factor Authentication PluginPassword Manager PluginSocial Login PluginGoogle Meet Integration PluginSpreadsheets PluginZoom Integration PluginAuto Attendance PluginWhiteboards PluginDocs PluginBlog Manager PluginWhatsApp Link PluginMicrosoft Teams Integration PluginProperty Management PluginTelegram Notification PluginAWS S3 Integration PluginWhatsApp Notification PluginWasabi Integration PluginBackblaze Integration PluginCloudflare R2 Integration PluginDigitalOcean Spaces Integration PluginAdyen Payment Method PluginbKash Payment Method Pluginiyzico Payment Method PluginJazzCash Payment Method PluginMercado Pago Payment Method PluginMidtrans Payment Method PluginMontonio Payment Method PluginN-Genius Payment Method PluginNagad Payment Method PluginPayFast Payment Method PluginPaysera Payment Method PluginPaystack Payment Method PluginPix Payment Method PluginRazorpay Payment Method PluginRocket Payment Method PluginSSLCommerz Payment Method Plugin
  1. Docs
  2. RISE - Ultimate Project Manager & CRM
  3. Plugins

Css and javascript file versions

RISE adds a version to the end of every CSS and JavaScript file it loads, like app.all.css?v=4.2.1763800000. The version is the app version plus the time the file was last changed. When a file changes, its link changes too, so browsers load the new file right away.

This lets you cache CSS, JavaScript and font files for a long time on your server (for example one year), without visitors getting old files after an update.

Load your plugin files

Use load_css() and load_js(). They add the version for you:

load_css(array(
    "plugins/My_Plugin/assets/css/my_plugin.css"
));
load_js(array(
    "plugins/My_Plugin/assets/js/my_plugin.js"
));

Write the link yourself

If you write the <link> or [removed] tag yourself, use get_asset_version() with the same path:

$path = "plugins/My_Plugin/assets/js/my_plugin.js";
echo "[removed][removed]";

The path starts from the RISE folder. If the file is not found, only the app version is used.

Do not use a fixed version like ?v=1.0. Its link never changes, so it can't be cached for long, and after a plugin update visitors may see the old file for a while.

Server caching

Pages are never cached. Only files whose ?v= ends with a file time should get a long cache time. Other files (no version, or a fixed version like ?v=1.0) should get a short one. Example for nginx:

map $arg_v $asset_cache_control {
    "~^[0-9.]*\.[0-9]{9,}$" "public, max-age=31536000, immutable";
    default "max-age=3600";
}

server {
    location ~* \.(css|js|woff2?|png|jpg|svg)$ {
        add_header Cache-Control $asset_cache_control;
        try_files $uri /index.php?$query_string;
    }
}
Was this article helpful? Yes No
How can we improve this article?
© 2026 Fairsketch
Home Get Support Buy Now

Delete?

Are you sure? You won't be able to undo this action!
To do