<?
///
/// phpschool tip & tech 게시판에서 글 목록 뽑아오기
/// 추가^^ 답글수와 조회수도 가져오기
///
$url = "http://phpschool.com/v2/html/tip_tech.html"; // 게시판 주소
$data = join("", file($url)); // 페이지를 읽어 옴
$data = strtolower($data); // 대문자를 소문자로 변환
$temp = split("href",$data); // 주어진 문자로 문자열 구분하여 배열에 저장
$size = sizeof($temp); // 배열 크기
$mark = chr(34); // 큰따옴표
for($i=1; $i < $size; $i++){ // 각 배열 검색
$seek = strstr($temp[$i],"/inc_view.html?id"); // (/inc_view.html?id) 로 시작하는 문자열 검색
$seek_reply = strstr($seek,">["); // 답글수 가져오기 시작
$seek_reply = substr("$seek_reply",0,strpos($seek_reply,"]</font>"));
if ( strlen("$seek_reply") > 10 ) {
$seek_reply = substr("$seek_reply",5);
$seek_reply = strstr($seek_reply,"[");
}
$seek_reply = ereg_replace(">","",$seek_reply);
$seek_read = strchr($seek,"<p>"); // 조회수 가져오기 시작
$seek_read = substr("$seek_read",0,strpos($seek_read,"</td>"));
$seek_read = ereg_replace("<p>","",$seek_read);
$seek_read = ereg_replace("</td>","",$seek_read);
$seek = substr("$seek",0,strpos($seek,"<")); // (<)이 있는곳 전까지 뽑아낸다
$seek = ereg_replace("$mark >"," ",$seek); // 필요 없는 (" >) 를 없애고
$seek_link = substr("$seek",0,strpos($seek," ")); // 링크 추출
$seek_sub = strstr($seek," "); // 제목 추출
if ( strlen("$seek_link") != 0 ) {
echo "<pre><a href='http://phpschool.com/bbs2$seek_link'>$seek_sub</a> 답글수 $seek_reply] / 조회수 $seek_read</pre>"; // 화면에 표시
}
}
?>
///
/// phpschool tip & tech 게시판에서 글 목록 뽑아오기
/// 추가^^ 답글수와 조회수도 가져오기
///
$url = "http://phpschool.com/v2/html/tip_tech.html"; // 게시판 주소
$data = join("", file($url)); // 페이지를 읽어 옴
$data = strtolower($data); // 대문자를 소문자로 변환
$temp = split("href",$data); // 주어진 문자로 문자열 구분하여 배열에 저장
$size = sizeof($temp); // 배열 크기
$mark = chr(34); // 큰따옴표
for($i=1; $i < $size; $i++){ // 각 배열 검색
$seek = strstr($temp[$i],"/inc_view.html?id"); // (/inc_view.html?id) 로 시작하는 문자열 검색
$seek_reply = strstr($seek,">["); // 답글수 가져오기 시작
$seek_reply = substr("$seek_reply",0,strpos($seek_reply,"]</font>"));
if ( strlen("$seek_reply") > 10 ) {
$seek_reply = substr("$seek_reply",5);
$seek_reply = strstr($seek_reply,"[");
}
$seek_reply = ereg_replace(">","",$seek_reply);
$seek_read = strchr($seek,"<p>"); // 조회수 가져오기 시작
$seek_read = substr("$seek_read",0,strpos($seek_read,"</td>"));
$seek_read = ereg_replace("<p>","",$seek_read);
$seek_read = ereg_replace("</td>","",$seek_read);
$seek = substr("$seek",0,strpos($seek,"<")); // (<)이 있는곳 전까지 뽑아낸다
$seek = ereg_replace("$mark >"," ",$seek); // 필요 없는 (" >) 를 없애고
$seek_link = substr("$seek",0,strpos($seek," ")); // 링크 추출
$seek_sub = strstr($seek," "); // 제목 추출
if ( strlen("$seek_link") != 0 ) {
echo "<pre><a href='http://phpschool.com/bbs2$seek_link'>$seek_sub</a> 답글수 $seek_reply] / 조회수 $seek_read</pre>"; // 화면에 표시
}
}
?>
[이 게시물은 관리자님에 의해 2011-10-31 17:16:08 PHP & HTML에서 이동 됨]
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 2530 |
|
15년 전 | 2624 | |
| 2529 |
|
15년 전 | 1336 | |
| 2528 | 15년 전 | 1050 | ||
| 2527 | 15년 전 | 1514 | ||
| 2526 | 15년 전 | 912 | ||
| 2525 | 15년 전 | 1207 | ||
| 2524 | 15년 전 | 1101 | ||
| 2523 | 15년 전 | 1501 | ||
| 2522 |
NY더지더지
|
15년 전 | 1636 | |
| 2521 | 15년 전 | 909 | ||
| 2520 |
|
15년 전 | 1315 | |
| 2519 |
|
15년 전 | 1107 | |
| 2518 | 15년 전 | 939 | ||
| 2517 |
|
15년 전 | 1014 | |
| 2516 | 15년 전 | 1328 | ||
| 2515 | 15년 전 | 773 | ||
| 2514 | 15년 전 | 953 | ||
| 2513 | 15년 전 | 2609 | ||
| 2512 |
|
15년 전 | 1422 | |
| 2511 |
|
15년 전 | 794 | |
| 2510 |
|
15년 전 | 826 | |
| 2509 | 15년 전 | 1270 | ||
| 2508 | 15년 전 | 1306 | ||
| 2507 | 15년 전 | 1555 | ||
| 2506 | 15년 전 | 1039 | ||
| 2505 | 15년 전 | 1402 | ||
| 2504 |
JMoon
|
15년 전 | 697 | |
| 2503 |
|
15년 전 | 1049 | |
| 2502 | 15년 전 | 1311 | ||
| 2501 | 15년 전 | 2725 | ||
| 2500 | 15년 전 | 1088 | ||
| 2499 | 15년 전 | 1059 | ||
| 2498 | 15년 전 | 964 | ||
| 2497 |
첫만남의감격
|
15년 전 | 835 | |
| 2496 |
|
15년 전 | 842 | |
| 2495 |
|
15년 전 | 3440 | |
| 2494 |
soulfuleyes
|
15년 전 | 2812 | |
| 2493 | 15년 전 | 1992 | ||
| 2492 | 15년 전 | 2440 | ||
| 2491 | 15년 전 | 1530 | ||
| 2490 | 15년 전 | 1079 | ||
| 2489 | 15년 전 | 1069 | ||
| 2488 | 15년 전 | 2343 | ||
| 2487 | 15년 전 | 891 | ||
| 2486 | 15년 전 | 1935 | ||
| 2485 |
못말리는크리스
|
15년 전 | 741 | |
| 2484 |
|
15년 전 | 1885 | |
| 2483 | 15년 전 | 821 | ||
| 2482 | 15년 전 | 2492 | ||
| 2481 | 15년 전 | 742 | ||
| 2480 | 15년 전 | 1168 | ||
| 2479 | 15년 전 | 721 | ||
| 2478 |
|
15년 전 | 2886 | |
| 2477 | 15년 전 | 1265 | ||
| 2476 | 15년 전 | 1294 | ||
| 2475 | 15년 전 | 1305 | ||
| 2474 | 15년 전 | 1368 | ||
| 2473 | 15년 전 | 980 | ||
| 2472 | 15년 전 | 1740 | ||
| 2471 | 15년 전 | 1268 | ||
| 2470 | 15년 전 | 852 | ||
| 2469 | 15년 전 | 2708 | ||
| 2468 | 15년 전 | 1096 | ||
| 2467 | 15년 전 | 1296 | ||
| 2466 | 15년 전 | 1098 | ||
| 2465 | 15년 전 | 1955 | ||
| 2464 | 15년 전 | 1971 | ||
| 2463 | 15년 전 | 1637 | ||
| 2462 | 15년 전 | 990 | ||
| 2461 | 15년 전 | 1223 | ||
| 2460 | 15년 전 | 918 | ||
| 2459 | 15년 전 | 859 | ||
| 2458 | 15년 전 | 1102 | ||
| 2457 | 15년 전 | 2463 | ||
| 2456 | 15년 전 | 2482 | ||
| 2455 | 15년 전 | 1460 | ||
| 2454 | 15년 전 | 1000 | ||
| 2453 | 15년 전 | 1156 | ||
| 2452 | 15년 전 | 1161 | ||
| 2451 | 15년 전 | 1028 | ||
| 2450 | 15년 전 | 931 | ||
| 2449 | 15년 전 | 858 | ||
| 2448 | 15년 전 | 1215 | ||
| 2447 | 15년 전 | 1170 | ||
| 2446 | 15년 전 | 914 | ||
| 2445 | 15년 전 | 888 | ||
| 2444 | 15년 전 | 1063 | ||
| 2443 | 15년 전 | 1535 | ||
| 2442 | 15년 전 | 1067 | ||
| 2441 | 15년 전 | 1390 | ||
| 2440 |
|
15년 전 | 1232 | |
| 2439 | 15년 전 | 1900 | ||
| 2438 |
|
15년 전 | 2962 | |
| 2437 |
|
15년 전 | 2291 | |
| 2436 |
|
15년 전 | 888 | |
| 2435 |
|
15년 전 | 1900 | |
| 2434 |
|
15년 전 | 2085 | |
| 2433 |
|
15년 전 | 1391 | |
| 2432 | 15년 전 | 1368 | ||
| 2431 | 15년 전 | 2632 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기