{"action":"created","issue":{"url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/135","repository_url":"https://api.github.com/repos/GetmeUK/ContentTools","labels_url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/135/labels{/name}","comments_url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/135/comments","events_url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/135/events","html_url":"https://github.com/GetmeUK/ContentTools/issues/135","id":134434724,"number":135,"title":"Not enable to view the image after upload","user":{"login":"Portekoi","id":1560754,"avatar_url":"https://avatars.githubusercontent.com/u/1560754?v=3","gravatar_id":"","url":"https://api.github.com/users/Portekoi","html_url":"https://github.com/Portekoi","followers_url":"https://api.github.com/users/Portekoi/followers","following_url":"https://api.github.com/users/Portekoi/following{/other_user}","gists_url":"https://api.github.com/users/Portekoi/gists{/gist_id}","starred_url":"https://api.github.com/users/Portekoi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Portekoi/subscriptions","organizations_url":"https://api.github.com/users/Portekoi/orgs","repos_url":"https://api.github.com/users/Portekoi/repos","events_url":"https://api.github.com/users/Portekoi/events{/privacy}","received_events_url":"https://api.github.com/users/Portekoi/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-17T23:37:47Z","updated_at":"2016-02-18T11:42:21Z","closed_at":"2016-02-18T11:41:27Z","body":"Hello,\r\n\r\nIn trying to test this framework with php. The upload is running and the image dialog box close normally. The image file is save in the server. It's OK.\r\nBut the image is not visible. In the source code, the width and the height are not transmit.\r\n\r\nI've try to delete all unneeded js/css file but I've the same issu : image do not appear.\r\n\r\nI've take the last version, follow the instructions on this page : http://getcontenttools.com/tutorials/handling-image-uploads but nothing....\r\n\r\nHere is my online code : http://portekoi.com/contentools/\r\n\r\nMy \"form.php\" php file : \r\n\r\n    $postData = $_FILES;\r\n    $target_dir = \"\";\r\n    $temp_file = $target_dir . basename($_FILES[\"image\"][\"name\"]);\r\n    $uploadOk = 1;\r\n    $imageFileType = pathinfo($temp_file,PATHINFO_EXTENSION);\r\n\t$file_name = \"\";\r\n\t$file_name = basename($_FILES[\"image\"][\"name\"], \".\" . $imageFileType) . \"-\" . rand(0, 10000) . \".\" . $imageFileType;\r\n\t$target_file = $target_dir . $file_name;\r\n    // Check if image file is a actual image or fake image\r\n    if(isset($_POST[\"submit\"])) {\r\n        $check = getimagesize($_FILES[\"image\"][\"tmp_name\"]);\r\n        if($check !== false) {\r\n            echo \"File is an image - \" . $check[\"mime\"] . \".\";\r\n            $uploadOk = 1;\r\n        } else {\r\n            echo \"File is not an image.\";\r\n            $uploadOk = 0;\r\n        }\r\n    }\r\n    // Check if file already exists\r\n    if (file_exists($target_file)) {\r\n        echo \"Sorry, file already exists.\";\r\n        $uploadOk = 0;\r\n    }\r\n    // Check file size\r\n    if ($_FILES[\"image\"][\"size\"] > 1500000) {\r\n        echo \"Sorry, your file is too large.\";\r\n        $uploadOk = 0;\r\n    }\r\n    // Allow certain file formats\r\n    if($imageFileType != \"jpg\" && $imageFileType != \"png\" && $imageFileType != \"jpeg\"\r\n    && $imageFileType != \"gif\" ) {\r\n        echo \"Sorry, only JPG, JPEG, PNG & GIF files are allowed ==> \" . $imageFileType;\r\n        $uploadOk = 0;\r\n    }\r\n    // Check if $uploadOk is set to 0 by an error\r\n    if ($uploadOk == 0) {\r\n        echo \"Sorry, your file was not uploaded.\";\r\n    // if everything is ok, try to upload file\r\n    } else {\r\n        if (move_uploaded_file($_FILES[\"image\"][\"tmp_name\"], $target_file)) {\r\n\r\n            $arr = array('size' => array('width' => 600, 'height' => 400 ), 'url' => 'http://www.portekoi.com/contenttools/'.$file_name.'');\r\n            echo json_encode($arr);\r\n\r\n        } else {\r\n            echo \"Sorry, there was an error uploading your file.\";\r\n        }\r\n    }\r\n\r\nand my save php file : \r\n        \r\n\r\n    $items = list($width, $height) = getimagesize($_POST['url']);\r\n\r\n    $arr = array('url' => $_POST['url'], 'width' => $_POST['width'], \r\n     'alt'=> \"Image\", 'size' => array('width' => $items[0], 'height' => $items[1] ));\r\n    echo json_encode($arr);\r\n\r\nSample result in json : \r\n\r\n    {\"url\":\"http:\\/\\/portekoi.com\\/contentools\\/test-2703.jpg\",\"width\":\"600\",\"alt\":\"Image\",\"size\":{\"width\":775,\"height\":587}}\r\n\r\nCan you help me?\r\n\r\nI've done something wrong maybe but I don't know what."},"comment":{"url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/comments/185678118","html_url":"https://github.com/GetmeUK/ContentTools/issues/135#issuecomment-185678118","issue_url":"https://api.github.com/repos/GetmeUK/ContentTools/issues/135","id":185678118,"user":{"login":"anthonyjb","id":3046287,"avatar_url":"https://avatars.githubusercontent.com/u/3046287?v=3","gravatar_id":"","url":"https://api.github.com/users/anthonyjb","html_url":"https://github.com/anthonyjb","followers_url":"https://api.github.com/users/anthonyjb/followers","following_url":"https://api.github.com/users/anthonyjb/following{/other_user}","gists_url":"https://api.github.com/users/anthonyjb/gists{/gist_id}","starred_url":"https://api.github.com/users/anthonyjb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthonyjb/subscriptions","organizations_url":"https://api.github.com/users/anthonyjb/orgs","repos_url":"https://api.github.com/users/anthonyjb/repos","events_url":"https://api.github.com/users/anthonyjb/events{/privacy}","received_events_url":"https://api.github.com/users/anthonyjb/received_events","type":"User","site_admin":false},"created_at":"2016-02-18T11:42:21Z","updated_at":"2016-02-18T11:42:21Z","body":"Hi @Portekoi thanks for updating the issue and letting me know and sorry I hadn't gotten around to answering the question sooner."}}