1

我正在尝试获取我之前保存的 html 文件的内容,当我检查 html 时一切都正确,但是当我尝试通过这样做访问它时:

$html = Storage::disk('local')->get(Session('view'));

我得到一个包含我的 html 一部分的字符串,我不明白为什么我的 html 全部被破坏,知道我可能做错了什么吗?

原始文件:

  <meta charset="UTF-8">
    <link href="http://127.0.0.1:8000/css/pdfpreview.css" rel="stylesheet" type="text/css">
    <div class="pdfContainer">
        <img src="http://127.0.0.1:8000/image/logo.png">
        <div class="soumissionInfoContainer">
            <h2>Soumission</h2>
            <p>Soumission S2-18</p>
            <p>Date: 20-02-2017</p>

        </div>
        <div class="clientInfoContainer">
            <h3>Destinataire</h3>
            <strong>Jean Tremblay</strong>
            <p>1010 St Hubert</p>
            <p>G7H 2B1</p>
            <p>418 555 5555</p>
        </div>
        <table class="previewTable">
            <tbody><tr>
            </tr><tr>
                <th>Quantité</th>
                <th>Description</th>
                <th>Prix</th>
            </tr>
                                                                                                                                                                                                                                                                                                                                                                                                                                        </tbody></table>
                    <p class="totalSoumission">TOTAL AVANT
            TAXES: 0$</p>
        <div class="ligne_signature">
            À la signature, ce devis est bon pour travaux et valide 90 jours
        </div>
    </div>

我从转储中得到的输出$html

"""
\r\n
    <meta charset="UTF-8">\r\n
    <link href="http://127.0.0.1:8000/css/pdfpreview.css" rel="stylesheet" type="text/css">\r\n
    <div class="pdfContainer">\r\n
        <img src="http://127.0.0.1:8000/image/logo.png">\r\n
        <div class="soumissionInfoContainer">\r\n
            <h2>Soumission</h2>\r\n
            <p>Soumission S2-18</p>\r\n
            <p>Date: 20-02-2017</p>\r\n
\r\n
        </div>\r\n
        <div class="clientInfoContainer">\r\n
            <h3>Destinataire</h3>\r\n
            <strong>Jean Tremblay</strong>\r\n
            <p>1010 St Hubert</p>\r\n
            <p>G7H 2B1</p>\r\n
            <p>418 555 5555</p>\r\n
        </div>\r\n
        <table class="previewTable">\r\n
            <tbody><tr>\r\n
            </tr><tr>\r\n
                <th>Quantité</th>\r\n
                <th>Description</th>\r\n
                <th>Prix</th>\r\n
            </tr>\r\n
                                                                                                                                                                                                                                                                                                                                                                                                                                               </tbody></table>\r\n
4

0 回答 0