Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

PHP Stock Checker & Price Comparison

Featured Replies

Hey all,

 

I have decided to take on a rather large project for my third year final project, and I intend to, well at least try to learn php from the ground up and complete a stock checker script that also includes pulling in the prices. Examples of what I want to do (but on a smaller scale and for just one product) are websites like http://www.wiipreorder.co.uk/ and http://www.wii-consoles.co.uk/ - I know this one is done in ASP, but can and is done in PHP too! :D

 

As I have to build my PHP knowledge from the ground up, I really dont know where to begin, so wondering if anyone out there has any advice as to how I at least begin with such a task. I have done some research online, and found someone asking for another to do something like this freelance, and he mentioned it would take an experienced coder about 2 to 3 hours to complete, now I have a whole academic year to learn php from the ground and complete this, and ofcourse put it online and style it all using CSS and HTML.

 

I just really need some advice as to what is required for such a task, and what sort PHP skills I should be learning. I do have a book on PHP, and have nearly finished chapter 1!

 

Any help or advice you give would be really appreciated!!

 

Thanks

 

wadet

  • 2 weeks later...
  • Author

No one have any advice ? I've yet to even know if I can even complete such a project! :(

What exactly do you want your script to do? If it's just a case of fetching prices from existing sources and then displaying them then that's pretty simple. However have you thought about the details? Are you storing it in a database after you've fetched it? Where are you getting the data from, is it from a HTML page (in which case you'll have to scrape it) or from an XML source?

 

If you list everything you need it to do, in some detail then I'll be able to offer more assistance.

  • Author

Ah fantastic mate! Thanks for you reply. Right I shall get a list up soon, I want something similier to those sites I linked to as examples, but I will make a list of the things I definately want. I was kind of looking for some direction as to what I should be learning in PHP to complete such a task, I need a sort of base of PHP knowledge, to then understand how these websites work and what sort of PHP techniques are used. Hope you understood that, hah!

 

 

 

What exactly do you want your script to do? If it's just a case of fetching prices from existing sources and then displaying them then that's pretty simple. However have you thought about the details? Are you storing it in a database after you've fetched it? Where are you getting the data from, is it from a HTML page (in which case you'll have to scrape it) or from an XML source?

 

If you list everything you need it to do, in some detail then I'll be able to offer more assistance.

  • Author

Right, got a few things down as to what I would like it to do it.

 

 

1. Different retailers all in a list

2. Price + stock status is pulled from retailers item page, displayed on website from least to most expensive.

3. Prices and stock status update regularly, every minute perhaps..

4. Section for a description of the item, and what it includes., if any extras (not sure if this is put in by me or see if some data can be pulled from retailers item page.

5. possible to include each retailer link(if customer wants to go to retailers website to buy) to then link through an affiliate marketing website, so I earn a little commision :p an incentive for me to complete this project :D

 

thats what ive got so far, examples include wii-consoles.co.uk & wii-bundles.co.uk

 

I understand these are coded in ASP, though ive read and know it has been done in PHP. there is a script available to buy somewhere. maybe be usefull to work from.

 

Cheers

Right, got a few things down as to what I would like it to do it.

 

 

1. Different retailers all in a list

2. Price + stock status is pulled from retailers item page, displayed on website from least to most expensive.

3. Prices and stock status update regularly, every minute perhaps..

4. Section for a description of the item, and what it includes., if any extras (not sure if this is put in by me or see if some data can be pulled from retailers item page.

5. possible to include each retailer link(if customer wants to go to retailers website to buy) to then link through an affiliate marketing website, so I earn a little commision :p an incentive for me to complete this project :D

 

thats what ive got so far, examples include wii-consoles.co.uk & wii-bundles.co.uk

 

I understand these are coded in ASP, though ive read and know it has been done in PHP. there is a script available to buy somewhere. maybe be usefull to work from.

 

Cheers

 

I can't help on the PHP stuff as I'm only a beginner myself but I wouldn't advise buying a pre-made script for it. If you did, you would only be copying from it and wouldn't really be learning. It's what I do with books, I copy it and think great I'm learning but when it comes to me making something I just don't know where to start because I haven't looked at the PHP properly and I'm just copying it. But that could just be me.

 

With regards to the project the best way to do it is to break it up into small little assignments like for example you know you will need a login so make that one assignment etc and then it all comes together.

  • Author

Cheers for the reply mate! Yeah I know waht you mean, it does end up being copying, I have since spoken with my project supervisor, and I simply need to start looking at it from the ground up and come up with my own method.

 

So at the moment I am simply looking how I would go about getting code from another webpage to be displayed on mine. My supervisor mentioned I may need to also incorporate javascript. I shall see. I need to simply start researching!

  • Author

I have come across cURL, which is used to pull data, could anyone say if this is what I should be looking at to begin with?

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.