fileinput-preview从图像获取详细信息

时间:2016-06-02 12:54:14

标签: javascript php file-io

我使用bootstrap-fileinput将图像加载到我的项目中。是否有可能获得大小,分辨率等图像细节?

我的代码是:

<div class="col-md-4">
        <div class="fileinput fileinput-new" data-provides="fileinput">
            <div class="fileinput-new thumbnail" >
                <img src="<?php echo $src; ?>" style="width:200px;height:150px" alt=""/>
            </div>
            <div class="fileinput-preview fileinput-exists thumbnail" id="imagem" style="max-width: 200px; max-height: 150px;">
            </div>
            <div>
                <span class="btn default btn-file">
                <span class="fileinput-new">Escolher imagem </span>
                <span class="fileinput-exists">Alterar </span>
                  <input id="imagem" type="file" name="...">
                </span>
                <a id="btnRemoverImagemCapa" href="#" class="btn red fileinput-exists" data-dismiss="fileinput"> Remover </a>
           </div>
    </div>

0 个答案:

没有答案