Reference to WAStyleLibrary

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

Reference to WAStyleLibrary

dtrussardi@tiscali.it
Hello All,
 
i work with VW7.4.1 and web support.
 
a) I'have defined one WAStyleLibrary subclass; ISTTabellaSortCSS with some uploaded - pictures.
Now in the styles method of the same class i reference this pictures.
Example : background-image: url (''ist/go/images/ISTTabellaSortCss/downsimple.png'')

My question is : i can define the path of image with only last definition
     background-image: url (''/downsimple.png'').

If yes where i define the prefix? ''ist/go/images/ISTTabellaSortCss"

b) The same problem is in javascript code where i reference the same
pictures.
  example:  img src = ''ist/go/images/ISTTabellaSortCss/downsimple.png'

c) What do you i need define to reference one image on my local disk
C:\images\pippo.png ?

Any pointers would be greatly appreciated!

Thank,

Dario Trussardi Romano


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

RE: Reference to WAStyleLibrary

Bany, Michel
Hi Dario,
         
        a) I'have defined one WAStyleLibrary subclass; ISTTabellaSortCSS
with some uploaded - pictures.
        Now in the styles method of the same class i reference this
pictures.
        Example : background-image: url
(''ist/go/images/ISTTabellaSortCss/downsimple.png'')
       
        My question is : i can define the path of image with only last
definition
             background-image: url (''/downsimple.png'').

The above makes me assume that you are using the SeasideImageTools
from the public store repository.

The answer to your question is no. When FileLibrary is ported to VW
(soon),
this will become possible (I believe).
       
        If yes where i define the prefix?
''ist/go/images/ISTTabellaSortCss"
       
        b) The same problem is in javascript code where i reference the
same
        pictures.
          example:  img src =
''ist/go/images/ISTTabellaSortCss/downsimple.png'

Here too, the answer to your question is no. It will become possible
with FileLibrary.
       
        c) What do you i need define to reference one image on my local
disk
        C:\images\pippo.png ?
       
Place the "pippo.png" file into $(VISUALWORKS)/web/examples,
it will be served with url http://localhost:8008/seaside/pippo.png
You may build any folder structure from there.

If you really need to place your static files in a specific folder
you will need to configure your Seaside site using a configure
file (see the VW documentation) or, programmatically with something
like that

        (VisualWave.WebSite siteNamed: 'seaside') configParameters
                at: 'directory' put: 'c:/seaside'

HTH
Michel.

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