eCommerce problem

Permalink 1 user found helpful
Hi Guys

I have posted this in the support for the add-on so apologies for posting here too but was hoping someone who has purchased the add-on may have came across this problem...

I have used the eCommerce add-on on a clients site but when I go to the billing page the state/provence drop down has no content? No matter which contry I select it stays empty.

Because of this the form can not be submitted as it keeps coming up saying the address field is required.

Hope someone can help as the site was suppose to go live this weekend.

Just so you can see the page...

http://www.sleeping-giants.net/newsite/downloads/......

Add to cart and go to checkout to see the problem.

senshidigital
 
Mnkras replied on at Permalink Reply
Mnkras
in my console i get

Uncaught ReferenceError: ccm_setupAttributeTypeAddressSetupStateProvinceSelector is not defined
senshidigital replied on at Permalink Reply
senshidigital
any idea whats causing it?
senshidigital replied on at Permalink Reply
senshidigital
Should this atribute not be set up already by the core or the add-on?
Mnkras replied on at Permalink Reply
Mnkras
it should be, but it looks like it bugged out or something, my recommendation is reinstall,
senshidigital replied on at Permalink Reply
senshidigital
I did and did not work. Funny thing is I installed it on a dev site and it worked fine so I am wondering in another add-on is conflicting with it.

Will do some testing.
senshidigital replied on at Permalink Reply
senshidigital
hmmm OK seems to be when I use the default theme all is OK. When I switch to my theme it does not work. My theme ,as far as I can tell, does not have anything I can see that would conflict with it. This is a strange one.
senshidigital replied on at Permalink Reply
senshidigital
Weird thing is I can see all the options in the source code but they just don't display?!?
senshidigital replied on at Permalink Reply
senshidigital
It was something to do with the header.php. I added some of my own code to it which seemed to stop it from working.

thanks for the feedback. Appreciated.

Once again the community rocks!
admin replied on at Permalink Reply
I have the same problem. Could you be more specific about what it is that needs to be in (or out) of the header? Thanks.
senshidigital replied on at Permalink Best Answer Reply
senshidigital
One thing you need to do is your view.php file has to contain:

<?php 
defined('C5_EXECUTE') or die(_("Access Denied."));
$this->inc('elements/header.php'); ?>
         <?php 
         print $innerContent;
         ?>


You may find your billing pages then have two header files. If so take out the '<?php $this->inc('elements/header.php'); ?>' from the core-commerce single page templates.

This seems to work depending on the theme/design used.
admin replied on at Permalink Reply
thanks, that worked perfectly
senshidigital replied on at Permalink Reply
senshidigital
Nice one!

Glad to help
drumrby replied on at Permalink Reply
drumrby
I'm having the same problem. Where exactly is that header code supposed to go?
JohntheFish replied on at Permalink Reply
JohntheFish
Its referring to the files from your theme. view.php is the file in the theme that is used for single pages.
See:
http://www.concrete5.org/documentation/developers/pages/single-page...
http://www.concrete5.org/documentation/developers/pages/themes...
drumrby replied on at Permalink Reply
drumrby
Thanks John for the reply. I guess I should have been more specific. Do I put it in the veiw.php in my theme fold or in the core-commerce single pages folder? Where is the document is that code supposed to go (head, body, specific location in the body)?
Steevb replied on at Permalink Reply
Steevb
That code IS the view.php file.

In your theme folder you a need file called 'view.php' and that code should be in it.

See below;

<?
defined('C5_EXECUTE') or die("Access Denied.");
$this->inc('elements/header.php'); ?>
<div id="central" class="no-sidebar">
      <div id="body">   
         <?
print $innerContent;
         ?>
      </div>
      <div class="spacer">&nbsp;</div>      
   </div>
<? $this->inc('elements/footer.php'); ?>



Hope that helps

Steev
drumrby replied on at Permalink Reply
drumrby
Thanks Steev for the help. When I use that code as my view.php file, I get completely screwed up pages. When I now navigate to the billing address page I get several PHP warnings. Failure to include elements/header.php and footer.php. I also lose all of my design I have in the previous view.php file. I have attached a link to the billing address page. Any help would be greatly appreciated.

http://letsgetrockin.com/index.php/checkout/billing/...
Steevb replied on at Permalink Reply
Steevb
Do you have a folder called elements?

Do you have header.php and footer.php in that folder?
JohntheFish replied on at Permalink Reply
JohntheFish
As Steev said
JohntheFish replied on at Permalink Reply
JohntheFish
Is the view.php you have created in the same directory within the theme as default.php? Does it have a subdirectory called elements? and in that subdirectory are there files header.php and footer.php? What other files are in that directory?
Steevb replied on at Permalink Reply
Steevb
Sorry John,

You got there first

I'm off now for a shower, good luck.