Toggle navigation
Toggle navigation
This project
Loading...
Sign in
이유제
/
CultureGallery
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
송효섭
2020-12-11 11:19:52 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
dc08b95a416d1ce0d3762102fad2fab0f4bb935b
dc08b95a
1 parent
6f05fed9
배포중 파일 send 도메인 수정
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
37 deletions
routes/findPage.ejs
routes/mapPage.ejs
routes/findPage.ejs
View file @
dc08b95
<!DOCTYPE html>
<html>
<head>
<head>
<title>
findpage
</title>
<link
rel=
"stylesheet"
href=
'/stylesheets/findPage_style.css'
type=
"text/css"
>
<script
src=
"https://developers.kakao.com/sdk/js/kakao.js"
></script>
<script>
Kakao
.
init
(
'0678e32dab56db1c52ac63ab4ccb7663'
)
function
sendLink
(
id
)
{
var
data
=
[];
function
sendLink
(
id
)
{
var
data
=
[];
var
strData
=
"<%= data %>"
;
var
splitData
=
strData
.
split
(
','
);
for
(
var
i
=
0
;
i
<
splitData
.
length
;
i
+=
5
)
{
data
.
push
([
Number
(
splitData
[
i
]),
splitData
[
i
+
1
],
Number
(
splitData
[
i
+
2
]),
Number
(
splitData
[
i
+
3
]),
splitData
[
i
+
4
],
splitData
[
i
+
5
]]);
var
splitData
=
strData
.
split
(
','
);
for
(
var
i
=
0
;
i
<
splitData
.
length
;
i
+=
5
)
{
data
.
push
([
Number
(
splitData
[
i
]),
splitData
[
i
+
1
],
Number
(
splitData
[
i
+
2
]),
Number
(
splitData
[
i
+
3
]),
splitData
[
i
+
4
],
splitData
[
i
+
5
]]);
}
var
index
;
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
console
.
log
(
data
.
length
);
if
(
data
[
i
][
0
]
===
id
)
{
index
=
i
;
if
(
data
[
i
][
0
]
===
id
)
{
index
=
i
;
Kakao
.
Link
.
sendDefault
({
objectType
:
'location'
,
address
:
`
${
data
[
i
][
5
]}
`
,
addressTitle
:
`
${
data
[
i
][
1
]}
`
,
content
:
{
content
:
{
title
:
`공연 이름:
${
data
[
i
][
1
]}
\n공연 위치:
${
data
[
i
][
5
]}
`
,
description
:
`
${
splitData
[
i
+
2
]}
`
,
imageUrl
:
'https://ifh.cc/g/aEvr86.png'
,
link
:
{
mobileWebUrl
:
'http://naver.com
'
,
webUrl
:
'http://naver.com
'
,
description
:
`
${
splitData
[
i
+
2
]}
`
,
imageUrl
:
'https://ifh.cc/g/aEvr86.png'
,
link
:
{
mobileWebUrl
:
'https://culturegallery.herokuapp.com/
'
,
webUrl
:
'https://culturegallery.herokuapp.com/
'
,
},
},
buttons
:
[
{
title
:
'Culture Gallery'
,
link
:
{
mobileWebUrl
:
'http://naver.com
'
,
webUrl
:
'http://naver.com'
,
mobileWebUrl
:
'https://culturegallery.herokuapp.com/
'
,
webUrl
:
'https://culturegallery.herokuapp.com/'
,
},
},
],
...
...
@@ -47,16 +48,17 @@
}
</script>
</head>
<body>
</head>
<body>
<h1
class=
'name'
>
공연 이름을 검색해보세요!
</h1>
<div
class =
"question"
>
<div
class=
"question"
>
<input
type=
"text"
value=
''
id=
"inputText"
placeholder=
"어떤 공연을 찾으시나요?"
>
<button
onclick=
'find()'
>
검색
</button>
</div>
</div>
<table
class=
"table"
>
<table
class=
"table"
>
<tr>
<th>
id
</th>
<th>
행사 이름
</th>
...
...
@@ -69,21 +71,21 @@
</tbody>
</table>
</div>
</div>
<script>
function
find
()
{
function
find
()
{
var
row
=
``
;
var
input
=
document
.
getElementById
(
'inputText'
).
value
;
var
dataContainer
=
document
.
getElementById
(
'map-data'
);
var
data
=
[];
var
input
=
document
.
getElementById
(
'inputText'
).
value
;
var
dataContainer
=
document
.
getElementById
(
'map-data'
);
var
data
=
[];
var
strData
=
"<%= data %>"
;
var
splitData
=
strData
.
split
(
','
);
for
(
var
i
=
0
;
i
<
splitData
.
length
;
i
+=
5
)
{
data
.
push
([
Number
(
splitData
[
i
]),
splitData
[
i
+
1
],
Number
(
splitData
[
i
+
2
]),
Number
(
splitData
[
i
+
3
]),
splitData
[
i
+
4
],
splitData
[
i
+
5
]]);
var
splitData
=
strData
.
split
(
','
);
for
(
var
i
=
0
;
i
<
splitData
.
length
;
i
+=
5
)
{
data
.
push
([
Number
(
splitData
[
i
]),
splitData
[
i
+
1
],
Number
(
splitData
[
i
+
2
]),
Number
(
splitData
[
i
+
3
]),
splitData
[
i
+
4
],
splitData
[
i
+
5
]]);
}
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
if
(
data
[
i
][
1
].
indexOf
(
input
)
!=-
1
)
{
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
if
(
data
[
i
][
1
].
indexOf
(
input
)
!=
-
1
)
{
row
=
`<tr>
<td>
${
data
[
i
][
0
]}
</td>
<td>
${
data
[
i
][
1
]}
</td>
...
...
@@ -93,10 +95,11 @@
<td> <input type="button" onclick="sendLink(
${
data
[
i
][
0
]}
)" value="전송하기"> </td>
</tr>`
dataContainer
.
innerHTML
+=
row
;
dataContainer
.
innerHTML
+=
row
;
}
}
}
</script>
</body>
</body>
</html>
\ No newline at end of file
...
...
routes/mapPage.ejs
View file @
dc08b95
...
...
@@ -32,16 +32,16 @@
description
:
`
${
splitData
[
i
+
2
]}
`
,
imageUrl
:
'https://ifh.cc/g/aEvr86.png'
,
link
:
{
mobileWebUrl
:
'http
://naver.com
'
,
webUrl
:
'http
://naver.com
'
,
mobileWebUrl
:
'http
s://culturegallery.herokuapp.com/
'
,
webUrl
:
'http
s://culturegallery.herokuapp.com/
'
,
},
},
buttons
:
[
{
title
:
'Culture Gallery'
,
link
:
{
mobileWebUrl
:
'http
://naver.com
'
,
webUrl
:
'http
://naver.com
'
,
mobileWebUrl
:
'http
s://culturegallery.herokuapp.com/
'
,
webUrl
:
'http
s://culturegallery.herokuapp.com/
'
,
},
},
],
...
...
Please
register
or
login
to post a comment