我正在为一个项目制作一个类似博客的页面。当用户点击标题时,会显示一个 div 和帖子。目前,我的 html 文件中有第一篇文章的文本。但是,有很多帖子,我不希望所有帖子都在我的 html 中。有没有办法插入文本文件而不是输入所有文本?
我一直在研究它,我发现了很多关于使用 PHP 的信息。但是,我对它不是很熟悉,所以如果有人能详细解释这个过程,如果它是最好的选择,将不胜感激。
<!-- I have this div with the text and I would like to replace it with a text file. -->
<div id="b1">
<span class="closebtn">x</span>
<h2> Integrating Informational Technology with Operational Technology </h2>
<h3> What Are the Challenges? </h3>
<p> The common challenge manufacturers face when integrating new technology to drive efficiencies is most often having a “connected” system. Three usual issues prevent manufacturing companies from pursuing a connected system including human barriers, rising costs, and a lack...</p>
</div>
<!-- More text here -->