Zen Cart is not limiting those fields. You'll see that the generated HTML is not doing the limiting.
The browser is probably to blame. Or maybe you have some CSS rules that are limiting the displayed size.
Zen Cart is not limiting those fields. You'll see that the generated HTML is not doing the limiting.
The browser is probably to blame. Or maybe you have some CSS rules that are limiting the displayed size.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
I will look around and will let you know if I discover anything. Thank you.
Using Zen Cart 1.5.1
Another questions
I have created an additional field in the zen_products called products_ship_info with the following attributes:
Type: text
Collattion: utf8_general_ci
Null: Yes
Default: NULL
I can not get it to display properly in admin>Product Description. I am using the following in admin/includes/modules/product/collect_info.php :
When I load this the page breaks after displaying Product Ship Info: and error log shows the following:PHP Code:<?php
for ($i=0, $n=sizeof($languages); $i<$n; $i++) {
?>
<tr>
<td class="main" valign="top"><?php echo 'Product Ship Info: ' ?></td>
<td colspan="2"><table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="main" width="25" valign="top"><?php echo zen_image(DIR_WS_CATALOG_LANGUAGES . $languages[$i]['directory'] . '/images/' . $languages[$i]['image'], $languages[$i]['name']); ?> </td>
<td class="main" width="100%"><?php echo zen_draw_textarea_field('products_ship_info[' . $languages[$i]['id'] . ']', 'soft', '100%', '30', htmlspecialchars((isset($products_ship_info[$languages[$i]['id']])) ? stripslashes($products_ship_info[$languages[$i]['id']]) : zen_get_products_ship_info($pInfo->products_id, $languages[$i]['id']), ENT_COMPAT, CHARSET, TRUE)); ?></td>
</tr>
</table></td>
</tr>
<?php
}
?>
Line 331 is the beginning of the PHP code.PHP Code:[03-Jul-2013 19:06:16 UTC] PHP Fatal error: Call to undefined function zen_get_products_ship_info() in path\Store\admin\includes\modules\product\collect_info.php on line 331
.
Using Zen Cart 1.5.1
Why are you using zen_get_products_ship_info( as a function?? stripslashes($products_ship_info[$languages[$i]['id']]) : zen_get_products_ship_info($pInfo->products_id, $languages[$i]['id']), ENT_COMPAT, CHARSET, TRUE))
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
No I am trying to show the field products_ship_info, there is no function involved.
I have added 3 other fields to the zen_products table, without any issues. The only difference here is products_ship_info field type here is text and the other 3 i added were varchar() type with different lengths.
I wanted the products_ship_info to be an expandable text field, not limited by the number of characters. That is why i followed the products_description method to display the data in admin.
Using Zen Cart 1.5.1
When I use:
I get a 5 character input text box, but I need to display a text area under admin and finally in product_info_display.PHP Code:<td class="main"><?php echo 'Product Ship Info: '; ?></td>
<td class="main"><?php echo zen_draw_separator('pixel_trans.gif', '24', '15') . ' ' . zen_draw_input_field('products_ship_info',
htmlspecialchars(stripslashes($pInfo->products_ship_info), ENT_COMPAT, CHARSET, TRUE), zen_set_field_length(TABLE_PRODUCTS, 'products_ship_info')); ?></td>
Last edited by Kevin205; 3 Jul 2013 at 08:51 PM.
Using Zen Cart 1.5.1
Fixed it. I replaced zen_draw_input_field by zen_draw_textarea_field
Thank you DrBytePHP Code:<td class="main"><?php echo 'Product Ship Info: '; ?></td>
<td class="main"><?php echo zen_draw_separator('pixel_trans.gif', '24', '15') . ' ' . zen_draw_textarea_field('products_ship_info',
htmlspecialchars(stripslashes($pInfo->products_ship_info), ENT_COMPAT, CHARSET, TRUE), zen_set_field_length(TABLE_PRODUCTS, 'products_ship_info')); ?></td>
Using Zen Cart 1.5.1