200字范文,内容丰富有趣,生活中的好帮手!
200字范文 > 关于利用webpy的框架下 HTML无法加载CSS和背景图片的问题

关于利用webpy的框架下 HTML无法加载CSS和背景图片的问题

时间:2022-06-01 09:19:46

相关推荐

关于利用webpy的框架下 HTML无法加载CSS和背景图片的问题

-----尚未解决,望有大神不吝赐教-----

这是我的代码,

$def with(content)<html><head><title>Gothons From Planet Percal #25</title><style type="text/css">body{background-image:url(images\bg.jpg);}</style></head><body><p>This is a paragraph for test.</p>$:content<p>This is another paragraph</p></body></html>

本意是把这个作为网页的模板,把content加入到模板中,利用了一张图片想要作为背景

并且使用webpy的框架提供服务,下面是代码

import weburls = (/hello, Index)app = web.application(urls, globals())#web.application#render = web.template.render(dgfp_31_hq/)#search the directory emplates, if there is a index, the following block can call itrender = web.template.render( emplates/, base="la

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。