在不使用 Tumblr 界面的情况下编辑 Tumblr 主题 html 的更简单方法?

发布于 2024-10-25 11:31:04 字数 289 浏览 7 评论 0原文

在构建 Tumblr 主题时,我的服务器上有一个外部 .css,这非常方便,因为我可以直接在编辑器中工作,保存到我的服务器并刷新以查看结果。

但是,如果我需要更改主题的 HTML,我会在编辑器中进行更改,将所有内容复制到 Tumblr 中的“自定义主题”选项,然后必须保存在那里。由于其编辑器的布局方式(html 覆盖了整个预览),这确实很乏味且麻烦。

有人有更流畅的工作流程吗? 即使它涉及在调整时直接从我的服务器查看我的 .html,然后在完成后将其粘贴进去。就像注入测试内容的某种方式一样,因此它不仅仅是 html 模板标签?

In building a Tumblr theme I've got an external .css on my server which is very convenient because I can work directly in my editor, save to my server and refresh to see my results.

However, if I need to make changes to the HTML of my theme I've been making the changes in my editor, copying everything over to the "Customize Theme" option in Tumblr, then having to save there. This is really tedious and cumbersome because of the way their editor is laid out (the html covers the entirety of the the preview).

Does anyone have a smoother workflow?
Even if it involves just viewing my .html directly from my server when tweaking, then pasting it in when done. Like some way to inject test content so it's not just the html template tags?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

逆夏时光 2024-11-01 11:31:04

虽然就主题花园而言,Tiny Giant Studios 是正确的,但没有什么可以阻止您在积极开发的同时进行外部托管,直到您满意为止。

为此,您可以尝试 Tumblr Themr。我还没有真正尝试过,但听起来很有希望。

编辑:由于原始链接无法解析,您也可以尝试他们的 github 页面

While Tiny Giant Studios is right as far as the Theme Garden is concerned, there's nothing stopping you from externally hosting 'til your heart's content while you're actively developing.

To that end, you might try Tumblr Themr. I haven't actually tried it yet, but it sounds promising enough.

EDIT: Seeing as the original link is not resolving, you may also try their github page

橘和柠 2024-11-01 11:31:04

不幸的是,简短的答案是否定的。

Tumblr 系统要求所有资源(从 CSS 文件到图像)都保存在 tumblr 服务器上。鉴于主题开发人员(目前无论如何)无法直接通过 ftp 访问主题目录(如果存在的话),因此无法单独使用编辑器(例如 notepadd++)工作...

我不确定他们是否正在考虑改变这一点,但目前我们仍坚持使用复制/粘贴解决方案。

不过,您可以尝试的一件事是复制所有 HTML 标记,然后使用浏览器插件(例如 stylebot 或 chrome 的开发人员工具)来编写 CSS,完成后,复制您的标题部分中的所有 CSS主题。

The short answer is an unfortunate no.

The Tumblr system requires that all assets (from CSS files to images) be kept on the tumblr server. Seeing as theme developers (at the moment in any case) do not have direct ftp access to a theme's directory (if that even exists), one cannot work from an editor (e.g. notepadd++) alone...

I'm not sure if they're looking into changing this, but for the time being we're stuck with being copy/paste solutions.

One thing you could, however try is copying over all the HTML markup and then using browser plugins - like stylebot or developer tools for chrome - to write the CSS and once you're done, copying over all the CSS in the head section of your theme.

小鸟爱天空丶 2024-11-01 11:31:04

我最近发现 Tumblr 具有 GitHub 集成功能,您只需推送到存储库,它就会更新您博客上的主题。我自己还没有尝试过,但我可能会在接下来的几个小时内尝试过。

检查一下!

编辑:我的错误是,这仅适用于计划提交其主题的主题创建者将主题添加到可由用户选择的 Tumblr 主题列表。有人可能仍然觉得这很有用,所以我会留下这个答案。

I have recently found that Tumblr features GitHub integration where you can just push to a repository and it updates the theme on your blog. I have not tried it myself but I probably will here in the next few hours.

Check it out!

EDIT: My mistake this is only for theme creators who plan on submitting their themes to the list of Tumblr themes that can be chosen by users. Someone may still find this useful so I will leave this answer.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文