묻고답하기
게시판과 슬라이드와의 연결고리
2017.06.01 13:21
<link href="./phpApplications/contentTouchSlider/css/font-awesome.min.css" rel="stylesheet" />
<link href="./phpApplications/contentTouchSlider/css/swiper.min.css" rel="stylesheet" />
<link href="./phpApplications/contentTouchSlider/css/style.css" rel="stylesheet" />
<?php
/* connection */
require './files/config/db.config.php';
$hostName = $db_info->master_db[db_hostname];
$userId = $db_info->master_db[db_userid];
$userPw = $db_info->master_db[db_password];
$dataBase = $db_info->master_db[db_database];
mysql_connect($hostName, $userId, $userPw) or die('something wrong');
mysql_select_db($dataBase);
mysql_query('SET NAMES utf8');
/* ����� ���� */
$module_srl = 12473;
?>
<div class="contentImageSlider swiper-container">
<div class="contentSlideWrapper swiper-wrapper">
<?php
$query = "SELECT F.* FROM `xe_files` F INNER JOIN xe_document_extra_vars E ON (E.document_srl = F.upload_target_srl) WHERE F.module_srl = $module_srl AND E.value = 'ON'
ORDER BY F.upload_target_srl DESC";
$result = mysql_query($query);
$imageNumber = 0;
while($row = mysql_fetch_array($result)){
$document_srl = $row['upload_target_srl'];
$link = mysql_query("SELECT value FROM xe_document_extra_vars WHERE document_srl = $document_srl AND eid = 'link'");
$link_result = mysql_fetch_row($link);
$imageUrl = $row['uploaded_filename'];
if($link_result)
echo '<div class="image'.$imageNumber.' contentSlide swiper-slide"><a href="'.$link_result[0].'" target="_blank"><img src="'.$imageUrl.'" style="width:100%; "/></a></div>';
else
echo '<div class="image'.$imageNumber.' contentSlide swiper-slide"><img src="'.$imageUrl.'" style="width:100%;"/></div>';
$imageNumber++;
}
?>
<!--
<div class="image1 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/20170517m.png" style="width:100%;"/></div>
<div class="image1 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/20170510m.jpg" style="width:100%;"/></div>
<div class="image1 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/20170510_2m.jpg" style="width:100%;"/></div>
<div class="image1 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/fm_170207_2.jpg" style="width:100%;"/></div>
<div class="image1 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/fm_161229_1.jpg" style="width:100%;"/></div>
<div class="image9 contentSlide swiper-slide"><img src="/m.layouts/firstglory_m/images/mm2.png" style="width:100%;"/></div
-->
</div>
<span class="swiper-button-prev leftIndicator indicator">
</span>
<span class="swiper-button-next rightIndicator indicator">
</span>
<div class="swiper-pagination" style="display:none; position: relative; bottom: 0px; background: #fff; height: 50px; padding-top: 20px;"></div>
</div>
<script src="./phpApplications/contentTouchSlider/js/swiper.js"></script>
<script src="./phpApplications/contentTouchSlider/js/script.js"></script>
<script>
function getInternetExplorerVersion() {
var rv = -1; // Return value assumes failure.
if (navigator.appName == 'Microsoft Internet Explorer') {
var ua = navigator.userAgent;
var re = new RegExp("MSIE ([0-9]{1,}[\.0-9]{0,})");
if (re.exec(ua) != null)
rv = parseFloat(RegExp.$1);
}
return rv;
}
if(getInternetExplorerVersion() >= 6 && getInternetExplorerVersion() <= 9){
var swiper = new Swiper('.swiper-container', {
pagination: '.swiper-pagination',
nextButton: '.swiper-button-next',
prevButton: '.swiper-button-prev',
paginationClickable: true,
loop: true,
spaceBetween: 30,
centeredSlides: true,
autoplay: 4200,
autoplayDisableOnInteraction: false
});
jQuery('.swiper-pagination').hide();
}
else{
var swiper = new Swiper('.swiper-container', {
pagination: '.swiper-pagination',
nextButton: '.swiper-button-next',
prevButton: '.swiper-button-prev',
paginationClickable: true,
loop: false,
spaceBetween: 30,
centeredSlides: true,
autoplay: 4200,
autoplayDisableOnInteraction: false
});
}
</script>
- [2020/12/16] 묻고답하기 footer 하단에 고정하려면 어딜 수정해야 할까요?
- [2020/01/31] 묻고답하기 2단메뉴 *2
- [2019/10/10] 묻고답하기 cafe24 XE3 STEP 3 단계에서 에러가 발생합니다. *3
- [2019/03/27] 묻고답하기 모바일에서만 '권한이 없습니다'가 나오는 이유가 궁금합니다. *1
- [2019/03/15] 포럼 웹 에이전시 디스케이션에서 레이아웃 템플릿 판매 개시했습니다. *2
댓글 0
글쓴이 | 제목 | 최종 글 |
---|---|---|
XE | 공지 글 쓰기,삭제 운영방식 변경 공지 [16] | 2019.03.05 by 남기남 |
iufc84 | 포인트 레벨 아이콘 표시 애드온... 문제 | |
하트 | testyle 관리화면 접속이 안됩니다. [2] | 2017.06.04 by 하트 |
사람인 | 쉬운설치가 안돼요 [1] | 2017.06.04 by 너에게제공 |
pb**** | 디비정보 변경시 xe 디비정보 변경 파일을 어디에 있나요 [3] | 2017.06.04 by pb**** |
Antikiwi | Ci 값 입력창 뜨게 하는 방법? | |
Synchel | 모바일에 유튜브 동영상 넣고 싶은데요 | |
iufc84 | pc 접속은 정상, 모바일 접속 시 흰 화면만 뜹니다.. [2] | 2017.06.03 by iufc84 |
Synchel | 사이트 이전후 게시글 가져오기 | |
쌩쥐 | 상단메뉴답변좀부탁드립니다.. (사진있음,사이트있음) [3] | 2017.06.03 by 비누남어 |
레오나 | 위젯페이지에 위젯을 추가하고 코드 생성은 되지만 위젯이 나타나지 않습니다. [2] | 2017.06.03 by sejin7940 |
thdwjdtjr | XE Core 1.8.40 업데이트 후 문서 첨부가 않되는 현상.... [2] | 2017.06.03 by thdwjdtjr |
박하향풍선껌 | 확장변수중 일부 관리자만 보이게 설정. 아무리 찾아봐도 모르겠어요 [2] | 2017.06.02 by 박하향풍선껌 |
chorok | 로그인 페이지 오류 [4] | 2017.06.02 by chorok |
전갈자리남 | XE 설치시 오류 | |
h2y_07 | SQLGate for MySQL에서 백업하는방법 질문드립니다. [1] | 2017.06.02 by h2y_07 |
stanlin | 위젯에서 확장변수 기준 정렬 방법 [6] | 2017.06.02 by stanlin |
kylehyj | 이게 왜이럴까요... [1] | 2017.06.02 by sejin7940 |
WindBoy | 도메인 수정방법 문의드립니다 [1] | 2017.06.01 by 마야 |
Thunder28 | 게시글 자동 정리나 첨부화일 정리 문의 | |
쩡님아야 | 게시판과 슬라이드와의 연결고리 |