Welcome Guest, Not a member yet? Register   Sign In
problem with display of webpage - main page not proper, all others fine
#1

[eluser]bu[/eluser]
Hello, I am new to CI, and I have the following problem. Here is the [/code]site . This is the site for development.
My site structure is like this:

controllers:
-home; - my main page in which there is a problem with the display. the page seems to "drop down" a bit
-info;
-gallery;
-location;
-contacts.

models:
-calendar_model; - a model for my calendar
-content_model; - a model for the content of every page

views:
-header_view; -here is the menu and the header info and the main picture
-content_view; -the content
-footer_view; -the footer

all the pages use the same views and all except the home page display it correctly. Here is an example code:
My Home controller:

Code:
<?php

class Home extends Controller {

    function Home()
    {
        parent::Controller();            
    }
    
    function index($year = null, $month = null)
    {        
        $this->load->model('Content_model');
        $data = $this->Content_model->nachalo();
        $this->load->model('Calendar_model');
        $data['calendar'] = $this->Calendar_model->generate($year, $month,'home');
        
        $this->load->view('header_view',$data);
        $this->load->library('calendar');
        $this->load->view('home_view',$data);
        $this->load->view('footer_view',$data);
    }
}

This is how i call the css file from my header view:
Code:
<?php echo doctype('xhtml1-trans');
$meta = array(
        array('name' => 'Content-type', 'content' => 'application/html; charset=utf-8', 'type' => 'equiv')
    );?>
<html >
<head>
<?php echo meta($meta);?>
<link rel="stylesheet" type="text/css" href=<?php echo base_url() . "assets/css/def.css"?> media="screen" />
<?php echo link_tag('assets/css/lightbox.css');?>
<?php echo link_tag('assets/js/prototype.js');?>
<title>Самостоятелни стаи "Дъга"</title>

[removed][removed]
[removed][removed]
[removed][removed]

</head>

<body>
    <div id="wrapper">
        <div id="menu">
            &lt;?php echo $menu; ?&gt;            
        </div>
        &lt;!-- end #menu --&gt;
        <div id="header">
            <div id="logo">
                <h1>&lt;?php print($webtitle); ?&gt;</h1>
                <p> &lt;?php print($websubtitle); ?&gt;</p>
            </div>
        </div>
        &lt;!-- end #header --&gt;

Can someone help me with that problem?


Messages In This Thread
problem with display of webpage - main page not proper, all others fine - by El Forum - 08-12-2010, 04:14 AM



Theme © iAndrew 2016 - Forum software by © MyBB