I have purchased the premium version today and simply can't get the demo "File_update.php" to work at all. First problem: the grid shows with broken image links. Second problem: The Edit and Add forms display without an upload button (they are both simple text boxes).
One contains "Invoice with total 1000.00" and the other "href="/phpgridorg/demos/editing//Invoice with total 1000.00" target="_blank"><img height="100" src="/phpgridorg/demos/editing//Invoice with total 1000.00">".
This is not surprising because the virtual column "logo" points at the column "note" and the data for that field contains the data above.
I also don't see how "$col["upload_dir"] = "temp";" makes any sense.
Does anyone know how to make this sample work?
The upload_dir is the path where the uploaded files will be stored on server.
It is relative to the grid code file.
In example, the note column is used for attachment. It will show the desired image, when you edit this row and upload some image with that record.
In demo, It works with 2 columns. First column is set to upload the file. It is hidden in listing.
Second column is used to show download link of uploaded file.
Thanks for your response. You have not addressed why I would have no upload button on the edit form. I am using the unmodified example code with your sample database. I assume from your reply that there should be a folder "temp" in the folder that phpgrid.php is in. Correct? I have added temp folders everywhere but can't make the sample code work.
Which OS and Browser are you using. I'll try to regenerate the case.
Currently, without changing demo it should show like …
For upload directory, you should not be worried as it is created if does not exist. Core issues seems to be different display now.
Awaiting your update …
That picture is exactly what I would expect to see but on my system there is no upload button. Only a text field where is should be.
Server: Win 7 running XAMPP
Client: I have tested with latest versions of Chrome and IE from multiple different systems (Win8, Win 7 and locally on the server) and get the same effect.
I am starting to suspect XAMPP and some file upload setting ……
How useful was this discussion?
Click on a star to rate it!
Average rating / 5. Vote count:
We are sorry that this post was not useful for you!
Let us improve this post!
Thanks for your feedback!