We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16009
    • 23 Posts
    www.dvep.nl is not using css-based layout. The side menu is a css-styled unordered list, but the page layout is done using html tables.
    • www.dvep.nl is not using css-based layout. The side menu is a css-styled unordered list, but the page layout is done using html tables.

      I have a ton of examples of tableless designs using MODx -- here are a few to wet your appetite...

      http://opengeek.com
      http://thevirtualhandshake.com
      http://conciergeforbusiness.com
        • 16009
        • 23 Posts
        Thanks, I'll take a look.
          • 7455
          • 2,204 Posts
          CSS is cool but 1 thing that is not nice is that when wanting to fully use the powers of tv's making a lot of items in on the site variable the parts in the css can not be done or you need to add the whole css in the html file instead of including the file. i have a tv 4 background color and images vor cells that is not posible if I would use a div and css, would be nice if we could include a css-file from the database or css tv's hehe

          Greets Dim
            follow me on twitter: @dimmy01
          • CSS is cool but 1 thing that is not nice is that when wanting to fully use the powers of tv's making a lot of items in on the site variable the parts in the css can not be done or you need to add the whole css in the html file instead of including the file. i have a tv 4 background color and images vor cells that is not posible if I would use a div and css, would be nice if we could include a css-file from the database or css tv's hehe

            Greets Dim

            Actually Dimmy, you could easily write a snippet or use naming conventions that could load specific stylesheets for particular TV's, or create TV's that load different CSS's as you need to. I just completed a very effective fluid 3 column layout today that uses a <body id="[*alias*]"> to help me override specific values across a variety of templates and pages with a single CSS file. I could easily have created separate CSS's for each template and included them with a TV in order to accomplish the same thing using smaller individual files.

            But I do agree, CSS can impose limitations on design at times, but I think it is primarily because it is still a relatively new way of approaching something we've been doing in other ways for a relatively long time. And, of course, the endless sea of inconsistencies in browser implementations can give easily deter you from dealing with it at all. But all that is slowly fading away, and I personally love the new found freedom I've found in complete separation of style from raw content.

            If you want to explain more about your specific issue, I'd be glad to provide more thoughts on approaching it.

            Cheers,
              • 7455
              • 2,204 Posts
              Actually Dimmy, you could easily write a snippet or use naming conventions that could load specific stylesheets for particular TV's, or create TV's that load different CSS's as you need to.

              I know but that way i need to make a new css for each small change i want to make e.g. changing a background image of a collum or changing the color of a button etc etc.

              what I need is a flexible css if a user wants another bg image than they do not need to edit the css but just insert an image in an BG-Image TV thats what I mean.

              Is it not posible to make an snipoped that updates the css file with tv inputs (when needed) so that there is a css stored in the database that can be alterd by a tv and when it is alterd that it wil write a new css from that?

              That would be a nice option.

              Greets Dimmy
                follow me on twitter: @dimmy01
                • 32963
                • 1,732 Posts

                what I need is a flexible css if a user wants another bg image than they do not need to edit the css but just insert an image in an BG-Image TV thats what I mean.

                Hi Dimmy,

                Why not use a Chunk to store your css?

                By using a chunk as the style sheet you can extent the functionality of your templates.

                example:

                Create a chunk call StyleSheet and save your css with TVs inside the chunk:
                
                body {
                   background-image:[*BGImage*];
                   background-color:[*BGColor*]; }
                
                .title {
                  font-size:[*TitleSize*];
                  color:[*TitleColor*]; }
                
                


                Next add the chunk to your template or document using:
                <style>
                 {{StyleSheet}}
                </style>
                
                


                Now you have a dynamic style sheet at your disposal smiley

                Note: Only the dynamic parts of your style sheet should be done this way. Other none dynamic parts should be done using the regular <link> or @import methods.


                Best regards,
                  xWisdom
                  www.xwisdomhtml.com
                  The fear of the Lord is the beginning of wisdom:
                  MODx Co-Founder - Create and do more with less.
                  • 7455
                  • 2,204 Posts
                  ok that would be a good way to do it it does make your document source head a bit messy that way but its a good alternitive

                  would it work to have a partial style set in internal and partial in external?
                  e.g. if I have a div to set a collum than the dimentions and position would be set in the external css but if that same tag also needs a variable background image that i want to set in a tv would the external style with the same name as the internal style not be ignored or visa versa?

                  Thanks
                    follow me on twitter: @dimmy01
                    • 32963
                    • 1,732 Posts
                    ok that would be a good way to do it it does make your document source head a bit messy that way but its a good alternitive
                    It's only 3 lines smiley
                    may be something like should look much better:
                    <style>{{StyleSheet}}</style>
                    


                    The beauty about it is that it does works well with html wysiwyg editor.


                    would it work to have a partial style set in internal and partial in external?
                    e.g. if I have a div to set a collum than the dimentions and position would be set in the external css but if that same tag also needs a variable background image that i want to set in a tv would the external style with the same name as the internal style not be ignored or visa versa?

                    I think it should work as long as the css properties are different. Example:

                    in your external css file
                    .title {
                       width:200px; }
                    


                    in your internal css chunk
                    .title {
                       color:[*TitleColor*]; }
                    



                    Give it a try.
                      xWisdom
                      www.xwisdomhtml.com
                      The fear of the Lord is the beginning of wisdom:
                      MODx Co-Founder - Create and do more with less.
                      • 7455
                      • 2,204 Posts
                      ok that would be a good way to do it it does make your document source head a bit messy that way but its a good alternitive
                      It's only 3 lines smiley
                      may be something like should look much better:
                      <style>{{StyleSheet}}</style>
                      



                      In the template it is but when the code is generated it looks much differend when all those lines are insert LOL

                      I will give it a try thanks a lot for the time
                        follow me on twitter: @dimmy01