Home News Contact Us Forum About Us Demos Products F.A.Q.
Shopping Cart
You currently have 0 items in your cart.


Recent Events
  • 31/12/2023 New Year SALE

    We are glad to announce New Year SALE. 25% discount for all our extensions. Use NY24 coupon code. Hurry up the discount is valid till 7 January.

  • 21/11/2023 BLACK FRIDAY 23 is coming

    BIG SALE, 35% discount for all our extensions. Use BF23 coupon code. Hurry up the discount is valid till 27 November.


2Checkout.com, Inc. is an authorized retailer of goods and services provided by ARI Soft. 2CheckOut




Follow us on twitter



Welcome, Guest
Please Login or Register.    Lost Password?

Possible Bug: Javascript / Responsive Enabled, v2x
(1 viewing) (1) Guest
Go to bottomPage: 12
TOPIC: Possible Bug: Javascript / Responsive Enabled, v2x
#52611
Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 0
I have the following code working nicely in a Columns Settings > format option for a data table, but when I enable Responsive in the module, it never completes. The page with the table starts to load, but hangs waiting for a socket/localhost. This only happens when Responsive is enable. It happens using Chrome, Firefox and IE.

Code:

<strong>{$value}</strong><br/>
<script>
if ('{$columns:address}') {  document.write('{$columns:address}<br/>') };
if ('{$columns:city}') {  document.write('{$columns:city}, ') };
if ('{$columns:state}') {  document.write('{$columns:state} ') };
if ('{$columns:zipcode}') {  document.write('{$columns:zipcode}<br/> ') };
if ('{$columns:contactPhone}') {  document.write('{$columns:contactPhone}<br/> ') };
if ('{$columns:contactEmail}') {  document.write('{$columns:contactEmail}<br/> ') };
if ('{$columns:webLink}') {  document.write('{$columns:webLink}<br/> ') }
</script>

The administrator has disabled public write access.
 
#52620
Re:Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 760
Hello,

Use the following code in "Columns settings -> Format" value:

Code:


{$columns:address|format:%s<br/>}
{$columns:city|format:%s<br/>}
{$columns:state|format:%s<br/>}
...



Regards,
ARI Soft
The administrator has disabled public write access.
 
#52622
Re:Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 0
So, am I interpreting this response correctly? If 'Responsive' is enabled, you have to add |format:%$ to every field displayed or for every field where there is a column format added.
The administrator has disabled public write access.
 
#52623
Re:Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 760
It is not a good approach to do it via javascript and use "document.write" construction. We provided the solution how to do it on server side.

Regards,
ARI Soft
The administrator has disabled public write access.
 
#52624
Re:Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 0
admin wrote:
It is not a good approach to do it via javascript and use "document.write" construction. We provided the solution how to do it on server side.

Regards,
ARI Soft


So, is it correct to say that '|format:%s' does the same thing as document.write? If so, how am I suppose to know that? There is nothing that I've found in the documentation (www.ari-soft.com/docs/arismartcontent/v2/html/ARI_Smart_Content_UserGuide.html?Datatable.html or www.ari-soft.com/docs/arismartcontent/v2/html/ARI_Smart_Content_UserGuide.html?SQLqueries.html#table_formatters) with regards to using ' | ' or the 'format:%s'. What other server side options are available, but not documented?
The administrator has disabled public write access.
 
#52625
Re:Possible Bug: Javascript / Responsive Enabled, v2x 9 Years, 11 Months ago Karma: 760
It is formatted values on server side. "format" calls "sprint" PHP function with value of the current cell.

The documentation has not contained description of formatters yet. We will update it soon.

Regards,
ARI Soft
The administrator has disabled public write access.
 
Go to topPage: 12