KinetiX Posted October 31, 2006 Share Posted October 31, 2006 Hy,i just wanted to ask if there is posible to make a function that will print a certain row from a webpage(EX: http://www.mypage.com/view.php)...Let`s say that on the page..there are 5 lines....can you make me a function that will print let`s say the fourth line pls....thanks Link to comment https://forums.phpfreaks.com/topic/25686-a-litle-help-with-files/ Share on other sites More sharing options...
Cep Posted October 31, 2006 Share Posted October 31, 2006 I beleive this is possible but only with text based files. Eg. you can read in a text based file and determine what the text was on a certain line and then assign that to a string variable and then print that variable on screen.I would suggest checking the file handling functions in the php manual,http://www.phpfreaks.com/phpref/41.php Link to comment https://forums.phpfreaks.com/topic/25686-a-litle-help-with-files/#findComment-117227 Share on other sites More sharing options...
Psycho Posted October 31, 2006 Share Posted October 31, 2006 What you are wanting to do is called screen scraping (i.e. pulling data off of a webpage. There's plenty of information out there. however, the difficult part will be in creating the rules to determine "where" the 4th line is - programatically speaking. If the structure of the page is changed you will need to rewrite your screen-scraping code to adjust. Link to comment https://forums.phpfreaks.com/topic/25686-a-litle-help-with-files/#findComment-117297 Share on other sites More sharing options...
KinetiX Posted October 31, 2006 Author Share Posted October 31, 2006 the page won`t change....it will remain the same..i will lok for more info`s now..Thanks a lot Link to comment https://forums.phpfreaks.com/topic/25686-a-litle-help-with-files/#findComment-117316 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.