cataiin Posted August 30, 2013 Share Posted August 30, 2013 Hei. Sorry for bad english. Need a little help. I have this code: $mama = $_SERVER['REQUEST_URI']; $tata = rawurldecode($mama); $asta= 'titlu='; preg_match("|$asta(.*)|",$tata,$bunica); $tataie = $bunica['1']; echo $tataie; Result is: http://www.example.com/a/123/b-and-c Now I want to get some text from that page. There is something like: "class":"cjbzeo"," and I need only cjbzeo. Thanks! Link to comment https://forums.phpfreaks.com/topic/281689-get-some-text-from-url/ Share on other sites More sharing options...
cyberRobot Posted August 30, 2013 Share Posted August 30, 2013 Sorry, I'm not sure I follow. Where does "cjbzeo" come from? Is it pulled from the string that you got from $_SERVER['REQUEST_URI']? Or do you have PHP pulling the actual content from a website and it's somewhere in that source code? Link to comment https://forums.phpfreaks.com/topic/281689-get-some-text-from-url/#findComment-1447448 Share on other sites More sharing options...
Maq Posted August 30, 2013 Share Posted August 30, 2013 Are you receiving JSON? Link to comment https://forums.phpfreaks.com/topic/281689-get-some-text-from-url/#findComment-1447454 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.