addressalign-toparrow-leftarrow-rightbackbellblockcalendarcameraccwcheckchevron-downchevron-leftchevron-rightchevron-small-downchevron-small-leftchevron-small-rightchevron-small-upchevron-upcircle-with-checkcircle-with-crosscircle-with-pluscrossdots-three-verticaleditemptyheartexporteye-with-lineeyefacebookfolderfullheartglobegmailgooglegroupsimageimagesinstagramlinklocation-pinm-swarmSearchmailmessagesminusmoremuplabelShape 3 + Rectangle 1outlookpersonJoin Group on CardStartprice-ribbonImported LayersImported LayersImported Layersshieldstartickettrashtriangle-downtriangle-uptwitteruseryahoo

Re: [php-49] sql error

From: Ian D.
Sent on: Monday, February 18, 2013 2:08 PM
To be honest, if the site is for a paying client or is going to process more than a handful of transactions a year, I'd be tempted to say it's kind of irresponsible to build an eCommerce app from scratch, unless you really know what you're doing. There are so many security issues to worry about, even if you're not going for full PCI compliance.

It'd probably be ok if you're just building the product database and redirecting offsite for payment collection and processing, but if you're touching the customer's credit card or personal info, you're asking for trouble.

Regardless, why re-invent the wheel when things like Shopp, OsCommerce and Magento already exist?

If you're just doing it for fun/education, though, then that's another story.

On 02/18/[masked]:43 PM, max steinmetz wrote:
Hello, newb here with a question.

I'm attempting to build a simple shopping cart, this is my first time doing so and I am getting an error message which reads as follows:

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in

Any help would be greatly appreciated as I'm google this error messag a bit and seen so many possible options that my mind turned to goop.

Again thank you for any help/direction possible.

This is the code starting with line #42

<div class="container">
<span class="top-label">
<span class="label-txt">PRODUCTS (TAKE Displayed things from here)</span>
<div class="content-area">
<div class="content drag-desired">
$result = mysql_query("SELECT * FROM internet_shop");
echo '<div class="product"><img src="_img/products/'.$row['img'].'" alt="'.htmlspecialchars($row['name']).'" width="128" height="128" class="pngfix" /></div>';
<div class="clear"></div>
<div class="bottom-container-border">

Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by max steinmetz ([address removed]) from The Seattle PHP Meetup Group.
To learn more about max steinmetz, visit his/her member profile
Set my mailing list to email me As they are sent | In one daily email | Don't send me mailing list messages

Meetup, POB 4668 #37895 NY NY USA 10163 | [address removed]

Our Sponsors

  • PluralSight

    PluralSight subscriptions for developer training

  • O'Reilly

    Disc Code: PCBW is good for 40% off print and 50% off ebooks and videos

  • JetBrains PhpStorm

    Occasional free licenses to raffle off at meetups

People in this
Meetup are also in:

Sign up

Meetup members, Log in

By clicking "Sign up" or "Sign up using Facebook", you confirm that you accept our Terms of Service & Privacy Policy