help to use routing with seaside

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

help to use routing with seaside

feav feav
I have to develop a web application with seaside and i don't know how to build routing system like
/app/user
/app/user/message
and others
Cordialement, Armel EMBOLO
Ingénieur de travaux en Informatique de Gestion / Analyste programmeur
Elève Ingénieur de Conception  en Génie Logiciel
Université de Maroua, Ecole Nationale Supérieure Polytechnique de Maroua (ex ISS)
Facebook : Armel Embolo
Linkedin : armel embolo
Tel : (+237) 650231339/698594740

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

Stephan Eggermont-3
feav feav <[hidden email]> wrote:
> I have to develop a web application with seaside and i don't know how to
> build routing system like
> /app/user
> /app/user/message
> and others

Is there a specific need you have for this? In Seaside this is not needed
by default.

Stephan



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

feav feav

we can not realize a whole web application with a single url. that's why I want to set up a road-controller-Model system

Cordialement, Armel EMBOLO
Ingénieur de travaux en Informatique de Gestion / Analyste programmeur
Elève Ingénieur de Conception  en Génie Logiciel
Université de Maroua, Ecole Nationale Supérieure Polytechnique de Maroua (ex ISS)
Facebook : Armel Embolo
Linkedin : armel embolo
Tel : (+237) 650231339/698594740

2018-05-16 16:24 GMT+01:00 Stephan Eggermont <[hidden email]>:
feav feav <[hidden email]> wrote:
> I have to develop a web application with seaside and i don't know how to
> build routing system like
> /app/user
> /app/user/message
> and others

Is there a specific need you have for this? In Seaside this is not needed
by default.

Stephan



_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

CyrilFerlicot
Le 16/05/2018 à 20:57, feav feav a écrit :
>
> we can not realize a whole web application with a single url. that's why
> I want to set up a road-controller-Model system
>

Hi,

In seaside by default you do not need to care for URLs.

Navigation in Seaside is not done as in classic web frameworks. By
default if you add an anchor to your page you can associate it with a
callback.

For example:

renderContentOn: html
  self counter ifNil: [ self counter: 0 ].

  html text: self counter.

  html anchor
    callback: [ self counter: self counter + 1 ];
    with: 'Increment'

In this rendering method you create a new anchor that will increment a
counter when clicked. The page will refresh and be re-drawn with the new
model behind (the counter incremented).

The URL of the anchor will be generated automatically by seaside. It
will be something like:
http://localhost:8080/MyApplication?_s=sr8lZ498rCXXt1_u&_k=FSAMnCtwxdLaoep6

Of course sometimes you want to be able to define the URL yourself. I
think that was the purpose of Setphan's question. What is your goal?
Knowing that we can know if you need to define your URLs by yourself or
if the default behaviour of Seaside is enough.


> *Cordialement, Armel EMBOLO*
> <https://accounts.google.com/SignOutOptions?hl=fr&continue=https://mail.google.com/mail&service=mail>
> *_Ingénieur de travaux en Informatique de Gestion / Analyste programmeur_*
> *Elève Ingénieur de Conception  en Génie Logiciel*
> *Université de Maroua, _Ecole Nationale Supérieure Polytechnique de
> Maroua (ex ISS)_
> *
> *Facebook : Armel Embolo <https://www.facebook.com/armel.embolo>
> *
> *Linkedin : armel embolo
> <https://www.linkedin.com/profile/view?id=AAMAABYswuMBn33mi4o_x8R49OxfxiIQVAryzw4&trk=hp-identity-name>
> *
> *Tel : (+237) 650231339/698594740*
>
--
Cyril Ferlicot
https://ferlicot.fr
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

feav feav
define my own URLs by myself

Cordialement, Armel EMBOLO
Ingénieur de travaux en Informatique de Gestion / Analyste programmeur
Elève Ingénieur de Conception  en Génie Logiciel
Université de Maroua, Ecole Nationale Supérieure Polytechnique de Maroua (ex ISS)
Facebook : Armel Embolo
Linkedin : armel embolo
Tel : (+237) 650231339/698594740

