Permalink
Browse files

5��/�����: ��������̼�, �ڵ�������и��� �̿��� ��μ��, id�Ķ�����ν�/�������…

…�͸���................................................��Ÿ: ������̹������������, movie�ʵ��߰�, ����ּҺ���ȭ(�Ϻ�)
  • Loading branch information...
unknown
unknown committed Jan 5, 2013
1 parent aac94c3 commit 4fba903ff5c3ab9c71d6f9d1033c4f6dd856c162
Showing with 240 additions and 286 deletions.
  1. BIN image/logo_mob.png
  2. +22 −100 index.php
  3. +37 −34 index_m.php → s_mob/index.php
  4. +61 −20 {style → s_mob}/style_m.css
  5. BIN { → s_web}/font/NanumGothic.eot
  6. BIN { → s_web}/font/NanumGothic.ttf
  7. BIN { → s_web}/font/NanumGothic.woff
  8. BIN { → s_web}/font/NanumGothicBold.eot
  9. BIN { → s_web}/font/NanumGothicBold.ttf
  10. BIN { → s_web}/font/NanumGothicBold.woff
  11. BIN { → s_web}/font/NanumGothicExtraBold.eot
  12. BIN { → s_web}/font/NanumGothicExtraBold.ttf
  13. BIN { → s_web}/font/NanumGothicExtraBold.woff
  14. BIN { → s_web}/font/NanumGothicLight.eot
  15. BIN { → s_web}/font/NanumGothicLight.ttf
  16. BIN { → s_web}/font/NanumGothicLight.woff
  17. BIN { → s_web}/font/NanumPen.eot
  18. BIN { → s_web}/font/NanumPen.ttf
  19. BIN { → s_web}/font/NanumPen.woff
  20. +4 −4 { → s_web}/head.php
  21. 0 { → s_web}/hold_snsshare.php
  22. BIN { → s_web}/image/apple-touch-icon.png
  23. BIN { → s_web}/image/apple-touch-icon@2x.png
  24. BIN { → s_web}/image/dogear.png
  25. BIN { → s_web}/image/dogear_01.png
  26. BIN { → s_web}/image/dogear_02.png
  27. BIN { → s_web}/image/favicon.ico
  28. BIN { → s_web}/image/lnb_diary_fb.png
  29. BIN { → s_web}/image/lnb_diary_fb.psd
  30. BIN { → s_web}/image/lnb_diary_gh.png
  31. BIN { → s_web}/image/lnb_sns_blog.png
  32. BIN { → s_web}/image/lnb_sns_fb.png
  33. BIN { → s_web}/image/lnb_sns_tw.png
  34. BIN { → s_web}/image/logo.png
  35. BIN s_web/image/logo_mob.png
  36. BIN { → s_web}/image/logo_mob_row.png
  37. BIN { → s_web}/image/navshadow.png
  38. BIN { → s_web}/image/navshadow_320.png
  39. BIN { → s_web}/image/navshadow_tile.png
  40. BIN { → s_web}/image/navshadow_tile_invert.png
  41. BIN { → s_web}/image/navshadow_tile_strong.png
  42. BIN { → s_web}/image/post_inner_btn_01.png
  43. BIN { → s_web}/image/post_inner_btn_02.png
  44. BIN { → s_web}/image/sel_mark_01.png
  45. BIN { → s_web}/image/sel_mark_01_tmp.png
  46. BIN { → s_web}/image/sel_mark_02.png
  47. BIN { → s_web}/image/sel_mark_02_tmp.png
  48. BIN { → s_web}/image/test_image_01.png
  49. BIN { → s_web}/image/test_image_02.png
  50. BIN { → s_web}/image/under_construction.png
  51. +62 −0 s_web/pagenation.php
  52. +3 −3 { → s_web}/post.php
  53. +29 −16 { → s_web}/post_core.php
  54. 0 { → s_web}/post_disqus.php
  55. 0 { → s_web}/post_inner.php
  56. +1 −1 { → s_web}/post_m.php
  57. 0 { → s_web}/select.php
  58. +8 −1 { → s_web}/style/style.css
  59. 0 { → s_web}/style/style_space.css
  60. +13 −0 s_web/variable_para.php
  61. +0 −56 style/style_keep.css
  62. +0 −25 test/test_01_input.php
  63. +0 −15 test/test_02_print.php
  64. +0 −11 z_keepold.php
View
BIN -41.7 KB image/logo_mob.png
Binary file not shown.
View
122 index.php
@@ -3,10 +3,10 @@
<head>
<?php
include_once ('./sugaruinet/head.php')
include_once ('./s_web/head.php')
?>
<link rel="stylesheet" type="text/css" href="./sugaruinet/style/style_space.css" />
<link rel="stylesheet" type="text/css" href="./sugaruinet/style/style.css" />
<link rel="stylesheet" type="text/css" href="./s_web/style/style_space.css" />
<link rel="stylesheet" type="text/css" href="./s_web/style/style.css" />
<link href='http://fonts.googleapis.com/css?family=Merriweather' rel='stylesheet' type='text/css'> <!--숫자웹폰트-->
</head>
@@ -22,36 +22,19 @@
<div class="nav_1">
<header>
<h1>
<div class="header_web">
<a href="./index.php"> <img src="./sugaruinet/image/logo.png" alt="사탕화면 회사로고"> </a>
</div>
<div class="header_mob">
<img src="./sugaruinet/image/logo_mob.png" alt="사탕화면 회사로고"> </a>
</div>
<a href="./index.php"> <img src="./s_web/image/logo.png" alt="사탕화면 회사로고"> </a>
</h1>
</header>
<nav>
<?php
//파라미터 기준 설정(카테냐,태그냐,아이디냐)
if($_GET['cate']){
$paraname = 'cate';
$paravalue = $_GET['cate'];
}else if($_GET['tag']){
$paraname = 'tag';
$paravalue = $_GET['tag'];
}else if($_GET['id']){
$paraname = 'id';
$paravalue = $_GET['id'];
}
//파라미터 관련 변수 인클루드
include './s_web/variable_para.php';
//Table(카테) 로부터 리소스획득
$sql = 'SELECT * FROM `su_cate_01` ORDER BY id_intent';
$result = mysql_query($sql);
//Table(카테) 로부터 리소스획득
$sql = 'SELECT * FROM `su_cate_01` ORDER BY id_intent';
$result = mysql_query($sql);
?>
<ul>
@@ -70,7 +53,7 @@
if( ($_GET['cate'] === $row['cate']) || ( !$paravalue && !$row['cate'] && !$_GET['special']) ){
// cate파라가있고 이것이 $row의cate열과같을때 OR 파라가전혀없고 $row의cate열이비었을때(all일때) 이면서 $row_special 스페셜값이 없을때
// 셀렉트 관련 변수를 지정한다
$select_open = "<div class=\"sel\"><img src=\"./sugaruinet/image/sel_mark_01.png\">&nbsp;";
$select_open = "<div class=\"sel\"><img src=\"./s_web/image/sel_mark_01.png\">&nbsp;";
$select_close = "</div>";
}else{
$select_open = " ";
@@ -105,7 +88,7 @@
<div class="nav_main">
<?php
if($_GET['special']==='about'){
echo "<img src=\"./sugaruinet/image/sel_mark_02.png\">&nbsp;ABOUT";
echo "<img src=\"./s_web/image/sel_mark_02.png\">&nbsp;ABOUT";
}else{
echo "ABOUT";
}
@@ -118,7 +101,7 @@
<div class="nav_main">
<?php
if($_GET['special']==='guest'){
echo "<img src=\"./sugaruinet/image/sel_mark_02.png\">&nbsp;GUEST";
echo "<img src=\"./s_web/image/sel_mark_02.png\">&nbsp;GUEST";
}else{
echo "GUEST";
}
@@ -134,12 +117,12 @@
</div>
<div class="icon">
<a href="https://www.facebook.com/sugaruipage" target="_blank">
<img src="./sugaruinet/image/lnb_diary_fb.png" alt="facebook">
<img src="./s_web/image/lnb_diary_fb.png" alt="facebook">
</a>
</div>
<div class="icon">
<a href="https://github.com/sugarui/sugaruinet" target="_blank">
<img src="./sugaruinet/image/lnb_diary_gh.png" alt="github">
<img src="./s_web/image/lnb_diary_gh.png" alt="github">
</a>
</div>
</li>
@@ -151,17 +134,17 @@
<ul>
<div class="icon">
<a href="https://www.facebook.com/sugaruipage#!/sugar.ui.9" target="_blank">
<img src="./sugaruinet/image/lnb_sns_fb.png" alt="facebook">
<img src="./s_web/image/lnb_sns_fb.png" alt="facebook">
</a>
</div>
<div class="icon">
<a href="https://twitter.com/sugarui" target="_blank">
<img src="./sugaruinet/image/lnb_sns_tw.png" alt="twitter">
<img src="./s_web/image/lnb_sns_tw.png" alt="twitter">
</a>
</div>
<div class="icon">
<a href="http://blog.naver.com/sugarui" target="_blank">
<img src="./sugaruinet/image/lnb_sns_blog.png" alt="blog">
<img src="./s_web/image/lnb_sns_blog.png" alt="blog">
</a>
</div>
</ul>
@@ -204,7 +187,7 @@
if(($_GET['tag']) && ($_GET['tag'] === $tags[$i])){
// tag파라가있고 이것이 $row의tag열과같을때
// 셀렉트 관련 변수를 지정한다
$select_open = "<div class=\"sel\"><img src=\"./sugaruinet/image/sel_mark_01.png\">&nbsp;";
$select_open = "<div class=\"sel\"><img src=\"./s_web/image/sel_mark_01.png\">&nbsp;";
$select_close = "</div>";
}else{
$select_open = " ";
@@ -243,10 +226,10 @@
<?php
// DB로부터 컨텐츠 셀렉트
include './sugaruinet/select.php';
include './s_web/select.php';
//출력
while ($row = mysql_fetch_array($result) ){
include './sugaruinet/post.php';
include './s_web/post.php';
}
?>
@@ -263,74 +246,13 @@ function copy(trb) {
</script>
<!---------------- 페이지네이션 ------------------>
<div class="pagenation">
<?php
<?php
//스페셜 페이지일때, 혹은 파라미터가 id일때는 1개뿐이므로 페이지네이션이 필요가 없다
if ( ($paraname != 'id') && (!$_GET['special']) ){
//리소스 획득 : Table(포스트) 에서 본 카테고리 데이터"량"을 알아내기 위해 id 열, 전체 행
if($paravalue){
$sql = "SELECT id FROM `su_post_01` WHERE $paraname = '$paravalue'";
}else{
$sql = "SELECT id FROM `su_post_01`";
}
$result = mysql_query($sql);
$num_rows = mysql_num_rows($result); // 게시물 총수획득. 예를들어 32
// $num_posts_display = oo ;페이지당 출력수선언. 올렸음. 예를들어 3
$num_pages = ceil($num_rows/$num_posts_display); //페이지수는 게시물 총수32/페이지당 출력수3 =10, 올림해서 11
// < ㅇㅇㅇㅇㅇ >포맷 구성
$range = 5;
$page_now = $_GET['page'];
$x = ceil($page_now / $range) - 1; // 6일땐 2-1 = 1 , 10일때도 2-1 = 1 // 1일땐 1-1 = 0 5일땐 1-1 = 0
$i_pre = $range * $x; //앞선 페이지는 5 // 1일땐 0
$i = $i_pre + 1; // 시작은 1이나 6
$limit_vague = ceil($page_now / $range) * $range; // 리미트. 6이나 10일땐 2x5, 1이나 5일땐 1x5
$limit = min ($num_pages, $limit_vague); // 리미트 상세. 실제 페이지 넘버까지만.
//출력
if ( 1 < $num_pages ){ //페이지수가 1을 넘어갈때만 출력
//꺾쇠 왼쪽
if ($i > $range){
echo "
<a href=\"?{$paraname}={$paravalue}&page={$i_pre}\">
<span class=\"pagenation_nav\">◀</span>
</a>
";
}
//페이지
while($i<= $limit ) { //레인지(표시범위)까지 에코
if($i == $_GET['page']){ //현페이지 셀렉트 체크는 파라미터로
echo "
<a href=\"?{$paraname}={$paravalue}&page={$i}\">
<span class=\"pagenation_each\"><span class=\"sel\">{$i}</span></span>
</a>
";
$i++;
}else{
echo "
<a href=\"?{$paraname}={$paravalue}&page={$i}\">
<span class=\"pagenation_each\">{$i}</span>
</a>
";
$i++;
}
}
//꺾쇠 오른쪽
if ($i <= $num_pages){ //$i 는 이미 ++은 됐을꺼야.
echo "
<a href=\"?{$paraname}={$paravalue}&page={$i}\">
<span class=\"pagenation_nav\">▶</span>
</a>
";
}
}
include './s_web/pagenation.php';
}
?>
</div>
<!--페이지네이션 end-->
@@ -3,21 +3,24 @@
<head>
<?php
include ('./sugaruinet/head.php')
include ('../s_web/head.php')
?>
<link rel="stylesheet" type="text/css" href="./sugaruinet/style/style_space.css" />
<link rel="stylesheet" type="text/css" href="./style/style_m.css" />
<link rel="stylesheet" type="text/css" href="http://elecuchi.cafe24.com/s_web/style/style_space.css" />
<link rel="stylesheet" type="text/css" href="./style_m.css" />
<link href='http://fonts.googleapis.com/css?family=Merriweather' rel='stylesheet' type='text/css'> <!--숫자웹폰트-->
</head>
<!--DB접속-->
<?php
include_once ('./db.php');
include_once ('../db.php');
?>
<body>
<header>
<img src="./sugaruinet/image/logo_mob.png" alt="사탕화면로고" style="width: 100%" />
<header>
<a href="./index.php">
<img src="http://elecuchi.cafe24.com/s_web/image/logo_mob.png" alt="사탕화면로고" style="width: 100%" />
</a>
<div class="header_space"></div><!--미스터치방지-->
</header>
<nav>
@@ -26,12 +29,15 @@
<?php
//현메뉴확인
if(!$_GET['special']){
echo "<a href=\"?cate={$row['cate']}\" style=\"color:#dc2276; \">";
//재클릭시 링크 유지를 위해서 파라미터를 상세히 적음
echo "<a href=\"?cate={$_GET['cate']}&page={$_GET['page']}&id={$_GET['id']}\" style=\"color:#dc2276; \">";
}else{
echo "<a href=\"?cate={$row['cate']}\" >";
echo "<a href=\"?cate={$_GET['cate']}&page={$_GET['page']}&id={$_GET['id']}\" >";
}
//출력
if(!$_GET['cate']){
if($_GET['id']){
echo 'Category';
}else if(!$_GET['cate']){
echo 'All works';
}else{ //방법을 몰라서 일단 직접 적음
if ($_GET['cate']==='guiat') { $display = 'GUI at work'; }
@@ -51,11 +57,14 @@
$result = mysql_query($sql);
while ($row = mysql_fetch_array($result)){
if($_GET['cate']){ //카테값이 없을 경우 all을 포함한 모든카테고리 출력
if($_GET['cate'] || $_GET['id']){ //카테가 있으면 혹은 id가 있으면
echo "<li><a href=\"?cate={$row['cate']}\">{$row['cate_expression']}</a></li>";
}else if($row['cate']){ //카테값이 있을 경우 카테필드값이 있을경우(all 외 전부) 만 출력
}else if($row['cate']){ //아님 로우에 카테가 있으면
echo "<li><a href=\"?cate={$row['cate']}\">{$row['cate_expression']}</a></li>";
}
// 카테가 없는 all일때 출력안됨,
// 카테가 없을때 else if로 오는데, 그마저 로우에 카테 있을때만 출력하므로
// all 의 row은 건너뜀
}
?>
</ul>
@@ -78,40 +87,34 @@
</ul>
</nav>
<div class="navshadow"></div>
<article>
<?php
// 파라미터 기준 설정(카테냐,태그냐,아이디냐)
//그래도 select.php 중 special이 없느 else 에서 이 변수를 써야하니까 지정.
$paraname = 'cate';
$paravalue = $_GET['cate'];
<?php
//파라미터 관련 변수 인클루드
include '../s_web/variable_para.php';
// DB로부터 컨텐츠 셀렉트
include './sugaruinet/select.php';
include '../s_web/select.php';
//출력
while ($row = mysql_fetch_array($result) ){
include './sugaruinet/post_m.php'; //와꾸는 post_m이지만 그속에 post_core는 웹과같다.
include '../s_web/post_m.php'; //와꾸는 post_m이지만 그속에 post_core는 웹과같다.
//echo "<div class=\"border_1\"></div> <div class=\"border_2\"></div> ";
}
?>
<!--더보기 : 작동하지않음
<div class="postbox_more">
<div id="more" onclick="moreHandler()">더보기</div>
</div>
<?php
echo "
<script type=\"text/javascript\">
var more = document.getElementById('more');
function moreHandler(){
";
include './a.php';
echo "
<!---------------- 페이지네이션 ------------------>
<div class="pagenation">
<?php
//스페셜 페이지일때, 혹은 파라미터가 id일때는 1개뿐이므로 페이지네이션이 필요가 없다
if ( ($paraname != 'id') && (!$_GET['special']) ){
include '../s_web/pagenation.php';
}
</script>
";
?>
더보기-->
?>
</div>
<!--페이지네이션 end-->
</article>
Oops, something went wrong.

0 comments on commit 4fba903

Please sign in to comment.