Vmi90 Posted November 26, 2006 Share Posted November 26, 2006 I want to get data thats on a certain website and echo it onto my site. How would i be able to do that? Quote Link to comment Share on other sites More sharing options...
theironchef Posted November 26, 2006 Share Posted November 26, 2006 its all inthe source correct?jsut steal the source and have it search for what you want... heres something i've made to copy unreal tournament stats...[code]<?/// PLAYER STATUS $output = "";$lines = file('http://www.shadyserver.com/stats/?p=players&filter=games&sort=DESC'); $linenumber = 0;// in the source the value is located between "center"> and Score.... that the score value to i copied it foreach ($lines as $line_num => $line){ $line = str_replace('<td class="grey" align="center">','Score: ', $line); $line = str_replace('</td>', ' ', $line); $output.= htmlspecialchars($line)."<br>";}if($line_num == ($linenumber+3)){ $line = str_replace('<td class="grey" align="center">','Frags: ', $line); $line = str_replace('</td>', ' ', $line); $output.= htmlspecialchars($line)."<br>";}[/code]... i dunno i wrote this a long time ago... you can see it work at my site www.shadyserver.com ... in the otp right of the page put in TheIronChef .... the code is shown on the right side of the page ... Quote Link to comment Share on other sites More sharing options...
Vmi90 Posted November 26, 2006 Author Share Posted November 26, 2006 would it be different if i didnt want the entire line? Its like....one line in a certain column :-\ Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.