value:random

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

value:random

keith1y
Hi Lukas,

when I saw value:random I thought that this was just what I had been
wanting.

I immediately gave it a try, expecting it to be "a random child of the
page in which the link is placed". Well it worked fine until I embedded
that page into another page, and then I discovered that it is "random
child of the current structure". Not what I expected at all.

So I investigated these value links, only to find that these links do
not appear to know their document, thus making my original idea
impossible to implement with value links.

To be honest I have hit this problem many times since I started using
pier. I never have any use for "children of the current structure", and
there are many "current structure" based features in pier. I always want
children of a specific structure. Then I can craft a menu, and embed it
somewhere else, or similar.

So I implemented a subclass of value links, implementing "page:" links,
and it works great.

Then I had a thought: the most powerful, and oft forgotten feature of
Ward Cunningham's original wiki, was the ability to click on the title
of a page, and get all of the referring pages.

So how does one get "all of the links that link to this page".

btw: the code in the comment to PRIncomingReferences is not a valid
example as far as I can see.

cheers

Keith


_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

keith1y

> So how does one get "all of the links that link to this page".
>
>  
I am a bit tired, senders of incomeingReferences yielded what I was
looking for.

(self owner root incomingReferences to: self owner) collect: [ :ea | ea
owner ].

So now I have:

+page:references+
+page:randomchild+
+page:children+
+page:siblings+

is this of interest?

Keith


_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

Lukas Renggli
In reply to this post by keith1y
> Then I had a thought: the most powerful, and oft forgotten feature of
> Ward Cunningham's original wiki, was the ability to click on the title
> of a page, and get all of the referring pages.
>
> [...]
>
> is this of interest?

There has always been the PRReferencesWidget that shows a list of all
incoming references.

There is also the Pier-Randomizer Package that displays a random
child, prominently used on the frontpage of seaside.st.

Only recently the whole story of the value-links started as a
lightweight and secure way to script your sites.

Thanks for pointing out this missing functionality in the context of
value-links. I added it as +value:incoming+ and +value:outgoing+ with
the latest commit.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch

_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

Damien Cassou-3
On Thu, Mar 26, 2009 at 9:08 AM, Lukas Renggli <[hidden email]> wrote:
> There is also the Pier-Randomizer Package that displays a random
> child, prominently used on the frontpage of seaside.st.

I also use it on my website for my photo: http://damiencassou.seasidehosting.st/

--
Damien Cassou
http://damiencassou.seasidehosting.st

_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

stéphane ducasse-2
what?
I did not see pharo on your great web site :)))

Stef

On Mar 26, 2009, at 9:21 AM, Damien Cassou wrote:

> On Thu, Mar 26, 2009 at 9:08 AM, Lukas Renggli <[hidden email]>  
> wrote:
>> There is also the Pier-Randomizer Package that displays a random
>> child, prominently used on the frontpage of seaside.st.
>
> I also use it on my website for my photo: http://damiencassou.seasidehosting.st/
>
> --
> Damien Cassou
> http://damiencassou.seasidehosting.st
>
> _______________________________________________
> SmallWiki, Magritte, Pier and Related Tools ...
> https://www.iam.unibe.ch/mailman/listinfo/smallwiki


_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

Damien Cassou-3
On Thu, Mar 26, 2009 at 11:33 AM, stéphane ducasse <[hidden email]> wrote:
> what?
> I did not see pharo on your great web site :)))

I explained before that Pharo is not compatible with SeasideHosting.
There is problem and I don't know which one. Adrian was also not able
to fix it.

--
Damien Cassou
http://damiencassou.seasidehosting.st


_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

stéphane ducasse-2
I was talking about a nice link to our wonderful web site. :)


On Mar 26, 2009, at 2:07 PM, Damien Cassou wrote:

> On Thu, Mar 26, 2009 at 11:33 AM, stéphane ducasse <[hidden email]
> > wrote:
>> what?
>> I did not see pharo on your great web site :)))
>
> I explained before that Pharo is not compatible with SeasideHosting.
> There is problem and I don't know which one. Adrian was also not able
> to fix it.
>
> --
> Damien Cassou
> http://damiencassou.seasidehosting.st
>
>
> _______________________________________________
> SmallWiki, Magritte, Pier and Related Tools ...
> https://www.iam.unibe.ch/mailman/listinfo/smallwiki
>



_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

Damien Cassou-3
On Thu, Mar 26, 2009 at 2:16 PM, stéphane ducasse <[hidden email]> wrote:
> I was talking about a nice link to our wonderful web site. :)

As soon as the website runs on Pharo you will have a link :-). Not before ;-)

--
Damien Cassou
http://damiencassou.seasidehosting.st


_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki
Reply | Threaded
Open this post in threaded view
|

Re: value:random

Mariano Martinez Peck
In reply to this post by Lukas Renggli


On Thu, Mar 26, 2009 at 6:08 AM, Lukas Renggli <[hidden email]> wrote:
> Then I had a thought: the most powerful, and oft forgotten feature of
> Ward Cunningham's original wiki, was the ability to click on the title
> of a page, and get all of the referring pages.
>
> [...]
>
> is this of interest?

There has always been the PRReferencesWidget that shows a list of all
incoming references.

There is also the Pier-Randomizer Package that displays a random
child, prominently used on the frontpage of seaside.st.

Only recently the whole story of the value-links started as a
lightweight and secure way to script your sites.

Thanks for pointing out this missing functionality in the context of
value-links. I added it as +value:incoming+ and +value:outgoing+ with
the latest commit.

I think I need something like this. I am building a tourism webpage and as you may imagine, I have lots of pictures. I want to have several random slide shows. For example: The user first wants to select a zone (suppose a continent). There I want to put a slideshow of photos from that zone. Than, he selects a zone and the provinces (suppose countries) are displayed. I want to put a slideshow  with photos of that province. And finally he can select a particular city. There I want a slideshow of that city.

So, for each photo I must tell it the zone, province and city. But, which can be the best approach to do this ?

Thanks in advance for the help.

Mariano



 

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch

_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki



_______________________________________________
SmallWiki, Magritte, Pier and Related Tools ...
https://www.iam.unibe.ch/mailman/listinfo/smallwiki