Skip to main content

Horizontal scrollbar and unresponsive on product Add/Edit Form

More
9 years 4 months ago #272026 by engferas
-- url of the page with the problem -- : adkakin.com/%D9%85%D9%86%D8%AA%D8%AC%D8%...%8A/product/add.html
-- HikaShop version -- : 3.1.1
-- Joomla version -- : 3.7.2
-- PHP version -- : 7.2

Hi,

I have a problem with product Add/Edit Form, a horizontal scroll bar appear (please check the screen shot 1), and the page is not responsive at all, I tried to change the template and I used Protostar Template but the same problem persist. please to advice how to solve this.
please use the demo user:
username: user2
pass: user2

Please Log in or Create an account to join the conversation.

More
9 years 4 months ago #272065 by Jerome
Hello,

Please note that the link you gave were not working ; but we access to HikaMarket via the non SEF URL.
pasteboard.co/aIzussuU.png

The issue is related to the "namebox" which have a span element outside the page to allow it to know the required width for text (during the search).
These span have " left:-2000px " but they should have " left:2000px " in RTL.

That's why you need to edit the HikaMarket type namebox and replace
Code:
$style = ''; if(!empty($options['style'])) $style = ' style="' . is_array($options['style']) ? implode(' ', $options['style']) : $options['style'] . '"';
By
Code:
$style = ''; if(!empty($options['style'])) $style = ' style="' . is_array($options['style']) ? implode(' ', $options['style']) : $options['style'] . '"'; $lang = JFactory::getLanguage(); $leftOffset = ($lang->isRTL()) ? '2000px' : '-2000px';

And then
Code:
$ret .= "\r\n".'<div class="nametext">'. '<input id="'.$id.'_text" type="text" style="width:50px;min-width:60px" onfocus="window.oNameboxes[\''.$id.'\'].focus(this);" onkeyup="window.oNameboxes[\''.$id.'\'].search(this);" onchange="window.oNameboxes[\''.$id.'\'].search(this);"/>'. '<span style="position:absolute;top:0px;left:-2000px;visibility:hidden" id="'.$id.'_span">span</span>'.
By
Code:
$ret .= "\r\n".'<div class="nametext">'. '<input id="'.$id.'_text" type="text" style="width:50px;min-width:60px" onfocus="window.oNameboxes[\''.$id.'\'].focus(this);" onkeyup="window.oNameboxes[\''.$id.'\'].search(this);" onchange="window.oNameboxes[\''.$id.'\'].search(this);"/>'. '<span style="position:absolute;top:0px;left:'.$leftOffset.';visibility:hidden" id="'.$id.'_span">span</span>'.

But also the code
Code:
<span style="position:absolute;top:0px;left:-2000px;visibility:hidden" id="'.$id.'_span">xxxxxx</span>
By
Code:
<span style="position:absolute;top:0px;left:'.$leftOffset.';visibility:hidden" id="'.$id.'_span">xxxxxx</span>

Please note that you can apply the same patch for the HikaShop namebox type too.

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Please Log in or Create an account to join the conversation.

Moderators: Obsidev
Time to create page: 0.124 seconds
Powered by Kunena Forum