Cannot read contents from file.. Warning! file_get_contents Magento 2











up vote
5
down vote

favorite












I have file type custom option.When i browse any image and add to cart the products then it shows me error.
Please check attached screenshot.



enter image description here



I have already give the permission.
Please help.Your help would be highly appreciated.










share|improve this question






















  • does the file exist ? have you checked the file permission make sure the file permission is 755
    – Idham Choudry
    Nov 28 at 7:24










  • Yes, The file permission set to 755.
    – Sunny Rahevar
    Nov 28 at 7:25










  • Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
    – Himmat Paliwal
    Nov 28 at 7:33















up vote
5
down vote

favorite












I have file type custom option.When i browse any image and add to cart the products then it shows me error.
Please check attached screenshot.



enter image description here



I have already give the permission.
Please help.Your help would be highly appreciated.










share|improve this question






















  • does the file exist ? have you checked the file permission make sure the file permission is 755
    – Idham Choudry
    Nov 28 at 7:24










  • Yes, The file permission set to 755.
    – Sunny Rahevar
    Nov 28 at 7:25










  • Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
    – Himmat Paliwal
    Nov 28 at 7:33













up vote
5
down vote

favorite









up vote
5
down vote

favorite











I have file type custom option.When i browse any image and add to cart the products then it shows me error.
Please check attached screenshot.



enter image description here



I have already give the permission.
Please help.Your help would be highly appreciated.










share|improve this question













I have file type custom option.When i browse any image and add to cart the products then it shows me error.
Please check attached screenshot.



enter image description here



I have already give the permission.
Please help.Your help would be highly appreciated.







magento2 custom-options file






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 28 at 7:14









Sunny Rahevar

894112




894112












  • does the file exist ? have you checked the file permission make sure the file permission is 755
    – Idham Choudry
    Nov 28 at 7:24










  • Yes, The file permission set to 755.
    – Sunny Rahevar
    Nov 28 at 7:25










  • Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
    – Himmat Paliwal
    Nov 28 at 7:33


















  • does the file exist ? have you checked the file permission make sure the file permission is 755
    – Idham Choudry
    Nov 28 at 7:24










  • Yes, The file permission set to 755.
    – Sunny Rahevar
    Nov 28 at 7:25










  • Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
    – Himmat Paliwal
    Nov 28 at 7:33
















does the file exist ? have you checked the file permission make sure the file permission is 755
– Idham Choudry
Nov 28 at 7:24




does the file exist ? have you checked the file permission make sure the file permission is 755
– Idham Choudry
Nov 28 at 7:24












Yes, The file permission set to 755.
– Sunny Rahevar
Nov 28 at 7:25




Yes, The file permission set to 755.
– Sunny Rahevar
Nov 28 at 7:25












Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
– Himmat Paliwal
Nov 28 at 7:33




Also give writable access to /tmp/opt/lamp/temp, you can run chmod -R 777 /tmp/opt/lamp/temp
– Himmat Paliwal
Nov 28 at 7:33










1 Answer
1






active

oldest

votes

















up vote
3
down vote



accepted










You have to give proper permission and have to give proper user to /tmp/opt/lampp/temp folder.



Apache user means www-data don't have proper permission at that folder.






share|improve this answer























  • There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
    – Sunny Rahevar
    Nov 28 at 8:38










  • please help me!!
    – Sunny Rahevar
    Nov 28 at 9:44










  • create a folder at /tmp/opt/lampp/temp and check what happenn
    – Amit Bera
    Nov 28 at 9:59










  • Or create a folder name 'tmp` at pub/media/
    – Amit Bera
    Nov 28 at 10:09










  • No Luck !!!!!!!
    – Sunny Rahevar
    Nov 28 at 10:18











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "479"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f251570%2fcannot-read-contents-from-file-warning-file-get-contents-magento-2%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
3
down vote



accepted










You have to give proper permission and have to give proper user to /tmp/opt/lampp/temp folder.



Apache user means www-data don't have proper permission at that folder.






share|improve this answer























  • There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
    – Sunny Rahevar
    Nov 28 at 8:38










  • please help me!!
    – Sunny Rahevar
    Nov 28 at 9:44










  • create a folder at /tmp/opt/lampp/temp and check what happenn
    – Amit Bera
    Nov 28 at 9:59










  • Or create a folder name 'tmp` at pub/media/
    – Amit Bera
    Nov 28 at 10:09










  • No Luck !!!!!!!
    – Sunny Rahevar
    Nov 28 at 10:18















up vote
3
down vote



accepted










You have to give proper permission and have to give proper user to /tmp/opt/lampp/temp folder.



Apache user means www-data don't have proper permission at that folder.






share|improve this answer























  • There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
    – Sunny Rahevar
    Nov 28 at 8:38










  • please help me!!
    – Sunny Rahevar
    Nov 28 at 9:44










  • create a folder at /tmp/opt/lampp/temp and check what happenn
    – Amit Bera
    Nov 28 at 9:59










  • Or create a folder name 'tmp` at pub/media/
    – Amit Bera
    Nov 28 at 10:09










  • No Luck !!!!!!!
    – Sunny Rahevar
    Nov 28 at 10:18













up vote
3
down vote



accepted







up vote
3
down vote



accepted






You have to give proper permission and have to give proper user to /tmp/opt/lampp/temp folder.



Apache user means www-data don't have proper permission at that folder.






share|improve this answer














You have to give proper permission and have to give proper user to /tmp/opt/lampp/temp folder.



Apache user means www-data don't have proper permission at that folder.







share|improve this answer














share|improve this answer



share|improve this answer








edited Nov 28 at 7:44

























answered Nov 28 at 7:33









Amit Bera

56.5k1370169




56.5k1370169












  • There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
    – Sunny Rahevar
    Nov 28 at 8:38










  • please help me!!
    – Sunny Rahevar
    Nov 28 at 9:44










  • create a folder at /tmp/opt/lampp/temp and check what happenn
    – Amit Bera
    Nov 28 at 9:59










  • Or create a folder name 'tmp` at pub/media/
    – Amit Bera
    Nov 28 at 10:09










  • No Luck !!!!!!!
    – Sunny Rahevar
    Nov 28 at 10:18


















  • There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
    – Sunny Rahevar
    Nov 28 at 8:38










  • please help me!!
    – Sunny Rahevar
    Nov 28 at 9:44










  • create a folder at /tmp/opt/lampp/temp and check what happenn
    – Amit Bera
    Nov 28 at 9:59










  • Or create a folder name 'tmp` at pub/media/
    – Amit Bera
    Nov 28 at 10:09










  • No Luck !!!!!!!
    – Sunny Rahevar
    Nov 28 at 10:18
















There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
– Sunny Rahevar
Nov 28 at 8:38




There is no any directory exist like /tmp/opt/lampp/temp .... But i have setup the project in /tmp/opt/lampp/htdocs/Ronnie_Work/magento226.So why error display like this? please check this screenshot.. nimb.ws/tDEwNU
– Sunny Rahevar
Nov 28 at 8:38












please help me!!
– Sunny Rahevar
Nov 28 at 9:44




please help me!!
– Sunny Rahevar
Nov 28 at 9:44












create a folder at /tmp/opt/lampp/temp and check what happenn
– Amit Bera
Nov 28 at 9:59




create a folder at /tmp/opt/lampp/temp and check what happenn
– Amit Bera
Nov 28 at 9:59












Or create a folder name 'tmp` at pub/media/
– Amit Bera
Nov 28 at 10:09




Or create a folder name 'tmp` at pub/media/
– Amit Bera
Nov 28 at 10:09












No Luck !!!!!!!
– Sunny Rahevar
Nov 28 at 10:18




No Luck !!!!!!!
– Sunny Rahevar
Nov 28 at 10:18


















draft saved

draft discarded




















































Thanks for contributing an answer to Magento Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f251570%2fcannot-read-contents-from-file-warning-file-get-contents-magento-2%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Quarter-circle Tiles

build a pushdown automaton that recognizes the reverse language of a given pushdown automaton?

Mont Emei