|
|
Rank: Enthusiast
Joined: 10/10/2006 Posts: 16
|
Where did it go? I found CPalm's MultiplePagePickerViaSource but not the 'old' one with the popup tree...
|
|
 Rank: Addict
Joined: 7/29/2006 Posts: 507 Location: Melbourne, Australia
|
Hey Mark,
I think you're thinking of the Content Picker, which is part of the Umbraco base install. I'm pretty sure there isn't a content-tree version of a multi-picker.. if there is, I'll help u find it cos that'd be saweeeet. :)
greg
Wishes he could work with Umbraco all the time.
|
|
Rank: Enthusiast
Joined: 10/10/2006 Posts: 16
|
Hi Greg,
Thx for the feedback... I was revering to this one: Bjornbakk.EditorControls.MultipleContentPicker.dll
I just picked it up from another websites bin directory... It's the same as CPalms content picker but without the extra list. This one is just one list with an add button which pops up a popup with a tree...
Regards,
Marc
|
|
 Rank: Addict
Joined: 7/29/2006 Posts: 507 Location: Melbourne, Australia
|
Hey Sweet.. i've never seen that one before, but i like it!
I'd replace alot of the multi-content pickers on my site if it'd display the Node Name instead of ID in the selected list... Daniel, any chance of fixing this?
Also, it'd be nice if you could specify a starting node for the selector, although now maybe i'm getting a little greedy. lol.
Wishes he could work with Umbraco all the time.
|
|
 Rank: Aficionado
Joined: 7/19/2006 Posts: 190 Location: Norway
|
I'll dig trough my stuff and see if I find the source for this... ;)
|
|
Rank: Enthusiast
Joined: 10/10/2006 Posts: 16
|
That would be of great help Daniel! Thx!! :!:
|
|
Rank: Enthusiast
Joined: 10/10/2006 Posts: 16
|
Uhm... Daniel? :cry:
|
|
 Rank: Aficionado
Joined: 7/19/2006 Posts: 190 Location: Norway
|
Marc wrote: Uhm... Daniel? :cry:
sorry... :blush: here it is.. full source; http://daniel.xeed.no/media/251/multiplecontentpicker.rar
|
|
 Rank: Addict
Joined: 7/29/2006 Posts: 507 Location: Melbourne, Australia
|
Awesome thanks Daniel
Although, I've just installed it on my blog site (under heavy development) running V3 RC1, and it works a treat... the ID's actually change to node names after the form is saved - i didnt realise this before. This makes your content picker the best one out there i reckon... another hidden gem. :)
GB
Wishes he could work with Umbraco all the time.
|
|
Rank: Enthusiast
Joined: 10/10/2006 Posts: 16
|
|
|
Rank: Newbie
Joined: 8/20/2007 Posts: 7
|
Hi there, Daniel's content picker is awsome! Tried to find traces of a documentaion or examples, with no luck :( I've met a problem with outputing selected nodes.. It's fine when there's only one node which is obvious, but probles are when I want add some more.. Tried Christian's picker as well which is working fine, however I need selecting nodes from the whole tree, not specified node... Im using XSLT as following: Code: <xsl:variable name="christiansPicker" select="$currentPage/data [@alias = 'christiansPicker']" />
<xsl:value-of select="$christiansPicker"/> <xsl:if test="$christiansPicker/value !=''"> <xsl:for-each select="$christiansPicker/value"> <xsl:variable name="item" select="umbraco.library:GetXmlNodeById(.)" /> <xsl:value-of select="$item/@nodeName"/> </xsl:for-each> </xsl:if> <hr />
<xsl:variable name="$danielsPicker" select="umbraco.library:Split($danielsPicker, ',')" />
<xsl:value-of select="$danielsPicker"/>
<xsl:if test="$danielsPicker/value !=''"> <xsl:for-each select="$danielsPicker/value"> <xsl:variable name="page" select="umbraco.library:GetXmlNodeById(.)" /> <xsl:value-of select="$danielsPicker/@nodeName"/> </xsl:for-each> </xsl:if> Thanx very much for any help. Przemek
|
|
 Rank: Aficionado
