You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

codeconfigs's avatar
codeconfigs
Explorer | Level 3
6 months ago

Getting Duplicated Dropbox File ID from SDK(PHP Version)

Hello Forum! 👋

 

Nice to meet everyone in this awesome community.

 

I’m developing a WordPress plugin that allows users to manage their Dropbox files directly from the WordPress dashboard. This plugin integrates the Dropbox SDK for PHP to provide seamless access to Dropbox’s file management features. Users can view, upload, download, and organize their Dropbox files without leaving their WordPress site.

 

However, I’ve encountered an issue with duplicated file IDs when using the Dropbox SDK in PHP. Any guidance or insights from those who have faced similar challenges would be greatly appreciated.

 

Looking forward to your suggestions and thank you in advance for your help!

  • Здравко's avatar
    Здравко
    Legendary | Level 20

    codeconfigs wrote:

    ...

    However, I’ve encountered an issue with duplicated file IDs when using the Dropbox SDK in PHP. ...


    Hi codeconfigs,

    Your description is very "thin" and not enough for any conclusion. What are you doing when that happens? 🧐🤔 Some example API calls sequence letting the issue reproduction might clarify your situation.

    The reason may be very different - starting from logical bug in your code up to mistake in interpretation of different list page results (where in some specific cases, such duplication is possible - uniqueness is guaranteed in border of single page only) and all between. Share some more details to clarify your question.

    • codeconfigs's avatar
      codeconfigs
      Explorer | Level 3

      Hi Здравко 

      Thanks for your comment. You're correct. 

      Single page has unique ID but we're storing ID's in mySQL DB(In WordPress) from different pages. In DB, we found some duplicate ID's and getting unexpected folder structure. 

       

      Thank you

      • Здравко's avatar
        Здравко
        Legendary | Level 20

        codeconfigs, I cannot be more concrete without more exact point/example what are you doing and it's going wrong accordingly.

         


        codeconfigs wrote:

        ..., we found some duplicate ID's ...


        There is no way to exist duplicate IDs. Every file/folder ID identifies in unique way particular file/folder. Though, keep in mind that ID identify the file/folder unit as such, neither path nor name. The same file/folder may be moved on other place and will keep its ID on the new path (and eventually name). At the same time on the old path another file may get up with different ID, of course. If you don't clearly understand this, you may get in confusion! If you are familiar with local FS params, Dropbox file/folder ID is something very similar to inode (roughly, you can count them as same things; I hope this analogy can help you clarify the things). Is it possible to have duplicate inode in particular partition on your computer? 😉

         


        codeconfigs wrote:

        ... getting unexpected folder structure. 

        ...


        That sounds like a logical mistake due to misunderstanding of IDs nature.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,910 PostsLatest Activity: 3 days ago
333 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!