Hi
I am trying to open site having frame and store its source code in a file.
Problem is the file stores:
"This page uses frames, but your browser doesn't support them."
I used the code:
$fd = @fopen( $q, "r" );
$handle = @fopen("default.txt", "w");
if (!$fd)
echo "Cannot open URL";
else
{
while(!feof($fd))
{
$buffer = fgets($fd,4096);
$buffer= preg_replace('/s\s+/', ' ',$buffer);
fwrite($handle,$buffer);
fflush($handle);
}
}
fclose($handle);
fclose( $fd );
But the site having <frame> and <frameset> doesn't store the source code in the file. it stores this msg.
<html>
<head>
<title>Welcome To Ranchi.com</title>
<meta name="keywords" content="Ranchi, Bihar, India, Calcutta, Plateau, Adivasi, Mica, HEC, Mecon, TATA, Jharkhand, City">
<meta name="description" content="Ranchi.com is the portal of entry into Bihar and Eastern India. The future capital of Jharkhand (Vananchal). An industrial city, with numerous companies, HEC, MECON, CCL, Usha Martin. Leading universities like BIT messra, St Xaviers, XLRI, RMCH etc. Get maps, tourist info, weather, and a whole lot more.">
</head>
<frameset border="0" frameborder="0" framespacing="0" cols="1,*">
<frame src="http://www.ranchi.com/nada.htm">
<frame name="main" scrolling="auto" src="http://www.ranchi.com/display/home/default.asp">
<noframes>
<body>
😕 <p>This page uses frames, but your browser doesn't support them.</p> 😕 </body>
</noframes>
</frameset>
</html>