Microsoft Content Management Server - ImagePlaceholder and Image deleted from resource gallery

This is Interesting: Free IT Magazines  
Home > Archive > Microsoft Content Management Server > March 2005 > ImagePlaceholder and Image deleted from resource gallery





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author ImagePlaceholder and Image deleted from resource gallery
Stefano

2005-03-24, 8:47 pm

Hi all,

I've a Template with an ImagePlaceholder.

When I create a Posting based on that template, and I select an image from
resource gallery.... if then I delete the resource from the gallery (using
resource manager or site manager), the posting still correctly shows the
image.

So, the question is:
how is this possible?

I've another Template with a custom placeholder (based on xmlplaceholder),
that stores in the xml the "Cms Guid" of resources (selected from the
resource gallery)... and so, it shows the resources in presentation mode
(like an images gallery).

In this case, if I delete the resources using resource manager (or site
manager), obviously I cannot render them (because I refer to the resource
using its Guid).

How can I implement a behavior like the ImagePlaceholder one (but also
AttachmentPlaceholder, HtmlPlaceholder when text links to resources...)?

Thank you so much.

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it



Stefan [MSFT]

2005-03-24, 8:47 pm

Hi Stefano,

the item is still in the database - only marked as deleted.
As long as you try to browse the posting as an MCMS administrator you will
see the item. But as a subscriber you will not see it.

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:ekJD9jHMFHA.1172@TK2MSFTNGP12.phx.gbl...
> Hi all,
>
> I've a Template with an ImagePlaceholder.
>
> When I create a Posting based on that template, and I select an image from
> resource gallery.... if then I delete the resource from the gallery (using
> resource manager or site manager), the posting still correctly shows the
> image.
>
> So, the question is:
> how is this possible?
>
> I've another Template with a custom placeholder (based on xmlplaceholder),
> that stores in the xml the "Cms Guid" of resources (selected from the
> resource gallery)... and so, it shows the resources in presentation mode
> (like an images gallery).
>
> In this case, if I delete the resources using resource manager (or site
> manager), obviously I cannot render them (because I refer to the resource
> using its Guid).
>
> How can I implement a behavior like the ImagePlaceholder one (but also
> AttachmentPlaceholder, HtmlPlaceholder when text links to resources...)?
>
> Thank you so much.
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
>



Stefano

2005-03-24, 8:47 pm

Hi Stefan,

where can I found documentation about this?
I need to deepen this argument.

Thank you so much.

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:O0hjqzHMFHA.576@TK2MSFTNGP15.phx.gbl...
> Hi Stefano,
>
> the item is still in the database - only marked as deleted.
> As long as you try to browse the posting as an MCMS administrator you will
> see the item. But as a subscriber you will not see it.
>
> Cheers,
> Stefan.
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:ekJD9jHMFHA.1172@TK2MSFTNGP12.phx.gbl...
from[vbcol=seagreen]
(using[vbcol=seagreen]
xmlplaceholder),[vbcol=seagreen]
resource[vbcol=seagreen]
>
>



Stefan [MSFT]

2005-03-24, 8:47 pm

Hi Stefano,

see the following articles:

http://blogs.msdn.com/stefan_gossne.../23/378718.aspx

http://blogs.msdn.com/stefan_gossne.../07/175298.aspx

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8


Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:un4Dv4HMFHA.3708@TK2MSFTNGP14.phx.gbl...
> Hi Stefan,
>
> where can I found documentation about this?
> I need to deepen this argument.
>
> Thank you so much.
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:O0hjqzHMFHA.576@TK2MSFTNGP15.phx.gbl...
will[vbcol=seagreen]
rights[vbcol=seagreen]
> from
> (using
the[vbcol=seagreen]
> xmlplaceholder),
mode[vbcol=seagreen]
site[vbcol=seagreen]
> resource
resources...)?[vbcol=seagreen]
>
>



Stefano

2005-03-24, 8:47 pm

Hi Stefan,

thanks a lot for the links.

If there is no way to understand if the resource is used in postings...
....so, the moral for a resource manager is: "Never delete a non-well-known
resource from the resource gallery. It could be used...! "

Is it right?

Thanks again.

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:exdaE%23HMFHA.2648@TK2MSFTNGP14.phx.gbl...
> Hi Stefano,
>
> see the following articles:
>
> http://blogs.msdn.com/stefan_gossne.../23/378718.aspx
>
> http://blogs.msdn.com/stefan_gossne.../07/175298.aspx
>
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
>
>
> Cheers,
> Stefan.
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:un4Dv4HMFHA.3708@TK2MSFTNGP14.phx.gbl...
> will
> rights
image[vbcol=seagreen]
> the
the[vbcol=seagreen]
> mode
> site
also[vbcol=seagreen]
> resources...)?
>
>



Stefano

2005-03-24, 8:47 pm

Stefan,

another question... resources are linked to "resource gallery", so it is
possible to evaluate the rights and authorization.

What about "local resources"? I mean... the resources directly uploaded to
the server, when needed (so, not included in resource galleries).

