0
Welcome Guest! Login
0 items Join Now

How Does One Style mainBody Content?

    • David Crisler's Avatar

    How Does One Style mainBody Content?

    Posted 17 years 8 months ago
    • In my short time with Joomla, I see templates that look good on the homepage, but once you click on an internal link it becomes boring Joomla content without much style.

      How do you control the look of actual content? If I want total control over the look, do I need to resort to using the wrapper and bringing in my own html pages?
    • CG Icon's Avatar
    • CG Icon
    • Hero Rocketeer
    • Posts: 371
    • Thanks: 0

    Re: How Does One Style mainBody Content?

    Posted 17 years 8 months ago
    • if it is your content that is boring then that is up to you to learn how do use your editor,,, I use JCE,, along with that some good knowledge of a raster editor such as PS or Fireworks.

      If it is your template that lets you down then learning a bit about CSS'n is really helpful

      if you have good looking HTML pages already,,dont wrap them !!!,,, all you need do is bring them into joomla, copy/ paste right into the editor using the editors HTML function..

      if you have a lot of pages to convert,, I do believe there is a plugin for that,, check Joomla.org
    • David Crisler's Avatar

    Re: How Does One Style mainBody Content?

    Posted 17 years 8 months ago
    • I have JCE too. My experience so far with the editors in Joomla is that they randomly strip code even when using the html function. How do you get around that?

      I rely on CSS exclusively to style content but it's frustrating when these Joomla editors strip out classes, ids, etc from the html.

      That brings up another question (thanks for your patience) - when you use your own custom CSS to style content, do you just append it to the template_css.css file or make a separate CSS file of your own? If separate, how you link to it? In the head of index.php?
    • Last Edit: 17 years 8 months ago by .
  • Re: How Does One Style mainBody Content?

    Posted 17 years 8 months ago
    • David Crisler wrote:
      I have JCE too. My experience so far with the editors in Joomla is that they randomly strip code even when using the html function. How do you get around that?
      You have to turn off the WYSIWYG editor and stay with the text only editor. THis will keep all the tags and styling you include in the content.
      That brings up another question (thanks for your patience) - when you use your own custom CSS to style content, do you just append it to the template_css.css file or make a separate CSS file of your own? If separate, how you link to it? In the head of index.php?
      You have basically answered all your question here. To avoid making the template_css.css difficult to read, you are better off creating your own and attach it to the index.php of the template you are using.
    • David Crisler's Avatar

    Re: How Does One Style mainBody Content?

    Posted 17 years 7 months ago
    • Thank you.

      Regarding the separate CSS file - how do you link to it? Usually, in my pre-Joomla days I just used the standard link code in my HTML like this:

      <link href="MYSTYLESHEET.css" rel="stylesheet" type="text/css" />

      Is that sufficient for Joomla? Because I notice Joomla mixes PHP code when linking to the template_css.css file like this:

      <style type="text/css" media="screen">
      @import url("<?php echo $mosConfig_live_site;?>
      /templates/new_site/css/template_css.css");
      </style>


      Which one should I use for my custom CSS file? Does it matter? Will they both work?
  • Re: How Does One Style mainBody Content?

    Posted 17 years 7 months ago
    • Joomla will not find this css.David Crisler wrote:
      <link href="MYSTYLESHEET.css" rel="stylesheet" type="text/css" />

      This looks okDavid Crisler wrote:
      <style type="text/css" media="screen">
      @import url("<?php echo $mosConfig_live_site;?>
      /templates/new_site/css/template_css.css");
      </style>

      this is a better way
      <link href="<?php echo $mosConfig_live_site;?>/templates/<?php echo $mainframe->getTemplate(); ?>/css/template_css.css" rel="stylesheet" type="text/css" />

      No hard coding of the site location and template name. you can move it to any site want.
    • GollumX's Avatar
    • GollumX
    • Elite Rocketeer
    • Posts: 2817
    • Thanks: 0

    Re: How Does One Style mainBody Content?

    Posted 17 years 7 months ago
    • Adding on more style sheets is not a good idea. Better to copy your css onto the end of template_css.css.
    • Say no to Internet Explorer 6.
      twitter.com/mark_up

Time to create page: 0.058 seconds