2018-05-16 20:08 GMT+01:00 Cyril Ferlicot D. <[hidden email]>:
Le 16/05/2018 à 20:57, feav feav a écrit :
>
> we can not realize a whole web application with a single url. that's why
> I want to set up a road-controller-Model system
>

Hi,

In seaside by default you do not need to care for URLs.

Navigation in Seaside is not done as in classic web frameworks. By
default if you add an anchor to your page you can associate it with a
callback.

For example:

renderContentOn: html
  self counter ifNil: [ self counter: 0 ].

  html text: self counter.

  html anchor
    callback: [ self counter: self counter + 1 ];
    with: 'Increment'

In this rendering method you create a new anchor that will increment a
counter when clicked. The page will refresh and be re-drawn with the new
model behind (the counter incremented).

The URL of the anchor will be generated automatically by seaside. It
will be something like:
http://localhost:8080/MyApplication?_s=sr8lZ498rCXXt1_u&_k=FSAMnCtwxdLaoep6

Of course sometimes you want to be able to define the URL yourself. I
think that was the purpose of Setphan's question. What is your goal?
Knowing that we can know if you need to define your URLs by yourself or
if the default behaviour of Seaside is enough.


> *Cordialement, Armel EMBOLO*
> <https://accounts.google.com/SignOutOptions?hl=fr&continue=https://mail.google.com/mail&service=mail>
> *_Ingénieur de travaux en Informatique de Gestion / Analyste programmeur_*
> *Elève Ingénieur de Conception  en Génie Logiciel*
> *Université de Maroua, _Ecole Nationale Supérieure Polytechnique de
> Maroua (ex ISS)_
> *
> *Facebook : Armel Embolo <https://www.facebook.com/armel.embolo>
> *
> *Linkedin : armel embolo
> <https://www.linkedin.com/profile/view?id=AAMAABYswuMBn33mi4o_x8R49OxfxiIQVAryzw4&trk=hp-identity-name>
> *
> *Tel : (+237) 650231339/698594740*
>
--
Cyril Ferlicot
https://ferlicot.fr
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

feav feav

And i am not able to load local file like stylesheet, image or javascript on m'y Web application.


Le Mer 16 Mai 2018 21:50, feav feav <[hidden email]> a écrit :
define my own URLs by myself

Cordialement, Armel EMBOLO
Ingénieur de travaux en Informatique de Gestion / Analyste programmeur
Elève Ingénieur de Conception  en Génie Logiciel
Université de Maroua, Ecole Nationale Supérieure Polytechnique de Maroua (ex ISS)
Facebook : Armel Embolo
Linkedin : armel embolo
Tel : (+237) 650231339/698594740

2018-05-16 20:08 GMT+01:00 Cyril Ferlicot D. <[hidden email]>:
Le 16/05/2018 à 20:57, feav feav a écrit :
>
> we can not realize a whole web application with a single url. that's why
> I want to set up a road-controller-Model system
>

Hi,

In seaside by default you do not need to care for URLs.

Navigation in Seaside is not done as in classic web frameworks. By
default if you add an anchor to your page you can associate it with a
callback.

For example:

renderContentOn: html
  self counter ifNil: [ self counter: 0 ].

  html text: self counter.

  html anchor
    callback: [ self counter: self counter + 1 ];
    with: 'Increment'

In this rendering method you create a new anchor that will increment a
counter when clicked. The page will refresh and be re-drawn with the new
model behind (the counter incremented).

The URL of the anchor will be generated automatically by seaside. It
will be something like:
http://localhost:8080/MyApplication?_s=sr8lZ498rCXXt1_u&_k=FSAMnCtwxdLaoep6

Of course sometimes you want to be able to define the URL yourself. I
think that was the purpose of Setphan's question. What is your goal?
Knowing that we can know if you need to define your URLs by yourself or
if the default behaviour of Seaside is enough.


> *Cordialement, Armel EMBOLO*
> <https://accounts.google.com/SignOutOptions?hl=fr&continue=https://mail.google.com/mail&service=mail>
> *_Ingénieur de travaux en Informatique de Gestion / Analyste programmeur_*
> *Elève Ingénieur de Conception  en Génie Logiciel*
> *Université de Maroua, _Ecole Nationale Supérieure Polytechnique de
> Maroua (ex ISS)_
> *
> *Facebook : Armel Embolo <https://www.facebook.com/armel.embolo>
> *
> *Linkedin : armel embolo
> <https://www.linkedin.com/profile/view?id=AAMAABYswuMBn33mi4o_x8R49OxfxiIQVAryzw4&trk=hp-identity-name>
> *
> *Tel : (+237) 650231339/698594740*
>
--
Cyril Ferlicot
https://ferlicot.fr
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

Tim Mackinnon
Hi - I think you need to take a look at the tutorial on file handling; http://book.seaside.st/book/in-action/serving-files/filelibraries

Normally its served from within the image, but you can also configure it to use external files if you want. But for CSS, there is neat DSL library called Renoir.

Tim

On 17 May 2018, at 02:27, feav feav <[hidden email]> wrote:

And i am not able to load local file like stylesheet, image or javascript on m'y Web application.


Le Mer 16 Mai 2018 21:50, feav feav <[hidden email]> a écrit :
define my own URLs by myself

Cordialement, Armel EMBOLO
Ingénieur de travaux en Informatique de Gestion / Analyste programmeur
Elève Ingénieur de Conception  en Génie Logiciel
Université de Maroua, Ecole Nationale Supérieure Polytechnique de Maroua (ex ISS)
Facebook : Armel Embolo
Linkedin : armel embolo
Tel : (+237) 650231339/698594740

2018-05-16 20:08 GMT+01:00 Cyril Ferlicot D. <[hidden email]>:
Le 16/05/2018 à 20:57, feav feav a écrit :
>
> we can not realize a whole web application with a single url. that's why
> I want to set up a road-controller-Model system
>

Hi,

In seaside by default you do not need to care for URLs.

Navigation in Seaside is not done as in classic web frameworks. By
default if you add an anchor to your page you can associate it with a
callback.

For example:

renderContentOn: html
  self counter ifNil: [ self counter: 0 ].

  html text: self counter.

  html anchor
    callback: [ self counter: self counter + 1 ];
    with: 'Increment'

In this rendering method you create a new anchor that will increment a
counter when clicked. The page will refresh and be re-drawn with the new
model behind (the counter incremented).

The URL of the anchor will be generated automatically by seaside. It
will be something like:
http://localhost:8080/MyApplication?_s=sr8lZ498rCXXt1_u&_k=FSAMnCtwxdLaoep6

Of course sometimes you want to be able to define the URL yourself. I
think that was the purpose of Setphan's question. What is your goal?
Knowing that we can know if you need to define your URLs by yourself or
if the default behaviour of Seaside is enough.


> *Cordialement, Armel EMBOLO*
> <https://accounts.google.com/SignOutOptions?hl=fr&continue=https://mail.google.com/mail&service=mail>
> *_Ingénieur de travaux en Informatique de Gestion / Analyste programmeur_*
> *Elève Ingénieur de Conception  en Génie Logiciel*
> *Université de Maroua, _Ecole Nationale Supérieure Polytechnique de
> Maroua (ex ISS)_
> *
> *Facebook : Armel Embolo <https://www.facebook.com/armel.embolo>
> *
> *Linkedin : armel embolo
> <https://www.linkedin.com/profile/view?id=AAMAABYswuMBn33mi4o_x8R49OxfxiIQVAryzw4&trk=hp-identity-name>
> *
> *Tel : (+237) 650231339/698594740*
>
--
Cyril Ferlicot
https://ferlicot.fr
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

Ramon Leon-5
In reply to this post by feav feav
On 05/16/2018 01:50 PM, feav feav wrote:
> define my own URLs by myself

Then Seaside really isn't the framework for you.  You clearly want some
kind of MVC type framework like Rails where you have routes and
controllers; that's not Seaside.

--
Ramon Leon

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: help to use routing with seaside

NorbertHartl
You may have a look at Teapot then


Norbert
Am 17.05.2018 um 18:40 schrieb Ramon Leon <[hidden email]>:

On 05/16/2018 01:50 PM, feav feav wrote:
define my own URLs by myself

Then Seaside really isn't the framework for you.  You clearly want some kind of MVC type framework like Rails where you have routes and controllers; that's not Seaside.

--
Ramon Leon

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside