close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Products Page not loading Cart Page

Thread began 12/04/2013 6:53 am by phill401410 | Last modified 12/11/2013 12:15 pm by Jason Byrnes | 5268 views | 17 replies |

phill401410

Products Page not loading Cart Page

Jason,
I am setting up an Ecomm site. The first page I made was a Product page using your tutorial, http://www.webassist.com/tutorials/Getting-started-with-MySQL-and-dynamic-websites. The second page I made was a cart page using http://www.webassist.com/tutorials/Add-a-shopping-cart-eCommerce-Series.

I created an Add to Cart Button and when I test products.php I get the error message; Notice: Undefined variable: ATC_itemQuantity in C:\xampp\htdocs\ItsNotHardTo\products.php on line 100. COuldn't find a solution in the forums. Thanking you for your help.

Files attached.

Attached Files
Ecomm-04DEC13.ZIP
Sign in to reply to this post

Jason ByrnesWebAssist

the where clauase of your recordset is not valid:
WHERE ProductName > '$50.00'


the product name is a text column, you cannot perform math function on text.

Greater than is a math function, one text value cannot be Greater than another text value.

the greater than comparison can only be performed on numbers.

This means your recordset is empty which is causing the add to cart function to fail, since there are no items in the recordset to lookup.

Sign in to reply to this post

phill401410

Products Page not loading Cart Page

Jason
Thank you for your prompt reply
I deleted WHERE ProductName > '$50.00' from the recordset
get this error
Notice: Undefined variable: ATC_itemQuantity in C:\xampp\htdocs\ItsNotHardTo\products.php on line 75
So in eCart Add from Recordset for Quantity I deleted the dynamic vale and set it to default 1
Still getting error
Thanking you in advance again.
Files attached.

_______________________________________________________________________

04DEC13 8:30 pm

Tried eliminating Quantity in Bindings Recordset (rsProducts), Server Behaviors Recordset (rsProducts)
Still throwing Notice: Undefined variable: ATC_itemQuantity in C:\xampp\htdocs\ItsNotHardTo\products.php on line 77
Files attached Ecomm-04DEC13-3.zip

Attached Files
Ecomm-04DEC13-2.ZIP
Ecomm-04DEC13-3.ZIP
Sign in to reply to this post

Jason ByrnesWebAssist

the add to cart form is out side of the repeat region, it comes after the while loop:

<?php } while ($row_rsProducts = mysql_fetch_assoc($rsProducts)); ?>
<form name="eCart1_1_ATC_<?php echo $row_rsProducts["ProductID"]; ?>" method="POST" action="<?php echo $_SERVER["PHP_SELF"]; ?><?php echo (isset($_SERVER["QUERY_STRING"]) && $_SERVER["QUERY_STRING"] != "")?"?".$_SERVER["QUERY_STRING"]:""; ?>">
<input type="hidden" name="eCart1_1_ID_Add" value="<?php echo $row_rsProducts["ProductID"]; ?>" >

<input type="image" src="WA_eCart/Images/Yosemite/Btn4_EN_addtocart.gif" border="0" class="eC_ImageButton" value="Add to Cart" name="eCart1_1_ATC">
</form>



it should be in one of the table cells inside the repeat region.

Sign in to reply to this post

phill401410

Products Page not loading Cart Page

thank you for your response. Got me redirected and I now have the Products Page playing nice with an Items Page per your tut http://www.webassist.com/tutorials/Getting-started-with-MySQL-and-dynamic-websites
Moving forward to getting my head around how to set up a an eCart shopping cart. Kate Forbes tutorials using eCart rewrite DW templates so am a little bit stymied there. More learning curves ahead.

Sign in to reply to this post

Jason ByrnesWebAssist

Glad to hear it is working.

If you have further questions, don't hesitate to post them here.

Sign in to reply to this post

phill401410

Products Page not loading Cart Page

Take you up on that offer.
I can test index.html on the local server and it connects to product.php but throws error Warning: strpos() [function.strpos]: Empty delimiter in C:\xampp\htdocs\ItsNotHardTo\Connections\ItsNotHardTo_Copy_Copy.php on line 15

On the remote server index.html does not connect to product.php, Get Fatal error: No such file or directory in /data/20/1/125/115/1940604/user/2116827/htdocs/ItsNotHardTo/Connections/ItsNotHardTo_Copy_Copy.php on line 25

Could not find anything in Forum on strpos() [function.strpos]: Empty delimiter.
Suspect I have not found right combination in my Dynamic MySQL Connection - ItsNotHardTo_Copy_Copy.php

Files attached. Thanx again.
________________________________________________
12:02pm
Did not have domain assigned to additional connection in ItsNotHardTo_Copy_Copy.php. Remote server now working.

Attached Files
Ecomm-04DEC13-4.ZIP
Sign in to reply to this post

Jason ByrnesWebAssist

in a private message, send a copy of the Connections\ItsNotHardTo_Copy_Copy.php file.

the error on the server:
Get Fatal error: No such file or directory in /data/20/1/125/115/1940604/user/2116827/htdocs/ItsNotHardTo/Connections/ItsNotHardTo_Copy_Copy.php

means that the file:
Connections/ItsNotHardTo_Copy_Copy.php

has not been uploaded.

Sign in to reply to this post

phill401410

Oops, Did not see your reply, I updated #7 with:
12:02pm
"Did not have domain assigned to additional connection in ItsNotHardTo_Copy_Copy.php. Remote server now working."
Thank you.
___________________________________________
12:28

I entered data into all the empty columns in the database and it seems to have stopped throwing the errors. See "On the remote server index.html does not connect to product.php, Get Fatal error: No such file or directory in /data/20/1/125/115/1940604/user/2116827/htdocs/ItsNotHardTo/Connections/ItsNotHardTo_Copy_Copy.php on line 25" in #7.
Even a blind squirrel finds a nut once in awhile.

Copied the wrong error, should be "Warning: strpos() [function.strpos]: Empty delimiter in C:\xampp\htdocs\ItsNotHardTo\Connections\ItsNotHardTo_Copy_Copy.php on line 15"

Sign in to reply to this post

Jason ByrnesWebAssist

So is this all set then? a little confused by the updates.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...