If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.
I just found the issue - some old code was in either the attribute machine or image machine template areas. Removed those and the problem disappeared. I will have to experiment with Frameworks to duplicate a Page next time to avoid errors in copy/paste to create a new Page.
Keep us posted. I just recently had an issue creating a new PROD template - seems that the Product Display Layout Image Machine items that get entered into those fields are different from what I have been used to. It tripped me up. Martin at Miva Support got me straightened out
I just found the issue - some old code was in either the attribute machine or image machine template areas. Removed those and the problem disappeared. I will have to experiment with Frameworks to duplicate a Page next time to avoid errors in copy/paste to create a new Page.
Thanks Leslie, good thought, but that's not fixing the weird quirk I'm experiencing. My new Page—which I created by just copying code from PROD into a new page (complete w/ the same items selected)—injects some weird JS at the top of the page. If I inspect the page, the weird JS code does show up just below the js-PROD code line. Here is what appears...
} );
If I go back to the actual PROD page, this code disappears from the top of the page. I can't find what's different!
Thanks Leslie, good thought, but that's not fixing the weird quirk I'm experiencing. My new Page—which I created by just copying code from PROD into a new page (complete w/ the same items selected)—injects some weird JS at the top of the page. If I inspect the page, the weird JS code does show up just below the js-PROD code line. Here is what appears...
} );
If I go back to the actual PROD page, this code disappears from the top of the page. I can't find what's different!
I am trying to make a copy of my PROD page as a base to create an alternate display page. But, I cannot find a way to duplicate a Page! I tried just copying and pasting all the template code and making sure all items are assigned the same, but something is still missing. I just want to make an exact copy of the existing PROD page and edit from there. Exporting a Page is not an option... do I use Frameworks? If so, how? I'm hesitant to play with Frameworks for fear of messing up something on my site. Thanks!
You are on the right track. You may be getting tripped up by the usage of the PROD code in other places. In your Alternate Page Template - change your body ID to (I'm guessing here) js-PROD (yes, you'll need to hard code it). That list body ID js-PROD triggers a lot of javascript for the PROD page (I've found it easier to change the body ID than to add additional javascript). The PROD shows up in a couple a places in the Global Footer, you'll most likely need to include your page code there too to duplicate what the PROD page is doing.
I am trying to make a copy of my PROD page as a base to create an alternate display page. But, I cannot find a way to duplicate a Page! I tried just copying and pasting all the template code and making sure all items are assigned the same, but something is still missing. I just want to make an exact copy of the existing PROD page and edit from there. Exporting a Page is not an option... do I use Frameworks? If so, how? I'm hesitant to play with Frameworks for fear of messing up something on my site. Thanks!
We would typically use a single product page and use custom fields and template logic to achieve the result you're looking for, however an alternate PROD page is a good solution as well.
When you create your alternate version of PROD, copy the main template as a starting point because it will auto assign some of the items for you. Then, pull up the original PROD screen and add any missing items to the new PROD page. Lastly you'll want to copy the template / settings of all the PROD components (image machine, Product Layout, etc). This should give you an identical copy of PROD which you can then start to modify.
Would be a big help if there was a "clone" button for any page. It should clone everything including the assigned items, except, probably, URLs
We would typically use a single product page and use custom fields and template logic to achieve the result you're looking for, however an alternate PROD page is a good solution as well.
When you create your alternate version of PROD, copy the main template as a starting point because it will auto assign some of the items for you. Then, pull up the original PROD screen and add any missing items to the new PROD page. Lastly you'll want to copy the template / settings of all the PROD components (image machine, Product Layout, etc). This should give you an identical copy of PROD which you can then start to modify.
I occasionally create a new page by copying an existing one. It does tend to be harder than you might think. Besides copying the templates, you also need to click to the Items list, and make sure that you've assign all the Items that were assigned to the original page.
What you describe here is do'able, but not without a little help from a module for the parts where you restrict the customer to purchasing only one of the product. I think Toolbelt provides a "pre-action" feature that you can use for that. My own "Modulator" module does the same thing, with a few extra bells and whistles that might be helpful.
Did you make sure you assigned all the little Items. I always seem to miss one or two. When you create an alternate page, the body tag with be using the Page code. You may need to change it in the template. For example, instead of body id="js-&mvte:page:code;" change it to body id="js-PROD" - that will at least get you the javascript for the page. That "may" fix the image problem. You may need to make sure that the Image Type are assigned to the template. Also check pesky things like the Attribute Machine section - you may have to fill some of the stuff in too. Also make sure you copy Head Template (for the Attribute Machine settings) from your default PROD Page. I think that when you create a new PROD Page template it generates code that is ever so slightly different.
I am trying to build an alternative display page for a product and cant seem to get it working properly. My goal is to setup the product so it mirrors the default display except it wont allow you to purchase more than one at a time, if you have already purchased one it will tell you that you already purchased it and not allow you to purchase again, and lastly if you are not logged into an account it will tell you that you must be signed into an account before you can purchase. The goal is to link this item to a specific user account and allow only one purchase per account. Currently i have this functionality working inside the "PROD" page. However it feels really hacky to have if statements on PROD page looking for one specific item.
In my endeavours on creating an alternative display page i have found it just breaks things despite copying the PROD page exactly. Things like the products images stop being populated, the add to cart button when clicked says "Invalid token", and the Description / Specifications / Reviews tabs (normally located below the product images) is inside the add to cart Div. If anyone has any experience with working with these Alternate Display Page any tips would be appreciated. Also i must note that i don't have the page anymore because i ended up getting frustrated and just doing the 'hacky' if statement inside the PROD page. Thanks again!
Last edited by Beefy Nugget; 01-20-18, 12:35 PM.
Reason: typo
Leave a comment: