Fiksirati visinu stranice

Moderators: cicans, TheHacker

Locked
ugac
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Feb 15, 2010 7:35 pm

Fiksirati visinu stranice

Post by ugac » Sat Jan 14, 2012 7:34 pm

Radio sam temu u Artisteru i problem mi je da fiksiram visinu stranice. Može li mi neko pomoći?

Unapred zahvalan.

 
ugac
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Feb 15, 2010 7:35 pm

Re: Fiksirati visinu stranice

Post by ugac » Sun Jan 15, 2012 3:52 pm

U pitanju je http://surogat.rs/en/ , a ovo dole je source code. Ima li neko ideju?

Code: Select all

<?php

/**
 * Template for Joomla! CMS, created with Artisteer.
 * See readme.txt for more details on how to use the template.
 */

defined('_JEXEC') or die;

require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . 'functions.php';

// Create alias for $this object reference.
$document = & $this;

// Shortcut for template base url.
$templateUrl = $document->baseurl . '/templates/' . $document->template;

// Initialize version-specific view.
$version = new JVersion();
$view = $this->artx = ('1.5' == $version->RELEASE) ? new ArtxPage15($this) : new ArtxPage16($this);

// Decorate component with Artisteer style.
$view->componentWrapper();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $document->language; ?>" lang="<?php echo $document->language; ?>" >
<head>
 <jdoc:include type="head" />
 <link rel="stylesheet" href="<?php echo $document->baseurl; ?>/templates/system/css/system.css" type="text/css" />
 <link rel="stylesheet" href="<?php echo $document->baseurl; ?>/templates/system/css/general.css" type="text/css" />
 <link rel="stylesheet" type="text/css" href="<?php echo $templateUrl; ?>/css/template.css" media="screen" />
 <!--[if IE 6]><link rel="stylesheet" href="<?php echo $templateUrl; ?>/css/template.ie6.css" type="text/css" media="screen" /><![endif]-->
 <!--[if IE 7]><link rel="stylesheet" href="<?php echo $templateUrl; ?>/css/template.ie7.css" type="text/css" media="screen" /><![endif]-->
 <script type="text/javascript">if ('undefined' != typeof jQuery) document._artxJQueryBackup = jQuery;</script>
 <script type="text/javascript" src="<?php echo $templateUrl; ?>/jquery.js"></script>
 <script type="text/javascript">jQuery.noConflict();</script>
 <script type="text/javascript" src="<?php echo $templateUrl; ?>/script.js"></script>
 <script type="text/javascript">if (document._artxJQueryBackup) jQuery = document._artxJQueryBackup;</script>
</head>
<body class="<?php echo $view->bodyClass(); ?>">
<div id="art-main">
    <div class="cleared reset-box"></div>
<div class="art-sheet">
    <div class="art-sheet-cc"></div>
    <div class="art-sheet-body">
<div class="art-header">
    <div class="art-header-clip">
    <div class="art-header-center">
        <div class="art-header-jpeg"></div>
    </div>
    </div>
<div class="art-headerobject"></div>
<div class="art-logo">
</div>

</div>
<div class="cleared reset-box"></div>
<?php if ($view->containsModules('user3', 'extra1', 'extra2')) : ?>
<div class="art-nav">
  <div class="art-nav-l"></div>
  <div class="art-nav-r"></div>
<div class="art-nav-outer">
  <?php if ($view->containsModules('extra1')) : ?>
  <div class="art-hmenu-extra1"><?php echo $view->position('extra1'); ?></div>
  <?php endif; ?>
  <?php if ($view->containsModules('extra2')) : ?>
  <div class="art-hmenu-extra2"><?php echo $view->position('extra2'); ?></div>
  <?php endif; ?>
  <?php echo $view->position('user3'); ?>
</div>
</div>
<div class="cleared reset-box"></div>
<?php endif; ?>
<?php echo $view->position('banner1', 'art-nostyle'); ?>
<?php echo $view->positions(array('top1' => 33, 'top2' => 33, 'top3' => 34), 'art-block'); ?>
<div class="art-content-layout">
    <div class="art-content-layout-row">
<div class="art-layout-cell art-content">

<?php
  echo $view->position('banner2', 'art-nostyle');
  if ($view->containsModules('breadcrumb'))
    echo artxPost($view->position('breadcrumb'));
  echo $view->positions(array('user1' => 50, 'user2' => 50), 'art-article');
  echo $view->position('banner3', 'art-nostyle');
  if ($view->hasMessages())
    echo artxPost('<jdoc:include type="message" />');
  echo '<jdoc:include type="component" />';
  echo $view->position('banner4', 'art-nostyle');
  echo $view->positions(array('user4' => 50, 'user5' => 50), 'art-article');
  echo $view->position('banner5', 'art-nostyle');
?>

  <div class="cleared"></div>
</div>

    </div>
</div>
<div class="cleared"></div>


<?php echo $view->positions(array('bottom1' => 33, 'bottom2' => 33, 'bottom3' => 34), 'art-block'); ?>
<?php echo $view->position('banner6', 'art-nostyle'); ?>

    <div class="cleared"></div>
    </div>
</div>
<div class="art-footer">
    <div class="art-footer-body">
        <div class="art-footer-left">
            <div class="art-footer-wrapper">
                <div class="art-footer-text">
                    <?php echo $view->position('syndicate'); ?>
                    <?php if ($view->containsModules('copyright')): ?>
                    <?php echo $view->position('copyright', 'art-nostyle'); ?>
                    <?php else: ?>
                    <?php ob_start(); ?>
<p>Copyright © 2011. All Rights Reserved.</p>

<div class="cleared"></div>

                    <?php echo str_replace('%YEAR%', date('Y'), ob_get_clean()); ?>
                    <?php endif; ?>
                </div>
            </div>
        </div>
        <div class="cleared"></div>
    </div>
</div>

    <div class="cleared"></div>
</div>

<?php echo $view->position('debug'); ?>
</body>
</html>

User avatar
cicans
Joomla! Hero
Joomla! Hero
Posts: 2252
Joined: Fri Oct 12, 2007 10:31 am
Location: Novi Sad, Serbia
Contact:

Re: Fiksirati visinu stranice

Post by cicans » Sun Jan 15, 2012 5:35 pm

Blog: http://www.kuvarancije.com/
Serbian Joomla!® Translation Team Coordinator http://www.joomla-serbia.com/
Follow me on Twitter @cicans - Svetlana Zec

ugac
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Feb 15, 2010 7:35 pm

Re: Fiksirati visinu stranice

Post by ugac » Sun Jan 15, 2012 11:14 pm

