• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

on setting callback type to GET_USER_PROFILE_API when will the function trigger ?

New Here ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

I am trying to set user profile using this . But when i try adding annotations it still shows as Guest.

 

https://pastebin.com/Ww8rH40M

TOPICS
PDF Embed API

Views

571

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

NVM, I was previewing somewhere else. Maybe that's why it didn't work. Got it working after doing a previewFile

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

For other developers who might run into this question, I have a CodePen here that shows how to set up user profiles. There are two views side by side reviewing the same document. The left and right sides have two different user profiles assigned and the event callbacks make it so that the user on each side can only select their own annotations.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

Thanks a lot Joel 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 07, 2020 Aug 07, 2020

Copy link to clipboard

Copied

how to get the file ID sir? is this manually created

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 08, 2020 Aug 08, 2020

Copy link to clipboard

Copied

LATEST

They are arbitrary but I use the second element in the document ID array of the PDF. The document ID is an array of two strings in hex-encoded binary format. The first string is a permanent identifier based on the contents of the file at the time it was originally created; it does not change when the file is incrementally updated. The second string is a changing identifier based on the file’s contents at the time it was last updated. These identifiers are defined by the optional ID entry in a PDF file’s trailer dictionary. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources