Can not view product details

6 views
Skip to first unread message

Chris Quang

unread,
Oct 20, 2008, 4:42:55 AM10/20/08
to KiweeCommerce Forum
I had a list 3 products in my Products catalog page with their sort
description. when clicked on the product name link to view product
details, I have the following error:
---------------------------

Warning: Call-time pass-by-reference has been deprecated; If you would
like to pass it by reference, modify the declaration of [runtime
function name](). If you would like to enable call-time pass-by-
reference, you can set allow_call_time_pass_reference to true in your
INI file in modx\assets\snippets\shoppingCart\eCart\classes
\gButton.php on line 94

Warning: Call-time pass-by-reference has been deprecated; If you would
like to pass it by reference, modify the declaration of [runtime
function name](). If you would like to enable call-time pass-by-
reference, you can set allow_call_time_pass_reference to true in your
INI file in modx\assets\snippets\shoppingCart\eCart\classes
\gButton.php on line 94
« MODx Parse Error »
MODx encountered the following error while attempting to parse the
requested resource:
« `` is not numeric and may not be passed to makeUrl() »
------------------------

Chris Quang

unread,
Oct 20, 2008, 4:53:06 AM10/20/08
to KiweeCommerce Forum
If I inserted picture for the product manually (did not use the
Tinymce),in this case the following error occurred:
---------------------------
« MODx Parse Error »
MODx encountered the following error while attempting to parse the
requested resource:
« PHP Parse Error »

PHP error debug
Error: Division by zero
Error type/ Nr.: Warning - 2
File: modx\assets\snippets\shoppingCart\kiwee.class.php
Line: 413
Line 413 source: $height_ratio = $row['heightB'] /
$img[$masterNameArray[$row['master_img_id']]]['height'];
---------------------------

is there any body catched this error?

Richard Northcott

unread,
Oct 20, 2008, 2:09:40 PM10/20/08
to kiweec...@googlegroups.com
Hi Chris

I previously haven;t really done anything under the Catalog section so I don't know if I can help with that (I have been working on this area for the new version).

The error you mentioned to do with the Division by Zero, etc. can you tell me what put into the Image Properties for the Product and if one of those Image types related to a new image type setup under the Image section and if so whether it was a Primary of Secondary image (maybe easier to do screenshots but up to you).



Richard
Message has been deleted

Chris Quang

unread,
Oct 22, 2008, 10:48:36 AM10/22/08
to KiweeCommerce Forum
Sorry Richard, i was out of Modx yesterday. this is exactly what I
have:
[IMG]http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg[/IMG]

Richard Northcott

unread,
Oct 26, 2008, 9:28:31 AM10/26/08
to kiweec...@googlegroups.com
Hi Chris

sorry i've been out of the loop for a while.

can you tell me whether you have added another Image item (under the image category),
and can you give me the details you have entered into each field when selecting Edit Images under the Product Section

or is this something that has been put into the content area of the Product?

Richard

Chris Quang

unread,
Oct 26, 2008, 11:25:10 PM10/26/08
to KiweeCommerce Forum
Hi Richard,

How are you this Monday? I have some extra information on my error:

1. In the Image Categories, I have added 2 items named demo1 and demo2
with the same content as following:
---------------------
name : demo picture
description : this is test picture
width(max) :200
height(max):300
Master : none
HTML Class : <null>
-------------------
2. In the Edit Images under the Product Section, the information likes
this:
http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg
3. In the content area of product, the following content had been
inserted:
"Tennis ball Tennis ball "

Chris


On Oct 26, 8:28 pm, "Richard Northcott" <richard...@gmail.com> wrote:
> Hi Chris
>
> sorry i've been out of the loop for a while.
>
> can you tell me whether you have added another Image item (under the image
> category),
> and can you give me the details you have entered into each field when
> selecting Edit Images under the Product Section
>
> or is this something that has been put into the content area of the Product?
>
> Richard
>
> On Wed, Oct 22, 2008 at 2:48 PM, Chris Quang <chienqu...@gmail.com> wrote:
>
> > Sorry Richard, i was out of Modx yesterday. this is exactly what I
> > have:
> > [IMG]http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg[/IMG]<http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg%5B/IMG%5D>

Richard Northcott

unread,
Oct 27, 2008, 7:44:44 AM10/27/08
to kiweec...@googlegroups.com
Hi Chris

I would recommend that the demo image files (demo1 and demo2 - not sure why you have 2) are actually set to use the primary image as from the screenshot this is in effect what you are doing - as you are giving very image type the same image reference.

With the demo1 (and demo2 if needed) set to primary, go to the Product Edit Image and set the Primary image to the path to the the image and its actual width and height (which you have done). No need for the secondary image unless you have a image item that requires it. the cart and the checkout are just ALT tag references so just need descriptive text and not the path as they are both assigned to the Primary image item (and will scale the image accordingly).

The demo1 item will no longer need the image path (like the cart and checkout) as it is reliant of the Primary image for this and it has already had its width and height set under the image section so it only needs an ALT tag (should you wish to).

The final bit (which probably needs a better way of being adjusted) is that you need to make sure that the IMAGE chunk is altered to call the right image name (its probably set to Basic at the moment so replace with demo1 or whatever the image name is).
If you don't change you should get the no image pic so I am a bit lost as to which page you were in when you got there error/code that you did - was this the products own page (and if so what is the chunk it is calling on - this should be {{ProductTemplate}} which is called from the Kiwee-ProductTemplate2 template), or was it the Catalog page which I haven't (in this version) addressed.


Richard

Chris Quang

unread,
Oct 28, 2008, 11:56:37 PM10/28/08
to KiweeCommerce Forum
Thanks my friend,

