當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Helper::getFullUrl方法代碼示例

本文整理匯總了PHP中Helper::getFullUrl方法的典型用法代碼示例。如果您正苦於以下問題:PHP Helper::getFullUrl方法的具體用法?PHP Helper::getFullUrl怎麽用?PHP Helper::getFullUrl使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Helper的用法示例。


在下文中一共展示了Helper::getFullUrl方法的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: actionUpload

 /**
  * 文件上傳
  */
 public function actionUpload()
 {
     $uploader = new Uploader();
     if (Yii::app()->request->isPostRequest) {
         //斷點上傳
         $uploader->initSimple('kindeditor')->uploadSimple('kindeditor_file');
         $error = $uploader->getError();
         if (!$error) {
             //返回kindeditor接收的json格式
             exit(CJSON::encode(array('error' => 0, 'url' => Helper::getFullUrl($uploader->file_path))));
         } else {
             exit(CJSON::encode(array('error' => 0, 'message' => $error)));
         }
     }
 }
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:18,代碼來源:KindeditorController.php

示例2: run

 public function run()
 {
     $uploader = new Uploader();
     if (Yii::app()->request->isPostRequest) {
         //普通上傳
         $uploader->initSimple('album')->uploadSimple('simple_file');
         $error = $uploader->getError();
         if (!$error) {
             $data = array('file_name' => $uploader->file_name, 'file_path' => $uploader->file_path, 'file_path_full' => Helper::getFullUrl($uploader->file_path), 'thumb_path' => $uploader->thumb_path, 'thumb_path_full' => Helper::getFullUrl($uploader->thumb_path), 'file_ext' => $uploader->file_ext);
             App::response(200, 'success', $data);
         } else {
             App::response(101, $error);
         }
     }
 }
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:15,代碼來源:UploadSimpleAction.php

示例3: run

 public function run()
 {
     $uploader = new Uploader();
     if (Yii::app()->request->isPostRequest) {
         //斷點上傳
         $uploader->initResumable('album')->uploadResumable('file');
         $error = $uploader->getError();
         if (!$error) {
             $data = array('file_name' => $uploader->file_name, 'file_path' => $uploader->file_path, 'file_path_full' => Helper::getFullUrl($uploader->file_path), 'file_ext' => $uploader->file_ext);
             App::response(200, 'success', $data);
         } else {
             App::response(101, $error);
         }
     } else {
         //校驗已上傳的片段
         $uploader->checkExistChunks();
     }
 }
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:18,代碼來源:UploadResumableAction.php

示例4: foreach

    ?>
                    <?php 
    foreach ($imageList as $img) {
        ?>
                        <li>
                            <img src="<?php 
        echo Helper::getFullUrl($img);
        ?>
" width="100px" height="100px">
                            <input type="hidden" value="<?php 
        echo $img;
        ?>
" name="imagelist[]">
                            <div class="clear">
                                <a href="<?php 
        echo Helper::getFullUrl($img);
        ?>
" class="left" target="_blank">[查看]</a>
                                <a href="javascript:;" class="right" onclick="deleteFile(this)">[刪除]</a>
                            </div>
                        </li>
                    <?php 
    }
    ?>
                <?php 
}
?>
            </ul>
        </td>
    </tr>
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:30,代碼來源:_form.php

示例5:

    echo $row->id;
    ?>
"><?php 
    echo $row->id;
    ?>
</td>
                <td>
                    <a href="<?php 
    echo Helper::getFullUrl($row->file_name);
    ?>
" target="_blank">
                        <?php 
    if (in_array($row->file_ext, array('jpg', 'png', 'bmp', 'gif'))) {
        ?>
                        <img src="<?php 
        echo Helper::getFullUrl($row->file_name);
        ?>
" alt="<?php 
        echo $row->real_name;
        ?>
" width="70"  height="70" title="<?php 
        echo $row->real_name;
        ?>
"/>
                        <?php 
    } else {
        ?>
                            <?php 
        echo $row->real_name;
        ?>
                        <?php 
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:31,代碼來源:index.php

示例6: foreach

?>
</th>
                <th width="8%"><?php 
echo Yii::t('admin', 'Operate');
?>
</th>
            </tr>
        </thead>
        <?php 
foreach ($datalist as $dk => $row) {
    ?>
            <?php 
    $type = ModelType::model()->findByPk($row->type);
    if ($type) {
        $type_name = $type->type_name;
        $view_url = Helper::getFullUrl($this->createUrl('/' . $type->type_key . '/view', array('id' => $row->content_id)));
    } else {
        $type_name = '未知';
        $view_url = 'javascript:alert("數據錯誤");';
    }
    ?>
            <tr class="tb_list">
                <td><input type="checkbox" name="id[]" value="<?php 
    echo $row->id;
    ?>
" /><?php 
    echo $row->id;
    ?>
</td>
                <td><input name="sortOrder[<?php 
    echo $row->id;
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:31,代碼來源:index.php

示例7:

      <td>
            <input name="img_banner" id="special_banner" type="hidden" value="<?php 
echo $model->img_banner;
?>
"/>
            <input name="simple_file" id="fileupload_banner" onclick="fileUpload()" type="file" />
            <div id="banner_preview">
            <?php 
if ($model->img_banner) {
    ?>
            <a href="<?php 
    echo Helper::getFullUrl($model->img_banner);
    ?>
" target="_blank">
                <img style="max-width: 900px; max-height: 300px; padding:5px; border:1px solid #cccccc;" src="<?php 
    echo Helper::getFullUrl($model->img_banner);
    ?>
" align="absmiddle" />
            </a>
            <?php 
}
?>
     
      </td>
    </tr>

    <!-- 專題簡介 -->
    <tr>
        <td class="tb_title"><?php 
echo $form->label($model, 'introduce');
?>
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:31,代碼來源:_form.php

示例8: end

                <?php 
if ($model->video_file) {
    ?>
           
                    <li>
                        <span style="color:green"><?php 
    echo end(explode('/', $model->video_file));
    ?>
</span>
                        <input type="hidden" value="<?php 
    echo $model->video_file;
    ?>
" name="video_file">
                        <div class="clear">
                            <a href="<?php 
    echo Helper::getFullUrl($model->video_file);
    ?>
" class="left" target="_blank">[查看]</a>
                            <a href="javascript:;" class="right" onclick="deleteFile(this)">[刪除]</a>
                        </div>
                    </li>           
                <?php 
}
?>
            </ul>
        </td>
    </tr>

    <tr>
        <td class="tb_title">
            <?php 
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:31,代碼來源:_form.php

示例9: pathinfo

                <?php 
if ($model->soft_file) {
    ?>
           
                    <li>
                        <span style="color:green"><?php 
    echo pathinfo($model->soft_file, PATHINFO_BASENAME);
    ?>
</span>
                        <input type="hidden" value="<?php 
    echo $model->soft_file;
    ?>
" name="soft_file">
                        <div class="clear">
                            <a href="<?php 
    echo Helper::getFullUrl($model->soft_file);
    ?>
" class="left" target="_blank">[查看]</a>
                            <a href="javascript:;" class="right" onclick="deleteFile(this)">[刪除]</a>
                        </div>
                    </li>           
                <?php 
}
?>
            </ul>
        </td>
    </tr>

    <tr>
        <td class="tb_title"><?php 
echo $form->label($model, 'language');
開發者ID:jerrylsxu,項目名稱:yiifcms,代碼行數:31,代碼來源:_form.php


注:本文中的Helper::getFullUrl方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。