I was wondering if it is possible, to load content from a website to another. In my case it is about to load the matches, from this website: http://csgolounge.com/ So the matches will automatically, show up on my page when there coming new matches. Is it possible? if yes how?
Asked
Active
Viewed 82 times
-4
-
What did you tried so far ? – Alexandru Guzinschi Apr 02 '15 at 15:13
-
i haven't tryed yet i would like to know how's the best way to do this because i have no idea how to do it, and i want to learn how. – Kristoffer Mikkelsen Apr 02 '15 at 15:15
-
possible duplicate of [How to display content of one site in another using PHP?](http://stackoverflow.com/questions/2735534/how-to-display-content-of-one-site-in-another-using-php) – Whirlwind Apr 02 '15 at 15:18
-
i do not know how to start this, but what kind of code should i use to do something like this? – Kristoffer Mikkelsen Apr 02 '15 at 15:20
-
you are being downvoted becase everybody expect from you to show at least some effort in order to ask for help. And that's how SO works. Just search SO or Google for file_get_contents, iframe etc and I am sure you will find an answer to your question... – Whirlwind Apr 02 '15 at 15:21
-
but i just wanted to know how to start – Kristoffer Mikkelsen Apr 02 '15 at 15:23
-
`file_get_contents()` -> Regex second occurence class `box` -> filter out entire `
` element and disply on your page. Some CSS designing might be needed as well. – icecub Apr 02 '15 at 15:24 -
what lang are you talking about php? @icecub – Kristoffer Mikkelsen Apr 02 '15 at 15:25
-
@icecub can you try to make a example? i have tryed with this script:http://paste2.org/OnU4faYv but dosen't work – Kristoffer Mikkelsen Apr 02 '15 at 23:07
1 Answers
2
Yes it is possible, if you pick your search options then click on search you will get a link in the url bar.
Then on your website just put that url into an iframe
<iframe src="http://csgolounge.com/result?&rdef_index%5B%5D=4753&rquality%5B%5D=0&rdef_index%5B%5D=4745&rquality%5B%5D=0"></iframe>

Dan
- 96
- 5
-
But this don't show the matches i don't understand this answer. the search in their site is for items only – Kristoffer Mikkelsen Apr 02 '15 at 15:38
-
well there is a bet page, so you can link that or if you want specific matches you can just grab their link.. e.g. http://csgolounge.com/match?m=2960 and put in the src="". – Dan Apr 02 '15 at 15:45
-
if you want to actually scrape their data, then you will need to use file_get_contents() and rip out the bits you want. – Dan Apr 02 '15 at 15:46
-
-
-
you will need to search through the $homepage for the bits you need and do what you want with them. – Dan Apr 02 '15 at 15:48
-