Hide column when using server side and simple side too
Hide column when using server side and simple side too
pajafumo
Posts: 5Questions: 0Answers: 0
Hi Allan, I think you should check the next function, I show me error when I try to hide columns v.1.9.3 and 1.9.4
[code]
function _fnStringToCss( s )
{
if ( s === null )
{
return "0px";
}
if ( typeof s == 'number' )
{
if ( s < 0 )
{
return "0px";
}
return s+"px";
}
/* Check if the last character is not 0-9 */
var c = s.charAt( s.length-1 );
if (c < 0x30 || c > 0x39)
{
return s;
}
return s+"px";
}
[/code]
I try to add this line: var s = new String(s); and everything works fine.
[code]
function _fnStringToCss( s )
{
var s = new String(s); // here the change
if ( s === null )
{
return "0px";
}
if ( typeof s == 'number' )
{
if ( s < 0 )
{
return "0px";
}
return s+"px";
}
/* Check if the last character is not 0-9 */
var c = s.charAt( s.length-1 );
if (c < 0x30 || c > 0x39)
{
return s;
}
return s+"px";
}
[/code]
I hope this will be usefull
[code]
function _fnStringToCss( s )
{
if ( s === null )
{
return "0px";
}
if ( typeof s == 'number' )
{
if ( s < 0 )
{
return "0px";
}
return s+"px";
}
/* Check if the last character is not 0-9 */
var c = s.charAt( s.length-1 );
if (c < 0x30 || c > 0x39)
{
return s;
}
return s+"px";
}
[/code]
I try to add this line: var s = new String(s); and everything works fine.
[code]
function _fnStringToCss( s )
{
var s = new String(s); // here the change
if ( s === null )
{
return "0px";
}
if ( typeof s == 'number' )
{
if ( s < 0 )
{
return "0px";
}
return s+"px";
}
/* Check if the last character is not 0-9 */
var c = s.charAt( s.length-1 );
if (c < 0x30 || c > 0x39)
{
return s;
}
return s+"px";
}
[/code]
I hope this will be usefull
This discussion has been closed.
Replies
Allan
Thanks