https://github.com/sjardim/processwire-simple-flickr-album
http://www.webinfopedia.com/multiple-file-download-by-creating-zip-file-in-PHP.html
http://stackoverflow.com/questions/1754352/download-multiple-files-as-zip-in-php
=====
jquery
https://github.com/biesiad/jquery-multidownload
** $('.my_download_trigger').multiDownload({ delay: 500 });
http://stackoverflow.com/questions/9047645/download-multiple-files-without-using-zip-file
https://github.com/sindresorhus/multi-download
2016/03/02
http://www.mikkonen.info/imageutil/
=====2015/11/29
http://www.smashingmagazine.com/2015/06/efficient-image-resizing-with-imagemagick/
From my tests, running ImageMagick with the following settingsproduced the smallest results, while generally being visually indistinguishable from Photoshop’s output:
mogrify -path OUTPUT_PATH -filter Triangle -define filter:support=2 -thumbnail OUTPUT_WIDTH -unsharp 0.25x0.25+8+0.065 -dither None -posterize 136 -quality 82 -define jpeg:fancy-upsampling=off -define png:compression-filter=5 -define png:compression-level=9 -define png:compression-strategy=1 -define png:exclude-chunk=all -interlace none -colorspace sRGB -strip INPUT_PATH
I looked at 11 different functions and found that -thumbnail does the best job of optimizing quality and file size.
phpFlickr authentication to access private photos
1:https://github.com/jrtilson/phpflickr/tree/master/token
download index.php & auth.php
or
my demo
2:edit index.php
2-1 mark:
//$f->auth($_SESSION[‘perms’]); //會造成迴圈
//$token = $f->auth_checkToken($_SESSION[‘phpFlickr_auth_token’]); //無用
!!important!! token usually is ok~ and phpFlickr check token is broken.
This can check token https://www.flickr.com/services/api/explore/flickr.auth.checkToken 2-2 change:
echo “” . $_SESSION[‘phpFlickr_auth_token’][_content] . “";
//要補上[_content]
3:call back URL set THIS FILE:**http://xxxxoooo.com/**auth.php
IF not sure, just index.php when you not login.
http://www.angularcode.com/useful-database-helper-class-to-generate-crud-statements-using-php-and-mysql/
這個看起來更好,滿足我的問題,不用再進crud class中,一個一個改欄位,直接帶什麼改什麼,這樣更快。
http://www.roxyfileman.com/CKEditor-file-browser
檔案下載 filedownload
Integration blueimp fileupload in ckeditor
http://stackoverflow.com/questions/14013418/integration-blueimp-fileupload-in-ckeditor
https://github.com/blueimp/jQuery-File-Upload
-—–
檔案下載 file download
1、index.php 是 建立ckeditor,主要是多一個function triggerUploadImages(url){
2、在ckeditor目錄下的config.js,補上網頁上的程式碼,要注意html : ' <iframe src= 需要給正確
2.1、index.html 是非常基本的,basic-plus.html是取jquery file uploder的範例來用,上傳完後,點選該圖或文字,就能會回傳
2.2、index.html 和 basic-plus.html兩支程式都有呼叫 parent.triggerUploadImages,把url傳回ckeditor
2.3、注意index.html的data-url=“server/php/” 路徑是否正確;basic-plus.html 這段
var url = window.location.hostname === ‘blueimp.github.io’ ?
‘//jquery-file-upload.appspot.com/’ : ‘server/php/’
路徑是否正確
基本上較麻煩的是,上傳完畢後,會回傳url,再送到CKEitor裡面。
圖片上傳在server/php/files ,會自動做縮圖
http://www.dukaweb.net/2014/01/how-to-make-upload-image-in-ckeditor.html
In script tag, which we call CKEditor put one more code:
CKEDITOR.replace( ‘editor1’, {
filebrowserUploadUrl: “upload/upload.php”
} );
In upload.php
if (file_exists(“img/"; . $_FILES[“upload”][“name”]))
{
echo $_FILES[“upload”][“name”] . " already exists please choose another image.";
}
else
{
move_uploaded_file($_FILES[“upload”][“tmp_name”],
“img/” . $_FILES[“upload”][“name”]);
echo “Stored in: " . “img/” . $_FILES[“upload”][“name”];
}
If you get an error “image source url is missing“, that means the url of the image doesn’t pass to the image info tab, you can fix this error by adding the php code to pass the image url.