js怎么从数据库里提取第一张图片到网站的前端页面?
比如从数据库名abc 表名ha_a_question 字段是content 里面提取第一张图片地址,第一张有可能是jpg,有可能是gif,下面代码里的12.png 也有可能是其他的数字,这些都不是固定的!怎么做呢?
<p>面板站点管理里选择伪静态,选1,内容如下,保存。</p><pre><code>location / {
if (!-e $request_filename){
rewrite ^(.*)$ /index.php?s=$1 last; break;
}
}</code></pre><p><img src="/uploads/20190719/d67b3a464ce4f75c307b0050b9a35f8e.png" alt="12.png" title="12.png"></p>