Post by jenstm » Fri Jul 15, 2011 7:48 am

Hello :)

I have seen the question before and have tried to fix it, but i seems like the fix I found here..:
http://forum.opencart.com/viewtopic.php?t=14704
http://forum.opencart.com/viewtopic.php ... 2&start=20

...does not work version 1.5.0.5. I seems only to work on 1.4.x

In Denmark the shipping is the same price nomatter where in Denmark you ship to, also I am only going to sell in Denmark so therefor I would like to remove the drop down boxes.

I hope some brilliant brain will help me out :)

Best Regards,

Jens
Denmark

Newbie

Posts

Joined
Fri Jul 15, 2011 7:33 am

Post by merry » Sun Jul 17, 2011 6:57 am

Hi Jens,
When you say it does not work, what part does not work--what happens? It will help us to help you if you please tell us what you did and where it breaks, so we can just start from the breaking point.
Kerry

Most answers are from my OpenCart 1.5 User Manual CURRENT TO 1.5.5.1 and includes free updates.
FREE HELP! 60-page user guide with OpenCart Admin Menu Cheatsheet, Install Guide & 30 Minute QuickStart Guide: http://showmeguides.com/


User avatar
Active Member

Posts

Joined
Thu Dec 09, 2010 12:51 am
Location - Mexico and sometimes Texas

Post by IsoNick » Wed Jul 20, 2011 6:08 am

I've been helping Jens on this issue.

The problem is, that those lines that you can replace in version 1.4.x, don't seem to be in 1.5.x - or maybe they are, we just can't find them. We wan't to strip off the region and country selector during check out.

The test board is online at this url: http://oc.amusant.dk

Thanks

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by i2Paq » Wed Jul 20, 2011 1:32 pm

If you set it to work with only Denmark maybe removing the lines from the theme's .tpl that shows them would be enough?

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by peecha85 » Thu Jul 21, 2011 3:00 am

If you set it to work with only Denmark maybe removing the lines from the theme's .tpl that shows them would be enough?
this worked in 1.4.x, but not in 1.5.x
If you remove the lines or comment out, you are no longer able to proceed the checkout process- the continue button doesn't work. it's not only because these fields are mandatory- this happens to all fields (fax, company etc)
I am also looking forward to see the answer, because I don't need such fields as fax, company or address 2.

Active Member

Posts

Joined
Tue May 11, 2010 10:28 pm

Post by freshbreeze » Thu Jul 21, 2011 5:13 am

If you disable all countries except Denmark then the other countries won't be in the dropdown. Sorry I don't know how the drop down will behave then after with just one active country.

BACK UP and you could run this sql in the databse:

Code: Select all

UPDATE country SET status = '0' WHERE status = '1';
UPDATE country SET status = '1' WHERE name = 'Denmark';
You could then then run something similar to disable the Danish zones. Always better to disable than delete.....

Newbie

Posts

Joined
Mon Jul 18, 2011 3:36 am
Location - UK

Post by IsoNick » Sat Jul 23, 2011 12:58 pm

Thanks for the SQL tip. Will give it a try, to see if it's working. But the best, would be to remove the boxes completely.

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by uksitebuilder » Sat Jul 23, 2011 3:10 pm

You could maybe replace those boxes with hidden input fields of the same names instead and pre-fill their values to match

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by IsoNick » Sat Jul 23, 2011 3:12 pm

Would you hide them with CSS?

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by uksitebuilder » Sat Jul 23, 2011 3:19 pm

Code: Select all

<input type="hidden" name="country_id" value="57"> 
<input type="hidden" name="zone_id" value="903">
Delete the original select inputs from your tpl and pop the above hidden inputs next to postcode input so you can shorten the form a little

I selected Arhaus for the zone because it is a required field.

Further coding could sort this out proplery, but I have little time today I'm sorry

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by IsoNick » Sat Jul 23, 2011 3:25 pm

It's okay. Thanks for the work around. Will give it a try.

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by freshbreeze » Sun Jul 24, 2011 9:11 pm

I also want to remove the region/ state drop down as it really isn't necessary for most of the EU countries inc UK.

I have disabled all countries except EU countries and disabled all zones in database using phpmyadmin. But the Region / State selector in shipping estimator & checkout requires you to choose a state called "None" which is pointless. I had hoped this field would not appear if no zones were active. ???

Sorry but I didn't understand UKsitebuilders suggestion :'(

Please can you explain it a bit more?

I also want postcode to be required for checkout addresses but not shipping estimator. Anyone got a nice clean way of doing this too please?

Thanks
1.5.0.5 as well
Last edited by freshbreeze on Mon Jul 25, 2011 12:04 am, edited 1 time in total.

Newbie

Posts

Joined
Mon Jul 18, 2011 3:36 am
Location - UK

Post by IsoNick » Sun Jul 24, 2011 11:47 pm

uksitebuilder wrote:Delete the original select inputs from your tpl and pop the above hidden inputs next to postcode input so you can shorten the form a little
Oh, in which tpl file by the way? More than one?

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by peecha85 » Mon Jul 25, 2011 2:54 pm

Delete the original select inputs from your tpl and pop the above hidden inputs next to postcode input so you can shorten the form a little
didn't work for me- wasn't able to proceed the checkout (continue button didn't respond)

Active Member

Posts

Joined
Tue May 11, 2010 10:28 pm

Post by IsoNick » Mon Jul 25, 2011 2:59 pm

peecha85 wrote:didn't work for me- wasn't able to proceed the checkout (continue button didn't respond)
Oh, good I didn't start to work on the problem yesterday then.

What now then, anyone got other solutions for this annoying issue?

Newbie

Posts

Joined
Wed Jul 20, 2011 6:06 am
Location - Denmark

Post by peecha85 » Mon Jul 25, 2011 6:02 pm

I really don't know how to hide the form fields. I could remove the texts (Fax, Company, Address etc.), but the form fields have to be visible, or else the continue button doesn't work.

I think there should be something deleted not only from .tpl files, but also from related .php files, but I have no idea what exactly

Active Member

Posts

Joined
Tue May 11, 2010 10:28 pm

Post by Goffer » Thu Aug 04, 2011 9:04 pm

Been playing with the exact same thing today.
I would asume that the easiest way is to make the field "Non mandatory" and then hide dropdown in the register.tpl file.
But i dont know how to make the fields mandotory, i can see the tpl file says:

Code: Select all

        <tr>
          <td><span class="required">*</span> <?php echo $entry_zone; ?></td>
          <td><select name="zone_id">
            </select>
            <?php if ($error_zone) { ?>
            <span class="error"><?php echo $error_zone; ?></span>
            <?php } ?></td>
        </tr>
about the dropdown, and i guess its the "required" class that makes it mandotory? wild guess actually.

Newbie

Posts

Joined
Sun Jun 19, 2011 3:28 pm

Post by thufir » Fri Mar 09, 2012 8:18 am

First im sorry to ressurrect this post, but i am in the same situation as the OP.

By browsing around the forums, ive found some solutions to the problem, and managed to remove the dropdown asking for Region and State in the checkout, but only for the payment address part, if i try to do the same in the shipping address part, and under the create user part, the javascript for some reason simply refuses me to press "next".
I believe it is because the javascript is used to check if the fields are set. Im not very good at javascript, so i wonder if anyone could give me a hint or two to get myself in the right direction?

Im using version 1.5.1.3

Thank you all in advance
Thufir

Newbie

Posts

Joined
Sun Jan 29, 2012 5:33 am
Who is online

Users browsing this forum: No registered users and 22 guests