SERACH THE NAME : http://maplestory.nexon.net/Ranking...ld=0&job=0&pageIndex=1&key=XXXXXX&search=true XXXXXX= character name Obtaining results example SuperMario4 Now obtain image from line 447 output if' alt=""/></td> </body
could you be a bit clear? if you want to extract a URL of an image from a page, then it is possible, but be clear, your post seems jumbled up regards
Ok the imput box is this the name will be put were xxxxx are so in this case i want to search for jeffrey it would be like this Then on line 447 of the site the image is given in this format
Try this out: $keyword='Jeffrey'; $data=file_get_contents('http://maplestory.nexon.net/Rankings/OverallRanking.aspx?type=overall&world=0&job=0&pageIndex=1&key='.$keyword.'&search=true'); $pattern='|src\=\'(.*?)\' alt\=""/></td>\s*\n*\s*<td class\="char\-name">\s*'.$keyword.'</td>|'; preg_match($pattern,$data,$match); $img_url=$match[1]; PHP:
It works perfect for me, what error are you getting? It is possible that file_get_contents() is blocked on your server.
Would'nt say blocked, disabled. Can check if its been disabled via function_exists() or ini_get('disabled_functions') Furthermore if thats the case and you can't do anything to rectify it, consider using cURL.