900 viewsMern Amazona
0 Comments

When I am creating a product page, the page that is returned is a 404 page not found error. How do I fix this? This is in reference to the
Nextjs ECommerce Tutorial For Beginners 2022 [Next.js, MongoDB & Tailwind]

Bassir Changed status to publish November 26, 2023

I also notice that my img tags (src and alt) read undefined as well

hello there,

404 error comes from here:

https://github.com/basir/next-tailwind-amazona/blob/main/pages/product/%5Bslug%5D.js#L16

if the product slug does not exist you get this error.

check the db to see if you have product with that slug.

also share the screenshot of the 404 error please.

Bassir Answered question October 21, 2022