Okay
  Public Ticket #3302661
File from provided URL is empty.
Closed

Comments

  • Alison M started the conversation

    I have changed an excel file (literally just updated cells on one column). Updated the file from media. Now receiving: 

    Error
    File from provided URL is empty.

    It is literally named the same. I want this file to work because it is on the first page of list files. Why can I not access the table to correct? Can you? Milos is an admin on the site.


    Alison

  •  1,688
    Miloš replied

    Hi, Alison.

    Sorry for the delay.

    I am able to log in the Wp-Admin, and i see that you have 5.3 wpDatatables version installed,

    so this behaviour sounds strange.

    We did have a bug that manifested during 'file location' on table save changes for tables linked with existing Excel files,  but that was fixed in version 5.2, so it seems this is a new issue we haven't seen before.

    4158330346.png

    Could you send me the path of this Excel file that you are trying to use in the table in our plugin?

    If the Excel file is confidential, please send the teply as PRIVATE message.

    And if you can point out the ID of the existing/linked table.

    Thank you.

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables

  • Alison Watson Maston replied

    I am sorry for the delayed response. I lost track of this completely. The URL on the website is: 

    https://simsburyfreelibrary.org/sfl-quarterly-article-index/

    The error on the page is: Provided file /homepages/21/d673975321/htdocs/wp-content/uploads/2023/02/SFL-Quarterly-Subject-Index-Publication-02262023.xlsx does not exist!

    The file exists in the media library: https://simsburyfreelibrary.org/wp-content/uploads/2023/02/SFL-Quarterly-Article-Index-Publication-02262023.xlsx

    I have had the problem in the past and resolved it by creating a new table, but now the tables I use the most are at the end of my file of tables and I really would like to use the original tables.

    The other URL is: https://simsburyfreelibrary.org/wp-content/uploads/2023/03/SFL-Quarterly-Name-Index-Publication-02262023.xlsx

    I would like to use table 2 for that, but if I cannot, I won't. Also....If I delete a table, why can't I reuse the number?

    Thanks.
    Alison

  •  1,688
    Miloš replied

    Hi, Alison.

    Firstly, my apology for the waiting time on this reply.
    We had our Orthodox Easter holiday break which increased the delay.
    Thank you very much for your patience.

    -

    So i can see from the full URL path,  the error in the page says that our plugin is "expecting" to have this source table file path as :

    /homepages/21/d673975321/htdocs/wp-content/uploads/2023/02/SFL-Quarterly-Subject-Index-Publication-02262023.xlsx

    ( So this was the old domain path to the Excel file :  /homepages/21/d673975321/htdocs/)

    But, your file is now existing in the Media Library under a different path;

    make note of the first part of this path, the domain is different ( https://simsburyfreelibrary.org) :

     https://simsburyfreelibrary.org/wp-content/uploads/2023/02/SFL-Quarterly-Article-Index-Publication-02262023.xlsx

    And you also changed the file name, if i see this correctly;

    the old file was named like :

    SFL-Quarterly-Subject-Index-Publication-02262023.xlsx

    while this new Excel is :

    SFL-Quarterly-Article-Index-Publication-02262023.xlsx

    -

    If you wish to overwrite the source file while it is connected to an existing table, 

    without having to make  a new table - you have to make sure to have the same URL file path, and have the same file name, and same column structure. ( same number of columns, and same Header names of all columns)

    -

    In the future, if you want to overwrite / update the file on its source;

    when the table is already connected/  you have to make sure that the file is in the same URL path, and has exactly the same file name.

    -

    There is a workaround if you need to change the column structure or filename, though.

    In order to safely do this,  while the table is still connected to the "old file";

    you can go in the table settings of our plugin,

    and there you can manually replace the 'Input file path or URL', then hit "Save Changes" and the table will safely change the data source without breaking.

    6570495094.png

    -

    Now, we did have a bug in one of the older versions for this behaviour, if people change file source,

    they would get an error.

    You did not confirm do you have the latest version of wpDataTables installed 5.5 ?

    If not, please update to make sure that you're not having that bug.

    -

    The workaround was to switch the File Location choice from WP Media Library to  URL From Any Domain,

    Save Changes - and then go back to WP Media Library and Paste the URL to the file, Save Changes.

    8266023847.png

    But if you are not able to go in this table settings at all;

    the only remaining thing is to go in your Database via PHPMyAdmin,

    and there you can manually change the file Path for this table's source file.

    -


    This workaround is for people who change Domain Name and their table data becomes empty, 

    then it means that the path to the files most likely changed.

    First, to check what is the "new path" on your new site,

    you can create a new table linked to any Excel file ( or CSV file), and it should generate just fine. 

    Once you do that, access your database, and open 'wp_wpdatatables' database table.

    ( the wp_ prefix is default WordPress Database table prefix, on your site it might be different)

    In the "content" column, you will see the path related to the new table. 

    6078389527.png
    1893629511.png

    So, if the new file is stored in (for example):

    /var/www/html/your_NEW_site/wp-content/uploads/2021/02/file-one.xls

    And your old files are in:

    /var/www/html/your_OLD_site/wp-content/uploads/2021/02/file-two.xls

    You need to modify the content column for each row, and replace the path.

    To do that, you can run this SQL command on your database ( via your database management tool, such as PHPMyAdmin):

    UPDATE `wp_wpdatatables` SET content=REPLACE(content,'this_part','that_part')
    

    Please bear in mind that wp_ is the default prefix of WordPress, 

    but on your site it could be anything, so you should run `your_prefix_wpdatatables` and actually replace the part of the path in "this_part" and "that_part" sections.

    If you're unsure how to do this SQL Query in your database, we can do it for you if you can provide us with WP-Admin Administrator access,

     URL to the site, with a temporary wp-admin user (administrator), 

    and database access (phpMyAdmin) access URL with credentials.

    -

    Let me know if that helps; and if you need to send us any access, please make sure to mark the reply as PRIVATE, for safety.

    Thank you.


    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables

  • Alison Watson Maston replied

    Hi. Yes...we have the current version. Yes, I changed the file and the file name because we could not access it at all. That was my question. Once we have this issue, there is no way to change it on the front end. Gives a red error box.

    So you said for that:

    "But if you are not able to go in this table settings at all;

    the only remaining thing is to go in your Database via PHPMyAdmin,

    and there you can manually change the file Path for this table's source file."

    So if/when it happens again, I will try that.

    Alison


  •  1,688
    Miloš replied

    Hi, Alison.

    Yes. Unfortunately, if the source file which is already connected to a table gets changed,

    such as changing the file name, or number of columns or header names, that breaks the table.

    Then you would have to either make a new table;

    or you can try to overwrite the source file with a data set with same structure/number of columns/file name/header names;

    then it might be possible;

    or you can try in the database as mentioned, to change the "content" field of the related table ID in wp_wpdatatables table.

    -

    Let us know if you have any additional questions, and of course, please don't hesitate to open new tickets if anything else happens.

    Thanks.

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables