Jean-Baptiste
Well-known member
Hello,
To get the version ID for XenForo, you need to call the following static variable :
I would like to make a conditionnal check, to check if the version is older or equal to 2.1 (I don't care if it's a beta or stable release).
I read the following doc : https://xenforo.com/xf2-docs/dev/add-on-structure/#recommended-version-string-format
Is the following code correct to check if I am using the 2.1 version of XenForo ?
Thanks for the help,
Best regards,
Jean-Baptiste
To get the version ID for XenForo, you need to call the following static variable :
Code:
\XF::$versionId
I would like to make a conditionnal check, to check if the version is older or equal to 2.1 (I don't care if it's a beta or stable release).
I read the following doc : https://xenforo.com/xf2-docs/dev/add-on-structure/#recommended-version-string-format
Is the following code correct to check if I am using the 2.1 version of XenForo ?
Code:
if(\XF::$versionId > 2001070)
Thanks for the help,
Best regards,
Jean-Baptiste