Are "local resources" directly linked to the posting? How are they stored
internally?

And.. last... how can I create my own custom placeholder that allows the use
of "local resources"?

Thank you so much

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:exdaE%23HMFHA.2648@TK2MSFTNGP14.phx.gbl...
> Hi Stefano,
>
> see the following articles:
>
> http://blogs.msdn.com/stefan_gossne.../23/378718.aspx
>
> http://blogs.msdn.com/stefan_gossne.../07/175298.aspx
>
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
>
>
> Cheers,
> Stefan.
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:un4Dv4HMFHA.3708@TK2MSFTNGP14.phx.gbl...
> will
> rights
image[vbcol=seagreen]
> the
the[vbcol=seagreen]
> mode
> site
also[vbcol=seagreen]
> resources...)?
>
>



Stefan [MSFT]

2005-03-24, 8:47 pm

Hi Stefano,

not completly. Here is a tool to check if the resource is used:
http://www.gotdotnet.com/Community/...f2-bf283edb9159

Cheers,
Stefan

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:OGi2BsIMFHA.1096@tk2msftngp13.phx.gbl...
> Hi Stefan,
>
> thanks a lot for the links.
>
> If there is no way to understand if the resource is used in postings...
> ...so, the moral for a resource manager is: "Never delete a non-well-known
> resource from the resource gallery. It could be used...! "
>
> Is it right?
>
> Thanks again.
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:exdaE%23HMFHA.2648@TK2MSFTNGP14.phx.gbl...
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
rights[vbcol=seagreen]
messaggio[vbcol=seagreen]
you[vbcol=seagreen]
> image
gallery[vbcol=seagreen]
shows[vbcol=seagreen]
> the
presentation[vbcol=seagreen]
> also
>
>



Stefan [MSFT]

2005-03-24, 8:47 pm

Hi Stefano,

all resources are stored similar. The difference is that the resource
gallery items have a reference to the resource gallery while the local
attachments do not.

Here is the information about how to use the dialogs in your placeholder
controls:
http://blogs.msdn.com/stefan_gossne...2/07/41861.aspx

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:eMPXNwIMFHA.2468@tk2msftngp13.phx.gbl...
> Stefan,
>
> another question... resources are linked to "resource gallery", so it is
> possible to evaluate the rights and authorization.
>
> What about "local resources"? I mean... the resources directly uploaded to
> the server, when needed (so, not included in resource galleries).
>
> Are "local resources" directly linked to the posting? How are they stored
> internally?
>
> And.. last... how can I create my own custom placeholder that allows the

use
> of "local resources"?
>
> Thank you so much
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:exdaE%23HMFHA.2648@TK2MSFTNGP14.phx.gbl...
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
rights[vbcol=seagreen]
messaggio[vbcol=seagreen]
you[vbcol=seagreen]
> image
gallery[vbcol=seagreen]
shows[vbcol=seagreen]
> the
presentation[vbcol=seagreen]
> also
>
>



Stefano

2005-03-25, 2:47 am

Hi Stefan,

it could be a solution. Maybe you're using "AuthenticateAsCurrentUser"
method to authenticate against MCMS... right?

If so, the client that run this tool has to be logged as a MCMS account
(with privileges to enumerate resources). Right?

Can you provide me the source code of that tool? I could try to customize it
to better satisfy my needs.

Thanks!

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:%23qH3n4IMFHA.2988@TK2MSFTNGP14.phx.gbl...
> Hi Stefano,
>
> not completly. Here is a tool to check if the resource is used:
>

