Part-DB-server icon indicating copy to clipboard operation
Part-DB-server copied to clipboard

Add an html page as attachement for a project

Open Stephane-Peel opened this issue 2 weeks ago • 2 comments

I vibe coded a somewhat functionnal python script that create and InteractiveBOM (IBOM) html page that permit to locate a part ref. on a PCB.

It will be nice to import this html page as an attachement in a project. So, i tried to create a new attachement type in PartDB.

When i then try to open the imported html in PartDB the page is displayed as a text file.

It will be very nice to have the ability to display the html instead.

Stephane-Peel avatar Dec 10 '25 22:12 Stephane-Peel

polivoksvcf.html

Here is an exemple of the ibom output file i'd like to display as an attachement in PartDB.

Stephane-Peel avatar Dec 10 '25 22:12 Stephane-Peel

It is an deliberate choice that HTML get converted and shown as plain text, as it otherwise introduces security vulnerabilities, when you can run arbitary content (and especially JS) in the Part-DB website context.

There might be a solution by iframing the HTML content, but I never used that before.

jbtronics avatar Dec 11 '25 10:12 jbtronics

I had a guess about this security issue...

I will try to find a solution for this kind of use case. Including an IBOM to a project would be a killer feature !

Stephane-Peel avatar Dec 13 '25 13:12 Stephane-Peel