Vista Combinata Vista Piatta Vista ad Albero
Discussioni [ Precedente | Successivo ]
toggle
Ashwani Kumar
selecting image form "Doc. and media" on custom portlet.!!!
31 dicembre 2012 0.02
Risposta

Ashwani Kumar

Punteggio: Junior Member

Messaggi: 26

Data di Iscrizione: 19 ottobre 2012

Messaggi recenti

Hi All,

In my Cutom Portet...I am having a Browse button for selecting a file(that could be images), my requirement is, Once i click on Browse button..it should allow me to select the images from the "Document and Library" of Liferray.

Similary , How i can store the path of selected image in my custom table.

Thanks in advance.

Regards,
Ashwani
David H Nebinger
RE: selecting image form "Doc. and media" on custom portlet.!!!
31 dicembre 2012 5.43
Risposta

David H Nebinger

Community Moderator

Punteggio: Liferay Legend

Messaggi: 8378

Data di Iscrizione: 1 settembre 2006

Messaggi recenti

You do not store a path. Store the ID from the entity. That ID would be used to access the entity at a later time.

Browsing would just be a matter of invoking the API method to get the entities. You can use the keys returned to access the binary data of the content, then stream that back to the portlet for display.

You can reference the current source for the IG portlet to see how it's displaying the images inline for an example.
Hitoshi Ozawa
RE: selecting image form "Doc. and media" on custom portlet.!!!
31 dicembre 2012 6.17
Risposta

Hitoshi Ozawa

Punteggio: Liferay Legend

Messaggi: 7952

Data di Iscrizione: 23 marzo 2010

Messaggi recenti

Once i click on Browse button..it should allow me to select the images from the "Document and Library" of Liferray.


You're mixing David up. You probably mean "Document and Media" library. IG portlet in David's reply means Image Gallery portlet but that's just "Document and Media" portlet in the current version.
David H Nebinger
RE: selecting image form "Doc. and media" on custom portlet.!!!
31 dicembre 2012 7.52
Risposta

David H Nebinger

Community Moderator

Punteggio: Liferay Legend

Messaggi: 8378

Data di Iscrizione: 1 settembre 2006

Messaggi recenti

Hitoshi Ozawa:
IG portlet in David's reply means Image Gallery portlet but that's just "Document and Media" portlet in the current version.


I'm still on the Xmas/New Years holiday, so I'm kinda answering w/o looking at the code emoticon
Ashwani Kumar
RE: selecting image form "Doc. and media" on custom portlet.!!!
1 gennaio 2013 0.51
Risposta

Ashwani Kumar

Punteggio: Junior Member

Messaggi: 26

Data di Iscrizione: 19 ottobre 2012

Messaggi recenti

David H Nebinger:
You do not store a path. Store the ID from the entity. That ID would be used to access the entity at a later time.

Browsing would just be a matter of invoking the API method to get the entities. You can use the keys returned to access the binary data of the content, then stream that back to the portlet for display.


Hi David,

What APIs, I can invoke for selecting the image from "Doc and Media" for my browse button in custom portlet.??

Regards,
Ashwani
Daniel Aschauer
RE: selecting image form "Doc. and media" on custom portlet.!!!
9 aprile 2013 6.11
Risposta

Daniel Aschauer

Punteggio: Junior Member

Messaggi: 39

Data di Iscrizione: 22 ottobre 2012

Messaggi recenti

I need to do the same. Did you finally implement a solution for this requirement?
Thanks, Daniel
Aravinth Kumar
RE: selecting image form "Doc. and media" on custom portlet.!!!
23 aprile 2015 3.38
Risposta

Aravinth Kumar

Punteggio: Junior Member

Messaggi: 53

Data di Iscrizione: 25 giugno 2013

Messaggi recenti

Hi,
Can someone guide me to achieve this functionality.

Thanks in advance.