Questions tagged [file-upload]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
14 views

How to upload image/file using custom customer attribute with Rest API Magento 2?

I have create one custom customer attribute with file type. I want to upload file using rest API and want to store it to custom media path. How to upload file is with customer registration API?
0
votes
2answers
18 views

How can I access data of Laminas\Stdlib\Parameters Object in in Magento 2?

I want to access Laminas\Stdlib\Parameters Object data in that I can access video_url data in magento2. How can I access that object data ? $product = $this->getRequest()->getFiles(); print_r($...
0
votes
0answers
18 views

File upload not working

I am using Magento 2.3.5-p1, when I try to upload any file image (JPG, JPEG, PNG) from CMS or Product Image, it is not working and showing an error. pub folder has -R 777 permissions GD and imagick ...
0
votes
1answer
26 views

Magento 2 : How to save file in media folder using custom product attribute?

I have a create product attribute But it's not save file in pub/media folder -> Vendor\Module:- Meetanshi\ProductAttachment -> attribute_field_name:- custom_product_attachment -> Media folder ...
0
votes
1answer
26 views

Import CSV file with Ui form and process it - error 404

I want to create a file uploader using Ui form, upload and process it in adminpanel. this is my Ui form code <field name="fileUploader" formElement="fileUploader"> ...
0
votes
1answer
28 views

Add to cart product with custom option “file”

I am trying to add products to cart with custom options. All are working but if custom options is file, it's not working. I've tried everything so far, but no luck. Anyone tried this and have a ...
1
vote
0answers
20 views

Show thumbnail image via Data Provider in Dynamic Rows in admin form magento 2

How can I show image thumbnail (edit form) for dynamic rows created by Magento's Row Pattern using Data Provider / Modifier. Like this link: Magento2 How to add row pattern/dynamic rows to the custom ...
0
votes
1answer
15 views

Two files upload is not working in same form in Magento product page

I have a default Magento 2.4.2.installed on my server. I have a page where there are 2 input types of file upload which is not working together. When I remove one input file type then it is working ...
0
votes
1answer
51 views

Knockout JS Implementation with Phtml ReferenceError: Unable to process binding

After a lot of search in this forum I have decided to write a question by myself. I am trying to integrate my knockout page into a phtml file in way to update the input layout after a file has been ...
0
votes
1answer
28 views

Adminform uploaded file preview

I added file upload input in AdminHtml Block like this below. $fieldset->addField( 'document', 'file', [ 'name' => 'document', ...
0
votes
1answer
16 views

Is it a bad idea to allow magento upload SVG file for CMS page?

One of my user request to ask me to make the Magento able to upload svg file to the CMS. I did some research, some say security issue, but didn't tell much what kind of security issue it may happen. ...
1
vote
1answer
37 views

create file attribute to customer image error occur in magento 2.3.6

create custom file attribute for customer, it is not compulsory or required to field but if file is not uploaded then throw error Uncaught TypeError: preg_match() expects parameter 2 to be string, ...
0
votes
0answers
17 views

Magento2 ui component binding issue for file uploader in knockout template

I am using knockout file uploader in one of checkout step, please check below screenshot: below is my code to initialize file uploader but somehow its not working: <div class="reference-...
0
votes
0answers
28 views

CSV file upload [duplicate]

Can anybody help me with how to upload the CSV file from the frontend of magento2?
0
votes
1answer
32 views

Magento2 - Customer not Able to upload file

I have multi-websites in Magento 2: Url : https://www.lilysprints.co.uk/upload-an-image.html https://nepbhprint.com/upload-an-image.html When I try to upload an image I get this error Path /var/www/...
0
votes
2answers
94 views

How can i upload SVG image on Magento 2.3.6?

Please help me. Now i can't upload SVG image on Magento V-2.3.6. I tried with below code but still can't. <type name="Magento\Cms\Model\Wysiwyg\Images\Storage"> <argument name=&...
0
votes
1answer
143 views

Array to string conversion on File upload functionality in Magento2

I am getting this error after I put a file upload button.When I click save I got this error [2021-01-20 05:42:43] main.CRITICAL: Exception message: Notice: Array to string conversion in /var/www/html/...
0
votes
2answers
1k views

How to upload new product images after Adobe Flash Player EOL?

I am wondering how can I upload new product images to my Magento 1 store? Adobe has blocked all Flash content today and I can't see upload button now. However, I am already working on my new Magento 2 ...
0
votes
0answers
32 views

How to submit a CSV file in admin and how read it in Magento2?

How to submit a CSV file in admin side and how read it in Magento2?
0
votes
0answers
30 views

Magento 2 file uploader not working in other theme in frontend

I am using magento inbuilt file uploader component in my theme, I have 5 types of different themes and have called uploader component from one of the custom module, the issue is I cannot see file ...
0
votes
1answer
56 views

Validate uploaded file extension product save in Magento 2

I have created a product attribute input type as 'file'. Vendor\Module\Setup\Patch\Data\AddProductPdfProductAttribute.php namespace Vendor\Module\Setup\Patch\Data; public function apply() { $this-&...
0
votes
0answers
40 views

Connecting SFTP in Magento 2

I am still a newbie in Magento. I am looking for a way to read csv file for automating product upload to Magento. I will be receiving the csv file that contains the product attributes (data and images)...
0
votes
0answers
17 views

How to create REST API to upload image into customer custom fields

I am using Magento Enterprise Solution. Where I have created a few custom fields (File Type) for a customer. I want to get help to create REST API to upload an image into these fields by using REST ...
0
votes
0answers
23 views

validate customer custom attribute file upload extenssion

I have created one file customer custom attribute using below code. Currently it allow all extenssion to upload. I would like to only allow .pdf or .jpeg only. It is used to upload on both frontend ...
0
votes
0answers
34 views

How to implement Ajax File Upload in Magento 2?

I have a custom form and there I'm using the default file attachment input type but I want the form uploading as a ajax. I have followed many tutorials but can't find the appropriate solution. Can ...
0
votes
3answers
239 views

Magento 2 how to read the uploaded csv from front end form

Here am trying to read the csv file which is uploaded by frontend form. but am not able to open or read the file content. here is form file code. <form class="import-shipping-form" action=...
0
votes
0answers
31 views

How to get controller path for $postUrl for reading CSV in Magento 2?

I have created custom button in Admin Menu for import CSV and created a controller with below path app/code/Tym17/AdminSample/Controller/Adminhtml/SampleTwo/Index.php Used this in my phtml file with ...
0
votes
0answers
23 views

Magento 2.3.4: Customer File Attribute not working from admin

I followed below blogs in order to create a customer file attribute. https://blog.chapagain.com.np/magento-2-customer-image-file-upload-in-registration-account-page/ https://meetanshi.com/blog/create-...
2
votes
0answers
43 views

knockout data-bind issue on the Frontend Magento 2

I have added file-uploader component in the review form. I have used below code to add browse button in the form. <div class="upload-wrapper" data-bind="scope: 'uploader'"> ...
0
votes
1answer
238 views

magento 2.3 is that posible to upload file in graphql mutation

i wondering is there any way to upload file in magento 2.3.5 via graphql mutation is there way suggest the way ? For REST API how we can upload file in magento 2.3?
0
votes
0answers
421 views

Magento 2 error:The file doesn't exist. Verify the file and try again

When I trying to upload CSV from admin site in var folder Magento through below error Attention The "/var/www/html/pub/media/var/www/html/var/test/c/a/test_3.csv" file doesn't exist. Verify ...
1
vote
1answer
25 views

limit file type in admin custom module

Hi everybody how are you I have a problem to limit the type of file that can be uploaded from the administrator panel in a custom module, I only need the type csv and xls I try a class that extends ...
0
votes
1answer
145 views

Unable to upload a file from UI component using dynamic rows in magento2.3.1

My UI component form fieldset <field name="file"> <argument name="data" xsi:type="array"> <item name="config" xsi:...
2
votes
0answers
211 views

How to add upload image in custom payment gateway ( Magento 2.3.5)

I'm very new to Magento. This is what is tried to achieve, an image uploader in custom checkout. But the problem is that I have no idea how to upload the image. The code below is what I had tried. I ...
0
votes
1answer
130 views

Magento admin ajax call file upload

I'm trying to make a ajax call in admin page to upload a csv file in directory then to make a stock update function. In my PHTML: <form method="post" enctype="multipart/form-data" id="ajaxCall" &...
0
votes
1answer
79 views

Magento 2.3.4 Custom Module Backend Admin fileUploader (MIME Type) Strict check is enable

I've created a custom module for MG2.2.2 and add file uploader the same as the product file uploader functionality. I've now installed on 2.3.4 and there is an error when I load the form: Refused to ...
1
vote
1answer
1k views

Magento 2 file upload issue - {“error”:“The file was not uploaded.”,“errorcode”:666}

I've been fighting an issue with file/image uploading through my custom Catalog module. The upload field is in a programmatically generated UI Component form. Here is how my upload field is defined in ...
0
votes
1answer
224 views

The file was not uploaded. Magento 2 custom module

I'm trying to upload image in my custom module but I always getting the "The file was not uploaded." error. I trace the code and all I can say is the $this->uploader->create() is not working. Here my ...
0
votes
1answer
115 views

Magento 2 Custom UI grid form.php validate upload file extension

I want to check the upload file extension in form.php, I have three upload file options I want to check the upload file is pdf or not. Thanks in advance. my form.php file is namespace Vendor\...
2
votes
1answer
530 views

Magento 2: upload file in frontend

I want to make a function allowed customer upload file in My Account here is description image Any helps? Thank in advance.
1
vote
0answers
31 views

Magento 2.3.2: Can't Receive Muliple Files In Email

I made a custom module which has a form for customer, in which customer fill his info, upload multiple files and on Submit, Admin receives an email with customer info and files, but my problem is when ...
1
vote
1answer
281 views

Magento 2 How to send file to another server on predefined location?

I am trying to upload a custom exported CSV to another server FTP on particular location. Step 1: Added FTP Class in constructor protected $ftp; public function __construct( \Magento\Framework\...
0
votes
1answer
29 views

Magento 2: I want to upload file in magento 2 from front-end

$uploaderFactory = $this->uploaderFactory->create(['fileId' => 'image']); I want to know 'fileId' and 'image' what is this one mean?
0
votes
1answer
181 views

Create product attribute type is file in magento 2

How to create a product attribute in file type in Magento 2 our requirement is a particular product-wise Pdf upload in Magento 2 and shows a product view page in Magento 2. So How can I sort it? ...
0
votes
1answer
581 views

The image file was not uploaded error in Magento 2 while editing the grid form

I am getting the file was not uploaded error in Magento 2 when I edit the form in the Magento 2 backend. When I try to save the form it shows an error. The problem is that it requires me to choose ...
0
votes
1answer
376 views

After Creating Custom PDF Save Magento 2.3

Using dompdf Convert Custom Email Template To Pdf But After Create PDF I Want to Save That PDF into pub/media/customFolder Here My Code :- Define in email_templates.xml :- <?xml version="1.0"...
1
vote
0answers
42 views

Magento 2: Upload image without Ui component

how can I upload an image by this way, please help me, thank you $fieldset->addField( 'image_field_name', 'image', [ 'name' => 'image_field_name',...
6
votes
4answers
15k views

Export file problem in Magento 2.3

Error: "Message is added to queue, wait to get your file soon" enter code here Open admin panel/system/Data Transfer/Export After that select all export setting and click the continue button. When ...
0
votes
1answer
269 views

Magento 2 Dynamically Add file uploader in system config

How to add a file uploader render in a dynamically added rows? something like: But in dynamically added Like: Let say before or after drop down and the input text field? Best!
2
votes
0answers
87 views

How secure is the Magento 2 File Uploader

I recently added my own form to the Magento frontend. The form contains a file type input, an used the file uploader class to save the file. But I was wondering how save this class is? I already ...