[Vtigercrm-developers] Poss. to have HEADERSCRIPT dependent on vtiger version?

Stefan Warnat ich at stefanwarnat.de
Sun Oct 8 18:56:32 GMT 2017


Hy Alan,

This is an option, but requires a DOM access. (2 ms, which could be used
better) :)
My framework check this with the following function:


*isVT7: function () {*
*  return typeof app.helper !== 'undefined';*

*}*

Works great.

Stefan


----
*Freelancer at Webdevelopment*

Web: http://www.stefanwarnat.de
Xing: https://www.xing.com/profile/Stefan_Warnat2
LinkedIn: http://www.linkedin.com/pub/stefan-warnat/6/827/820
eMail: kontakt at stefanwarnat.de


On Sat, Oct 7, 2017 at 5:55 PM, Alan Lord <alanslists at gmail.com> wrote:

> On 07/10/17 16:35, Sutharsan Jeganathan wrote:
>
>> Hi
>>
>> Hope this will work.
>> http://api.jquery.com/jQuery.getScript
>>
>> It is bit slower,  but possible to send an Ajax to vtigerversion.php then
>> load relevant script
>>
>
> Thanks - but I managed to come up with a workaround - in the <body tag is
> a data attribute "skinpath" with a path: layouts/{v7,vlayout}/skins.
>
> This changes between v7 and v6 - as above - so I use that for now with a
> simple indexOf test in my init function.
>
> It's not ideal but it works.
>
> Cheers
>
> Al
>
> _______________________________________________
> http://www.vtiger.com/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20171008/dd009581/attachment.html>


More information about the vtigercrm-developers mailing list