에 나는 (제거 게시자 ID, 참고) 사실에서 샘플 API를 사용하고 있습니다 : http://api.indeed.com/ads/apisearch?publisher=ID&q=java&l=austin%2C+tx&sort=&radius=&st=&jt=&start=&limit=&fromage=&filter=&latlong=1&co=us&chnl=&userip=1.2.3.4&useragent=Mozilla/%2F4.0%28Firefox%29&v=2실제로 API는 로컬 호스트에서 작동하지만 라이브 서버
그것은 simplexml_load_file를 사용하여 로컬 호스트에서 작동합니다. 하지만 라이브 서버에서 테스트 할 때 false를 반환합니다. 뭐가 문제 야? https://ads.indeed.com/jobroll/xmlfeed
ini_set('allow_url_fopen ','ON'); $xml = simplexml_load_file("http://api.indeed.com/ads/apisearch?publisher=ID&q=java&l=austin%2C+tx&sort=&radius=&st=&jt=&start=&limit=&fromage=&filter=&latlong=1&co=us&chnl=&userip=1.2.3.4&useragent=Mozilla/%2F4.0%28Firefox%29&v=2"); var_dump($xml);
라이브 서버에서 'simplexml'을 사용할 수 있습니까? – pes502
웹 서버에서'ini_set ('allow_url_fopen', 'ON');을 설정할 권리가 없을 수도 있습니다. –
ini_set ('allow_url_fopen', 'ON') 없이도 작동하지 않습니다. BTW, 나는 호스트에 Fatcow를 사용하고 있습니다. – user10132