I added demo1 and demo2 field in the Image section because my product
needed 2 more pictures, but I found that the demo1 and demo2 didn't
have any URL field.
any suggestion for this feature?

Chris

On Oct 27, 6:44 pm, "Richard Northcott" <richard...@gmail.com> wrote:
> Hi Chris
>
> > <http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg%5B/IMG%5D>

Richard Northcott

unread,
Oct 29, 2008, 6:19:47 AM10/29/08
to kiweec...@googlegroups.com
Hi Chris

If you want them touse different image files then I would siggest that demo1 use the Primary type and demo2 use the Secondary type (they don't have to but it means that the Primary will also feed to the Cart and Checkout thumbnails that are displayed).
If you use the Primary and Secondary then these 2 are where the image urls are input (under the Product section - edit image properties). If you don't use either the Primary or Secondary the Primary will still require an image url as this type is called on to 'format' thumbnails for both the Cart and Checkout. The URL can be added for both demo1 and demo2 (if they are not set to either Primary and Secondary).

If you are unsure of this please provide the image name's also advising which will be the main image (that which you want to be shown in the Cart and Checkout) and I will try to explain what should go where (ohh, and can you let me know there width and height in pixels).

If i have not answered your question then please let me know.


Richard

Chris Quang

unread,
Oct 30, 2008, 5:36:59 AM10/30/08
to KiweeCommerce Forum
Hi Richard,

First of all, I would like to thank you for all your hard works but I
think i need give more details about my idea.
I added the demo1 and demo2 picture type in order to make my product
appear more plentiful besides the Primary and Secondary picture. so ,
after specifying the URL for the Primary and Secondary picture, I can
not find any field to add URL for my extra demo1 and demo2.

Chris

On Oct 29, 5:19 pm, "Richard Northcott" <richard...@gmail.com> wrote:
> Hi Chris
>
> If you want them touse different image files then I would siggest that demo1
> use the Primary type and demo2 use the Secondary type (they don't have to
> but it means that the Primary will also feed to the Cart and Checkout
> thumbnails that are displayed).
> If you use the Primary and Secondary then these 2 are where the image urls
> are input (under the Product section - edit image properties). If you don't
> use either the Primary or Secondary the Primary will still require an image
> url as this type is called on to 'format' thumbnails for both the Cart and
> Checkout. The URL can be added for both demo1 and demo2 (if they are not set
> to either Primary and Secondary).
>
> If you are unsure of this please provide the image name's also advising
> which will be the main image (that which you want to be shown in the Cart
> and Checkout) and I will try to explain what should go where (ohh, and can
> you let me know there width and height in pixels).
>
> If i have not answered your question then please let me know.
>
> Richard
>
> >http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg%5B/IMG%5D>

Richard Northcott

unread,
Oct 30, 2008, 6:28:11 AM10/30/08
to kiweec...@googlegroups.com
Hi Chris

OK think I understand now :)

The Primary always needs to be completed.

demo1 can also be the same as the Primary (so that the Cart/Checkout image has some image in the Product page that keeps the whole thing tied together visually) - up to you whether you set the demo1 as being a Primary image or not.

demo 2 will not be a Primary (or Secondary image) and thereofre you will be able to put its own url in under the Product section (Edit Image Properties), and follow for any other images (demo3, demo4, ....)

In the Chunk 'ProductTemplate (which is what your product should be defaulting to to use) you will see that there is already a reference to the IMAGE chunk. You can create a new chunk reference for each image or one for a group - up to you in how you want to format/structure your HTML.
You will need to edit the chunk IMAGE and create a new chunk (or chunks) if you have added in the 'ProductTemplate' (eg. IMAGE2).
The IMAGE chunk(s) need to have the end parameter matching the name of the image your calling

eg. for demo1
[[kiwee? &elem=IMAGE&img_name=demo1]]

eg. for demo2
[[kiwee? &elem=IMAGE&img_name=demo2]]


Hope this helps.


Richard

Chris Quang

unread,
Oct 31, 2008, 5:21:20 AM10/31/08
to KiweeCommerce Forum
Richard,

ahhh, it fixed my pictures.
Thanh you very much!

Chris

On Oct 30, 5:28 pm, "Richard Northcott" <richard...@gmail.com> wrote:
> Hi Chris
>
> OK think I understand now :)
>
> The Primary always needs to be completed.
>
> demo1 can also be the same as the Primary (so that the Cart/Checkout image
> has some image in the Product page that keeps the whole thing tied together
> visually) - up to you whether you set the demo1 as being a Primary image or
> not.
>
> demo 2 will not be a Primary (or Secondary image) and thereofre you will be
> able to put its own url in under the Product section (Edit Image
> Properties), and follow for any other images (demo3, demo4, ....)
>
> In the Chunk 'ProductTemplate (which is what your product should be
> defaulting to to use) you will see that there is already a reference to the
> IMAGE chunk. You can create a new chunk reference for each image or one for
> a group - up to you in how you want to format/structure your HTML.
> You will need to edit the chunk IMAGE and create a new chunk (or chunks) if
> you have added in the 'ProductTemplate' (eg. IMAGE2).
> The IMAGE chunk(s) need to have the end parameter matching the name of the
> image your calling
>
> eg. for demo1
> [[kiwee? &elem=IMAGE&img_name=demo1]]
>
> eg. for demo2
> [[kiwee? &elem=IMAGE&img_name=demo2]]
>
> Hope this helps.
>
> Richard
>
> > > >http://i181.photobucket.com/albums/x132/chienquang/Erros.jpg%5B/IMG%5D>

Richard Northcott

unread,
Oct 31, 2008, 9:08:05 AM10/31/08
to kiweec...@googlegroups.com
Thats OK :)
Reply all
Reply to author
Forward
0 new messages