Jump to content

Recommended Posts

Hello everyone, like title says i want to ask you some questions about web shop. Recently i started to develop web shop (php and mysql based) and down the road i came to this problems:

 

1) All products and theirs data are stored in database and the question is how will google see it when i search for some product? How SEO work with database?

2) I will create web shop from scratch without any framework or CMS (i will create my own) so my second question is how to insert social plugins? I insert twitter and google plus on my other site (from theirs developing pages and they work nicely) but facebook like button doesnt work well for me and i dont know why...i did everything from here http://developers.fa...e/plugins/like/ count numbers arent correct, i have metatags, and facebook sdk on page...is there any plugin or class or something that has all social plugins on one place?

3) Every product has image, so i thought to store path into database, but when admin (someone who dont know lot of how that works and need to be very, very simple) want to insert new product it will be needed to create query that will insert image path, so how to create that query?

4) Web shop will have a lot of product, and groups of product so it will needed to be hierarchical database which is problem for me becouse i never done it :) It will have few levels and every level will have sublevels and some sublevels will have their sublevels..and some product will have to be in two or more groups :)

5) I create css breadcrumb but how to do background for it?

I will appriciate some guidings :)

Sorry for grammer mistakes english isnt my native language :)

Edited by thugsr
Link to comment
https://forums.phpfreaks.com/topic/272348-few-questions-about-web-shop-aplication/
Share on other sites

  1. Google doesn't care, or know, about your DB. It just sees the site as your users does. So SEO is as it always has been.
  2. I do not recommend this! First of all you probably do not have the experience and knowledge to make a properly secure solution, and even if you did it would be a LOT more time efficient to use a pre-existing solution. Magento, OpenCart and the Joomla + Wordpress plugins are the most used, and recommended, of these.
    Most existing webshop solutions have plugins for social site integration, as well.
  3. First let me rephrase the answer to question #2: You don't have the necessary experience or knowledge.
    For this you need to learn more about SQL, as you just create the query to insert new data like any other query. The only difference is that you have to retrieve the primary key from the previous query, where you added the product, so that you can add the proper product ID key to the image-table query. You should also read up on transactions, and how they work.
    Though, again, all of this is already taken care of by using a pre-existing solution.
  4. OK...? What's the question?
  5. The CSS background property? I don't quite understand that question.

 

Now, if you want to create a webshop solution for the learning experience: I applaud it! Just don't use it for production, in other words: Don't try to run a live site off of it. Though, you might want to start with something smaller first, just to get some of the basics down. A blog might be a good starting point, as it'll allow to gain experience about associated queries, transactions and categories.

For question 3) i know that, my question was wrong, how to upload image to server and insert path in database...

4) how to do that?

5) No, i designed breadcrumb but now need to make it work, have front end, now i need to write back end for it :)

in my head every question sound nice, but i see that is confusing...

Let's see if we can't expand upon them a bit more then. ;)

  1. I recommend looking at the file uploads page in the PHP manual in order to learn how to do this. Do keep in mind that you will need to add a bit of validation in addition to the code in the examples, to ensure that the file uploaded is indeed a (valid) picture and within the size limits.
  2. This sounds like you'll need a many-to-may relationship, based upon a (basic) multi-level tree node design. In short, you'll one table for the categories which contains the fields "id, name, parent", then you'll need one table to join the items to the categories.
    Searching the net for the two terms should give you a lot of examples, on how to accomplish both.
  3. This one needs planning, and is completely reliant upon how you've structured the data as well as the pages. Mostly the latter. In any case, you need to de-construct the URL to its individual components which relates to an actual page, then re-build it step by step into a breadcrumb for each actual page.

Edited by Christian F.
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.