有没有一种工具可以管理网站上的冗余页面?
我负责构建一个带有“二维”站点地图的网站,稍后将对此进行解释。
我正在寻找(最好是 WordPress 插件,因为该网站已经在 Wordpress 中构建)可以使管理数千个页面变得更加容易。
为了进一步解释,让我重申一下我的情况。我正在为一家建筑公司建立一个网站,他们有几个主要城市和几个关键服务。现在,他们需要每个服务的父页面,子子服务的另一个唯一页面,最后,他们正在执行服务的城市的孙子页面。
例如,如果他们在洛杉矶进行混凝土施工,URL 如下所示:
/concrete/construction/los-angeles
/los-angeles 上的内容与 /malibu 或 /burbank 上的内容相同。
但是,/concrete/design/los-angeles 会有一组不同的内容,但整个页面内容(没有一些带有城市名称的变量)将是相同的。
有没有办法在网站上管理或自动“矩阵”这些信息?我正在寻找一种工具,可以让我根据孩子的内容要求轻松地在所有孙子中添加具有相同内容的“城市”。所有孙子页面都将包含冗余内容。
如果这样的东西不存在,作为一个自由职业项目创建会有多困难?我需要这样的工具,因为我正在接近大约 500 个城市和 50 种服务(混凝土施工、混凝土设计、混凝土工程等)
I am in charge of constructing a website with a '2-dimensional' site map, as explained later.
I am looking for (preferably a Wordpress plugin, as the site is built in Wordpress already) that would make managing thousands of pages a lot easier.
To explain further, let me iterate my situation. I am building a website for a construction company, and they have several key cities and several key services. Now, they want a parent page for each service, and another unique page for the child sub-service, and finaly, a grandchild page for the city they are performing the service in.
For example, if they were doing Concrete Construction in Los Angeles, the URL would look like:
/concrete/construction/los-angeles
The content on /los-angeles would be the same as on /malibu, or /burbank.
However, there would be a different set of content for /concrete/design/los-angeles, but the entire page content (sans a few variables with city names) would be the same.
Is there a way to manage or automate 'matrixing' this information on the site? I am looking for a tool that would allow me to easily add a 'city' with the same content across all grandchildren, per the child's content requirements. All of the grandchildren pages will have redundant content across them.
Should something like this not exist, how difficult would it be to create, as a freelance side project? I need a tool like this, because I am approaching about ~500 cities and 50 services (Concrete Construction, Concrete Design, Concrete Engineering, etc)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
支持分类和标记的 CMS 系统。
例如,Drupal 有分类法,与一些分类法模块和视图一起,您实际上可以拥有数百种 URL 组合,将参数传递给视图并返回内容。但这只是一个例子。很多CMS可以满足这种需求。但不确定 WordPress,因为帖子并不是真正的页面,除非您将所有内容创建为页面。
您也可以更进一步,将令牌实现到内容和/或字符串覆盖中,以用动态值替换关键字。
A CMS system that supports taxonomy and tagging.
For instance, Drupal has Taxonony and together with some Taxonomy modules and Views, you can have virtually hundreds of combinations of URLs that pass arguments to the View and return content. That's just one example though. A lot of CMS can facilitate this need. Not sure about Wordpress though, as Posts are not really Pages, unless you have created all the content as Pages.
You could take it a step further too and implement Tokens into content and/or String Overrides to replace key words with dynamic values.
我的方法是使用模板引擎,您可以动态创建页面并缓存它们,或者只是从一组输入和输出创建静态页面,然后让您的 Web 服务器或 WordPress 使用插件缓存它们,有强大的功能几乎所有可用语言的模板解决方案。 Python、Perl、Ruby 可能是最容易设置和管理的。选择一种语言,然后 Google 搜索该语言和模板,您应该会找到很多解决方案,并选择一个您喜欢的解决方案。
The way I would go about this is using a Templating Engine to you could create the pages dynamically and cache them or just create static pages from a set of inputs and output and let your web server or WordPress cache them with a plugin, there are robust templating solutions in just about every language available. Python, Perl, Ruby would probably be the easiest to set up and manage. Pick a language and Google for that language and templating and you should find lots of solutions and pick one you are comfortable with.
创建一个 php 函数来获取页面 URL 并将其拆分为“/”。根据最后一部分,该函数应返回城市的名称。然后在您的页面上调用此 php 函数。由于您使用的是 WordPress,因此您已经拥有 php
Make a php function that will get the page URL and split it on "/". Based on the last part, the function should return the name of the city. Then use the call to this php function on your pages. Since you are using wordpress, you will already have php