http://www.gotdotnet.com/Community/...f2-bf283edb9159
>
> Cheers,
> Stefan
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:OGi2BsIMFHA.1096@tk2msftngp13.phx.gbl...
non-well-known[vbcol=seagreen]
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
> rights
> messaggio
> you
no[vbcol=seagreen]
> gallery
> shows
from[vbcol=seagreen]
> presentation
(or[vbcol=seagreen]
(but[vbcol=seagreen]
>
>



Stefano

2005-03-25, 7:47 am

Stefan,

how does this tool determine when a resource is used?

Can you specify me the cases, please? (for example, when the resource is
linked in htmlplaceholder, xmlplaceholder, etc. etc.)

Thank you so much!

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:%23qH3n4IMFHA.2988@TK2MSFTNGP14.phx.gbl...
> Hi Stefano,
>
> not completly. Here is a tool to check if the resource is used:
>

http://www.gotdotnet.com/Community/...f2-bf283edb9159
>
> Cheers,
> Stefan
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:OGi2BsIMFHA.1096@tk2msftngp13.phx.gbl...
non-well-known[vbcol=seagreen]
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
> rights
> messaggio
> you
no[vbcol=seagreen]
> gallery
> shows
from[vbcol=seagreen]
> presentation
(or[vbcol=seagreen]
(but[vbcol=seagreen]
>
>



Stefano

2005-03-25, 7:47 am

Great article.

So, the only "link" between posting and a "local resource" is made by the
"/NR/rdonlyres/3EA96BB5-2148-422B-95D3-449F0260D807/5376/myimage.jpg" (how
is it parsed?)
stored into placeholder value.
Is it right?

I've a custom placeholder based on XmlPlaceholder... so, really there is no
way to workaround the problem... oh no!

If I understand... the popup web form retrieves the instance of the posting
object (using the given GUID), and the instance of the placeholder (using
the given name).
So, if my placeholder is type of XmlPlaceholder... an exception will be
thrown, and web form doesn't know how to return the value to the opener....
Is it correct?

Thank you!

Bye
--
Stefano Giannone
MCP .NET
http://www.giasoft.it


"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:uwx8e5IMFHA.3340@TK2MSFTNGP14.phx.gbl...
> Hi Stefano,
>
> all resources are stored similar. The difference is that the resource
> gallery items have a reference to the resource gallery while the local
> attachments do not.
>
> Here is the information about how to use the dialogs in your placeholder
> controls:
> http://blogs.msdn.com/stefan_gossne...2/07/41861.aspx
>
> Cheers,
> Stefan.
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
> Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
> ----------------------
>
>
> "Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
> news:eMPXNwIMFHA.2468@tk2msftngp13.phx.gbl...
to[vbcol=seagreen]
stored[vbcol=seagreen]
> use
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
> rights
> messaggio
> you
no[vbcol=seagreen]
> gallery
> shows
from[vbcol=seagreen]
> presentation
(or[vbcol=seagreen]
(but[vbcol=seagreen]
>
>



Stefan [MSFT]

2005-03-25, 7:47 am

Hi Stefano,

it uses an internal API call to get a resource dependency report.

Cheers,
Stefan

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:e6aFtqRMFHA.3328@TK2MSFTNGP14.phx.gbl...
> Stefan,
>
> how does this tool determine when a resource is used?
>
> Can you specify me the cases, please? (for example, when the resource is
> linked in htmlplaceholder, xmlplaceholder, etc. etc.)
>
> Thank you so much!
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:%23qH3n4IMFHA.2988@TK2MSFTNGP14.phx.gbl...
>

http://www.gotdotnet.com/Community/...f2-bf283edb9159
rights[vbcol=seagreen]
postings...[vbcol=seagreen]
> non-well-known
messaggio[vbcol=seagreen]
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
administrator[vbcol=seagreen]
> no
an[vbcol=seagreen]
> from
> (or
the[vbcol=seagreen]
> (but
>
>



Stefan [MSFT]

2005-03-25, 7:47 am

Hi Stefano,

he needs to be logged in as a MCMS adminsitrator as this is the only account
that can see all items.
The tool has been written with undocumented MS internal calls so I cannot
share the source code.

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:eqyqPURMFHA.568@TK2MSFTNGP09.phx.gbl...
> Hi Stefan,
>
> it could be a solution. Maybe you're using "AuthenticateAsCurrentUser"
> method to authenticate against MCMS... right?
>
> If so, the client that run this tool has to be logged as a MCMS account
> (with privileges to enumerate resources). Right?
>
> Can you provide me the source code of that tool? I could try to customize

it
> to better satisfy my needs.
>
> Thanks!
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:%23qH3n4IMFHA.2988@TK2MSFTNGP14.phx.gbl...
>

http://www.gotdotnet.com/Community/...f2-bf283edb9159
rights[vbcol=seagreen]
postings...[vbcol=seagreen]
> non-well-known
messaggio[vbcol=seagreen]
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
administrator[vbcol=seagreen]
> no
an[vbcol=seagreen]
> from
> (or
the[vbcol=seagreen]
> (but
>
>



Stefan [MSFT]

2005-03-25, 7:47 am

Just to add: all managed refernces will be found.
So if you disable the link management on an XmlPlaceholder it will not
befound.

Cheers,
Stefan.

--
This posting is provided "AS IS" with no warranties, and confers no rights
Book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Stefano" <stefano_REMOVETHIS@giasoft.it> wrote in message
news:e6aFtqRMFHA.3328@TK2MSFTNGP14.phx.gbl...
> Stefan,
>
> how does this tool determine when a resource is used?
>
> Can you specify me the cases, please? (for example, when the resource is
> linked in htmlplaceholder, xmlplaceholder, etc. etc.)
>
> Thank you so much!
>
> Bye
> --
> Stefano Giannone
> MCP .NET
> http://www.giasoft.it
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
> news:%23qH3n4IMFHA.2988@TK2MSFTNGP14.phx.gbl...
>

http://www.gotdotnet.com/Community/...f2-bf283edb9159
rights[vbcol=seagreen]
postings...[vbcol=seagreen]
> non-well-known
messaggio[vbcol=seagreen]
>

http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm#53EB2F9B-E87E-442C-8D69-B2B0B783EBB8
administrator[vbcol=seagreen]
> no
an[vbcol=seagreen]
> from
> (or
the[vbcol=seagreen]
> (but
>
>



Stefano

2005-03-29, 7:49 am

Thanks.

Bye!


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com