Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
lichenggang
/
seo_checker
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
eba7b088
authored
Oct 15, 2019
by
lichenggang
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
update server
parent
8ae4da3a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
server_test.py
server_test.py
View file @
eba7b088
...
@@ -62,6 +62,9 @@ class SeoCheckHandler(TornadoBaseHandler):
...
@@ -62,6 +62,9 @@ class SeoCheckHandler(TornadoBaseHandler):
dom
=
etree
.
HTML
(
t
)
dom
=
etree
.
HTML
(
t
)
data
=
dict_data
()
data
=
dict_data
()
data
[
'baidu_url'
]
=
base_url
.
format
(
target
)
data
[
'baidu_url'
]
=
base_url
.
format
(
target
)
if
'没有找到该URL'
in
t
:
data
[
'has_included'
]
=
0
return
data
if
dom
.
xpath
(
'//div[@id="content_left"]'
):
if
dom
.
xpath
(
'//div[@id="content_left"]'
):
data
[
'has_included'
]
=
1
data
[
'has_included'
]
=
1
snap_shot_url
=
dom
.
xpath
(
'//a[contains(text(),"百度快照")]/@href'
)[
0
]
snap_shot_url
=
dom
.
xpath
(
'//a[contains(text(),"百度快照")]/@href'
)[
0
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment