Seaside : including a static stylesheet.
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way : updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css' On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server. Can anyone help me to find this directory? Thanks. --- Dominique Dartois
On 28 Feb 2017, at 18:53, Dominique Dartois <dom@dartois.org> wrote:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
The easiest way is to use a Seaside FileLibrary subclass to serve your static CSS file. This is described in that same chapter 17.
Thanks.
--- Dominique Dartois
There is the seaside list here: http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside You should join it. While developing, to serve static files without using nginx or apache you can use Zinc's ZnZincStaticServerAdaptor with something like: ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: '/var/www/'. But for production use you'd want to use apache or nginx Dominique Dartois-4 wrote
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
-- View this message in context: http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493671... Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Hi Dominique, for some cases I also use static files on my local machine, the root directory of the local machines web server is /Library/WebServer/Documents perhaps this is what you are looking for. regards Sabine 2017-02-28 18:53 GMT+01:00 Dominique Dartois <dom@dartois.org>:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
Hi Sabine. It does not seem working for me I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried : updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://localhost:8080/Library/WebServer/Documents/columnal.css'. The style sheet is not found. I keep on trying. Regards --- Dominique ________________________________ De : Pharo-users <pharo-users-bounces@lists.pharo.org> de la part de Sabine Manaa <manaa.sabine@gmail.com> Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet. Hi Dominique, for some cases I also use static files on my local machine, the root directory of the local machines web server is /Library/WebServer/Documents perhaps this is what you are looking for. regards Sabine 2017-02-28 18:53 GMT+01:00 Dominique Dartois <dom@dartois.org<mailto:dom@dartois.org>>: In the Seaside book, chapter 17.2 I read I can include a stylesheet this way : updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css' On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server. Can anyone help me to find this directory? Thanks. --- Dominique Dartois
Oh sorry. I didn't edit my example above to your situation. Here try this: 1. Open the seaside control panel and stop then remove all the server adaptors. 2. Put your directories & files next to your image. So put your 'styles' folder next to your image. 3. From the world menu open a Transcript. 4. In a playground or workspace run: |server| ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: FileSystem disk workingDirectory pathString. server:=ZnZincStaticServerAdaptor default server. server logToTranscript; debugMode: true. I think that will get you a Zinc server serving static files from the directory your image is in and will log everything to the transcript and open a debugger when there is an error. Dominique Dartois-4 wrote
Hi Sabine.
It does not seem working for me
I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://localhost:8080/Library/WebServer/Documents/columnal.css'.
The style sheet is not found.
I keep on trying.
Regards
---
Dominique
________________________________ De : Pharo-users <
pharo-users-bounces@.pharo
> de la part de Sabine Manaa <
manaa.sabine@
> Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet.
Hi Dominique,
for some cases I also use static files on my local machine, the root directory of the local machines web server is
/Library/WebServer/Documents
perhaps this is what you are looking for.
regards Sabine
2017-02-28 18:53 GMT+01:00 Dominique Dartois <
dom@
<mailto:
dom@
>>: In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
-- View this message in context: http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784... Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Hi Dominique, try to use http://localhost:8080/columnal.css
From your app If you have your columlal.css In Library/WebServer/Documents/ Because Library/WebServer/Documents Is the web server root This is the way I serve my static files
Regards Sabine Paul DeBruicker [via Smalltalk] <ml-node+s1294792n4937841h66@n4.nabble.com> schrieb am Mi. 8. März 2017 um 05:07:
Oh sorry. I didn't edit my example above to your situation. Here try this:
1. Open the seaside control panel and stop then remove all the server adaptors.
2. Put your directories & files next to your image. So put your 'styles' folder next to your image.
3. From the world menu open a Transcript.
4. In a playground or workspace run:
|server|
ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: FileSystem disk workingDirectory pathString. server:=ZnZincStaticServerAdaptor default server. server logToTranscript; debugMode: true.
I think that will get you a Zinc server serving static files from the directory your image is in and will log everything to the transcript and open a debugger when there is an error.
Dominique Dartois-4 wrote
Hi Sabine.
It does not seem working for me
I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: ' http://localhost:8080/Library/WebServer/Documents/columnal.css'.
The style sheet is not found.
I keep on trying.
Regards
---
Dominique
________________________________
De : Pharo-users <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=0>> de la part de Sabine Manaa <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=1>>
Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet.
Hi Dominique,
for some cases I also use static files on my local machine, the root directory of the local machines web server is
/Library/WebServer/Documents
perhaps this is what you are looking for.
regards Sabine
2017-02-28 18:53 GMT+01:00 Dominique Dartois <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=2><mailto:[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=3>>>:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
If you reply to this email, your message will be added to the discussion below:
http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784... To start a new topic under Pharo Smalltalk Users, email ml-node+s1294792n1310670h65@n4.nabble.com To unsubscribe from Pharo Smalltalk Users, click here <http://forum.world.st/template/NamlServlet.jtp?macro=unsubscribe_by_code&nod...> . NAML <http://forum.world.st/template/NamlServlet.jtp?macro=macro_viewer&id=instant...>
-- View this message in context: http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784... Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Dominique, you could test that with putting a simple html file there, e.g. index.html and than visit with your browser http://localhost/index.html than this file should be shown. This has nothing to do with seaside, it is only about finding the web server root on mac. Perhaps Pauls solution is better. Regards Sabine 2017-03-08 8:15 GMT+01:00 Sabine Manaa <manaa.sabine@gmail.com>:
Hi Dominique,
try to use http://localhost:8080/columnal.css From your app If you have your columlal.css In Library/WebServer/Documents/ Because Library/WebServer/Documents Is the web server root This is the way I serve my static files
Regards Sabine
Paul DeBruicker [via Smalltalk] <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937845&i=0>> schrieb am Mi. 8. März 2017 um 05:07:
Oh sorry. I didn't edit my example above to your situation. Here try this:
1. Open the seaside control panel and stop then remove all the server adaptors.
2. Put your directories & files next to your image. So put your 'styles' folder next to your image.
3. From the world menu open a Transcript.
4. In a playground or workspace run:
|server|
ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: FileSystem disk workingDirectory pathString. server:=ZnZincStaticServerAdaptor default server. server logToTranscript; debugMode: true.
I think that will get you a Zinc server serving static files from the directory your image is in and will log everything to the transcript and open a debugger when there is an error.
Dominique Dartois-4 wrote
Hi Sabine.
It does not seem working for me
I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://localhost:8080/ Library/WebServer/Documents/columnal.css'.
The style sheet is not found.
I keep on trying.
Regards
---
Dominique
________________________________
De : Pharo-users <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=0>> de la part de Sabine Manaa <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=1>>
Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet.
Hi Dominique,
for some cases I also use static files on my local machine, the root directory of the local machines web server is
/Library/WebServer/Documents
perhaps this is what you are looking for.
regards Sabine
2017-02-28 18:53 GMT+01:00 Dominique Dartois <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=2><mailto:[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=3>>>:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
If you reply to this email, your message will be added to the discussion below: http://forum.world.st/Seaside-including-a-static-stylesheet- tp4936435p4937841.html To start a new topic under Pharo Smalltalk Users, email [hidden email] <http:///user/SendEmail.jtp?type=node&node=4937845&i=1> To unsubscribe from Pharo Smalltalk Users, click here. NAML <http://forum.world.st/template/NamlServlet.jtp?macro=macro_viewer&id=instant...>
------------------------------ View this message in context: Re: Seaside : including a static stylesheet. <http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784...> Sent from the Pharo Smalltalk Users mailing list archive <http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html> at Nabble.com.
Hi Sabine, this raises my interest. So you have two web servers listening to the same port, one being macOS X' built in web server (how did you activate/configure it?) and Seaside? If I visit localhost:8080 on my mac (no pharo image or anything running), I get no answer, although there are files in /Library/WebServer/Documents (provided by Apple: index.html.en). Joachim Am 08.03.17 um 08:15 schrieb Sabine Manaa:
Hi Dominique,
try to use http://localhost:8080/columnal.css From your app If you have your columlal.css In Library/WebServer/Documents/ Because Library/WebServer/Documents Is the web server root This is the way I serve my static files
Regards Sabine
Paul DeBruicker [via Smalltalk] <[hidden email] </user/SendEmail.jtp?type=node&node=4937845&i=0>> schrieb am Mi. 8. März 2017 um 05:07:
Oh sorry. I didn't edit my example above to your situation. Here try this:
1. Open the seaside control panel and stop then remove all the server adaptors.
2. Put your directories & files next to your image. So put your 'styles' folder next to your image.
3. From the world menu open a Transcript.
4. In a playground or workspace run:
|server|
ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: FileSystem disk workingDirectory pathString. server:=ZnZincStaticServerAdaptor default server. server logToTranscript; debugMode: true.
I think that will get you a Zinc server serving static files from the directory your image is in and will log everything to the transcript and open a debugger when there is an error.
Dominique Dartois-4 wrote
Hi Sabine.
It does not seem working for me
I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://localhost:8080/Library/WebServer/Documents/columnal.css' <http://localhost:8080/Library/WebServer/Documents/columnal.css%27>.
The style sheet is not found.
I keep on trying.
Regards
---
Dominique
________________________________
De : Pharo-users <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=0>> de la part de Sabine Manaa <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=1>>
Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet.
Hi Dominique,
for some cases I also use static files on my local machine, the root directory of the local machines web server is
/Library/WebServer/Documents
perhaps this is what you are looking for.
regards Sabine
2017-02-28 18:53 GMT+01:00 Dominique Dartois <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=2><mailto:[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=3>>>:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css' <http://seaside.st/styles/main.css%27>
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
If you reply to this email, your message will be added to the discussion below: http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784...
To start a new topic under Pharo Smalltalk Users, email [hidden email] </user/SendEmail.jtp?type=node&node=4937845&i=1> To unsubscribe from Pharo Smalltalk Users, click here. NAML <http://forum.world.st/template/NamlServlet.jtp?macro=macro_viewer&id=instant...>
------------------------------------------------------------------------ View this message in context: Re: Seaside : including a static stylesheet. <http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784...> Sent from the Pharo Smalltalk Users mailing list archive <http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html> at Nabble.com.
-- ----------------------------------------------------------------------- Objektfabrik Joachim Tuchel mailto:jtuchel@objektfabrik.de Fliederweg 1 http://www.objektfabrik.de D-71640 Ludwigsburg http://joachimtuchel.wordpress.com Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
Hi Joachim, I did nothing:-) I assume the macs web server runs by default. The localhost:8080 only works if I have Pharo/seaside running. the index.html example is independent of Pharo/seaside. I can not explain, perhaps someone other. But a long time ago, I was looking for a solution how to reference static css and png files in my local environment and I ended up with this solution. Regards Sabine 2017-03-08 8:47 GMT+01:00 jtuchel [via Smalltalk] < ml-node+s1294792n4937851h76@n4.nabble.com>:
Hi Sabine,
this raises my interest. So you have two web servers listening to the same port, one being macOS X' built in web server (how did you activate/configure it?) and Seaside?
If I visit localhost:8080 on my mac (no pharo image or anything running), I get no answer, although there are files in /Library/WebServer/Documents (provided by Apple: index.html.en).
Joachim
Am 08.03.17 um 08:15 schrieb Sabine Manaa:
Hi Dominique,
try to use http://localhost:8080/columnal.css From your app If you have your columlal.css In Library/WebServer/Documents/ Because Library/WebServer/Documents Is the web server root This is the way I serve my static files
Regards Sabine
Paul DeBruicker [via Smalltalk] <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937845&i=0>> schrieb am Mi. 8. März 2017 um 05:07:
Oh sorry. I didn't edit my example above to your situation. Here try this:
1. Open the seaside control panel and stop then remove all the server adaptors.
2. Put your directories & files next to your image. So put your 'styles' folder next to your image.
3. From the world menu open a Transcript.
4. In a playground or workspace run:
|server|
ZnZincStaticServerAdaptor startOn: 8080 andServeFilesFrom: FileSystem disk workingDirectory pathString. server:=ZnZincStaticServerAdaptor default server. server logToTranscript; debugMode: true.
I think that will get you a Zinc server serving static files from the directory your image is in and will log everything to the transcript and open a debugger when there is an error.
Dominique Dartois-4 wrote
Hi Sabine.
It does not seem working for me
I have found this directory here "/Users/Dom/Documents/Library/WebServer/Documents" and I tried :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://localhost:8080/ Library/WebServer/Documents/columnal.css'.
The style sheet is not found.
I keep on trying.
Regards
---
Dominique
________________________________
De : Pharo-users <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=0>> de la part de Sabine Manaa <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=1>>
Envoyé : mardi 7 mars 2017 10:08:33 à : Any question about pharo is welcome Objet : Re: [Pharo-users] Seaside : including a static stylesheet.
Hi Dominique,
for some cases I also use static files on my local machine, the root directory of the local machines web server is
/Library/WebServer/Documents
perhaps this is what you are looking for.
regards Sabine
2017-02-28 18:53 GMT+01:00 Dominique Dartois <[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=2><mailto:[hidden email] <http:///user/SendEmail.jtp?type=node&node=4937841&i=3>>>:
In the Seaside book, chapter 17.2 I read I can include a stylesheet this way :
updateRoot: anHtmlRoot super updateRoot: anHtmlRoot. anHtmlRoot stylesheet url: 'http://seaside.st/styles/main.css'
On my development machine (macOS) I use http://localhost:8080/myApp as the server address and I donât know the root directory of the Seaside integrated web server.
Can anyone help me to find this directory?
Thanks.
---
Dominique Dartois
If you reply to this email, your message will be added to the discussion below: http://forum.world.st/Seaside-including-a-static-stylesheet- tp4936435p4937841.html To start a new topic under Pharo Smalltalk Users, email [hidden email] <http:///user/SendEmail.jtp?type=node&node=4937845&i=1> To unsubscribe from Pharo Smalltalk Users, click here. NAML <http://forum.world.st/template/NamlServlet.jtp?macro=macro_viewer&id=instant...>
------------------------------ View this message in context: Re: Seaside : including a static stylesheet. <http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493784...> Sent from the Pharo Smalltalk Users mailing list archive <http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html> at Nabble.com.
-- ----------------------------------------------------------------------- Objektfabrik Joachim Tuchel [hidden email] <http:///user/SendEmail.jtp?type=node&node=4937851&i=0> Fliederweg 1 http://www.objektfabrik.de D-71640 Ludwigsburg http://joachimtuchel.wordpress.com Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
------------------------------ If you reply to this email, your message will be added to the discussion below: http://forum.world.st/Seaside-including-a-static-stylesheet- tp4936435p4937851.html To start a new topic under Pharo Smalltalk Users, email ml-node+s1294792n1310670h65@n4.nabble.com To unsubscribe from Pharo Smalltalk Users, click here <http://forum.world.st/template/NamlServlet.jtp?macro=unsubscribe_by_code&nod...> . NAML <http://forum.world.st/template/NamlServlet.jtp?macro=macro_viewer&id=instant...>
-- View this message in context: http://forum.world.st/Seaside-including-a-static-stylesheet-tp4936435p493785... Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
participants (5)
-
Dominique Dartois -
jtuchel@objektfabrik.de -
Paul DeBruicker -
Sabine Manaa -
Sven Van Caekenberghe