Hvala na linku, ali za sada ne ide. :(

User avatar
dare023
Joomla! Explorer
Joomla! Explorer
Posts: 362
Joined: Mon Feb 25, 2008 4:07 pm
Location: Bečkerek
Contact:

Re: Fiksirati visinu stranice

Post by dare023 » Mon Jan 16, 2012 7:57 pm

Šta tu ima da ne ide?

ugac
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Feb 15, 2010 7:35 pm

Re: Fiksirati visinu stranice

Post by ugac » Mon Jan 16, 2012 9:27 pm

Veruj mi da koji god deo koda promenim stranica je uvek na 100 procenata. Prosto neverovatno.

Da li je moguće da mu js ne dozvoljava da sluša css (deo u kodu dole)? Usput, evo celog css-a -> http://www.mediafire.com/?phce5rt5n5x9w7v

Code: Select all

/* begin Layout */
109jQuery(function () {
110 var c = jQuery('div.art-content');
111 if (c.length !== 1) return;
112 var s = c.parent().children('.art-layout-cell:not(.art-content)');
113 jQuery(window).bind('resize', function () {
114 c.css('height', 'auto');
115 var r = jQuery(window).height() - jQuery('#art-main').height();
116 if (r > 0) c.css('height', r + c.height() + 'px');
117 });
118
119 if (jQuery.browser.msie && parseInt(jQuery.browser.version) < 8) {
120
121 jQuery(window).bind('resize', function () {
122 var w = 0;
123 c.hide();
124 s.each(function () { w += this.clientWidth; });
125 c.w = c.parent().width(); c.css('width', c.w - w + 'px');
126 c.show();
127 })
128
129 var r = jQuery('div.art-content-layout-row').each(function () {
130 this.c = jQuery(this).children('.art-layout-cell:not(.art-content)');
131 });
132
133 jQuery(window).bind('resize', function () {
134 r.each(function () {
135 if (this.h == this.clientHeight) return;
136 this.c.css('height', 'auto');
137 var r = jQuery(window).height() - jQuery('#art-main').height();
138 this.h = this.clientHeight;
139 if (r > 0) this.h += r;
140 this.c.css('height', this.h + 'px');
141 });
142 });
143 }

User avatar
dare023
Joomla! Explorer
Joomla! Explorer
Posts: 362
Joined: Mon Feb 25, 2008 4:07 pm
Location: Bečkerek
Contact:

Re: Fiksirati visinu stranice

Post by dare023 » Tue Jan 17, 2012 7:33 am

A da li si menjao min-height ovde?Lepo piše da je 100%.

Code: Select all

body
{
  padding: 0; 
  margin:0;
  color: #3D3E3D;
  height:100%;
  min-height:100%;
  background-color: #3A383E;
  background-image: url('../images/Bottom_texture.jpg');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: top center;
  min-width: 800px;
}

User avatar
cicans
Joomla! Hero
Joomla! Hero
Posts: 2252
Joined: Fri Oct 12, 2007 10:31 am
Location: Novi Sad, Serbia
Contact:

Re: Fiksirati visinu stranice

Post by cicans » Tue Jan 17, 2012 8:11 am

Sta je to sto treba da bude 100% visine?
Blog: http://www.kuvarancije.com/
Serbian Joomla!® Translation Team Coordinator http://www.joomla-serbia.com/
Follow me on Twitter @cicans - Svetlana Zec

User avatar
dare023
Joomla! Explorer
Joomla! Explorer
Posts: 362
Joined: Mon Feb 25, 2008 4:07 pm
Location: Bečkerek
Contact:

Re: Fiksirati visinu stranice

Post by dare023 » Tue Jan 17, 2012 9:51 am

Eto kad me mrzi da upalim firebug,pa sam pretpostavio da je body u pitanju.
Sad vidim da tu ima još divova sa height: ... !important .
Lepo instaliraj firebug i web developer u firefox i traži i drugi put nemoj da koristiš te programe,a da bi isprobao da li taj js nešto kvari u index.php u head sekciji probaj da izbrišeš liniju koja se odnosi na njega.To će biti samo neki fix za visinu zbog nesrećnog explorera.

Edit : @cicans - pretpostavljam samo deo sa sadržajem ,mada je već manji,pa je i pitanje koliko to manje treba da bude.

ugac
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Feb 15, 2010 7:35 pm

Re: Fiksirati visinu stranice

Post by ugac » Tue Jan 17, 2012 6:33 pm

Hvala ljudovi! Evo dobitne kombinacije, mada šta sam sve poradio nisam baš ni 100% siguran. :D
.art-content-layout
{
display: table;
position:relative;
margin: 0 auto;
table-layout: fixed;
border-collapse: collapse;
background-color: Transparent;
border: none !important;
padding:0 !important;
width:100%;
margin-top:0;
margin-bottom:0;
height: 450px !important;
}
.art-layout-cell, .art-content-layout-row
{
background-color: Transparent;
vertical-align: top;
text-align: left;
border: none;
margin:0;
padding:0;
height: 450px !important;
}
Visina layout-a je glavni krivac i ona je trčala na 100 posto. REŠENO!

 

Locked

Return to “Šabloni”