Joined: 7/19/2006 Posts: 190 Location: Norway
|
try: Code:
<xsl:variable name="christiansPicker" select="$currentPage/data [@alias = 'christiansPicker']" />
<xsl:value-of select="$christiansPicker"/>
<xsl:if test="$christiansPicker/value !=''"> <xsl:for-each select="$christiansPicker/value"> <xsl:variable name="item" select="umbraco.library:GetXmlNodeById(.)" /> <xsl:value-of select="$item/@nodeName"/> </xsl:for-each> </xsl:if>
<hr />
<xsl:variable name="$danielsPicker" select="umbraco.library:Split($danielsPicker, ',')" />
<!-- output raw xml for the split method in a textarea --> <textarea style="height: 400px width: 400px;"> <xsl:value-of select="$danielsPicker" /> </textarea>
<xsl:value-of select="$danielsPicker"/>
<xsl:if test="$danielsPicker/value !=''"> <xsl:for-each select="$danielsPicker/value"> <xsl:variable name="page" select="umbraco.library:GetXmlNodeById(.)" /> <xsl:value-of select="$danielsPicker/@nodeName"/> </xsl:for-each> </xsl:if>
then you would be able to see the content - and what to do for-each on :thumbup:
|
|
Rank: Newbie
Joined: 8/20/2007 Posts: 7
|
Hi Daniel,
Thanx for prompt reponse, didn't suppose it's gonna come so quick.
I tried to work out the code, however I think it's missing few lines?
If you can check it out and grab the rest would be great!
Thanx Przemek
|
|
Rank: Newbie
Joined: 8/20/2007 Posts: 7
|
Hi there After hours, days, months... :hmm: of trying to work it out, I had to got back here and ask for help. That problem seems to be strange for me. Please have a look on the code below. Two diffrent Multi Content Pickers (Christian's and Daniel's), the same output, the same executive code and one of them is not working once more than one node is been added... CHRISTIAN'S CONTENT PICKER Which is working perfect, but I need to be able to select nodes from diffrent locations. Code:
<xsl:variable name="christiansPicker" select="$currentPage/data [@alias = 'newsItems']" />
Original output: <xsl:value-of select="$danielsPickerSplit"/><br /><br /> <!-- 1101,1226 -->
<xsl:variable name="christiansPickerSplit" select="umbraco.library:Split($christiansPicker, ',')" />
Splitted output: <xsl:value-of select="$christiansPickerSplit"/><br /><br /> <!-- 11011226 -->
<!-- Split() is necessary to remove comma and display results in the loop - something to do with /value -->
<xsl:for-each select="$christiansPickerSplit/value"> <xsl:variable name="page" select="umbraco.library:GetXmlNodeById(.)" />
<xsl:value-of select="$page/@id"/> - <xsl:value-of select="$page/@nodeName"/> <br />
</xsl:for-each>
DANIEL'S CONTENT PICKER That one isn't working for me. Code: <xsl:variable name="danielsPicker" select="$currentPage/data [@alias = 'newsItems']" />
Original output: <xsl:value-of select="$danielsPickerSplit"/><br /><br /> <!-- 11011226 -->
<xsl:variable name="danielsPickerSplit" select="umbraco.library:Split($danielsPicker, ' ')" />
Splitted output: <xsl:value-of select="$danielsPickerSplit"/><br /><br /> <!-- 11011226 -->
<!-- Output is the same, however Split() is necessary to display results in the loop - something to do with /value -->
<xsl:for-each select="$danielsPickerSplit/value">
<xsl:variable name="page" select="umbraco.library:GetXmlNodeById(.)" /> <xsl:value-of select="$page/@id"/> - <xsl:value-of select="$page/@nodeName"/> <br />
</xsl:for-each>
I'm sorry if I'm stupid but really couldn't work it out.. Many Thanx Przemek
|
|
 Rank: Aficionado
Joined: 7/19/2006 Posts: 190 Location: Norway
|
try somthing like this to se what the content picker gives you: Code:
<textarea style="height: 200px; width: 600px;">
<xsl:copy-of select="$danielsPicker" />
</textarea>
copy-of yould give you the raw content of the variable. I don't remember - but i might have wrapped the result in some xml so you don't have to use the split() function - but rather just do somthing like: Code:
<textarea style="height: 200px; width: 600px;">
<xsl:for-each select="$danielsPicker//item"> <xsl:value-of select="."/> </xsl:for-each>
</textarea>
hope this helps...
|
|
|
Guest |