Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] <div> starting in header template and ending in footer template
#11

(This post was last modified: 07-22-2018, 04:14 AM by John_Betong.)

Meanwhile create .hhh CSS element with display:none; and use it to hide the div or another CSS element .bd1 set to outline: solid 2px red; because it will highlight the div without affecting rendering. Using border introduces space which could create another problem.
Reply
#12

I want to make sure I understand. You supply the following

Code:
<html>
    <head>
        <title>CodeIgniter Tutorial</title>
    </head>
    <body>
        <div>
            <h1><?php echo $title; ?></h1>

<!--footer template-->
            <em>&copy; 2015</em>
        </div>

        <div>
        </div>
    </body>
</html>

But it renders as

Code:
<html>
    <head>
        <title>CodeIgniter Tutorial</title>
    </head>
    <body>
        <div>
            <h1><?php echo $title; ?></h1>

<!--footer template-->
            <em>&copy; 2015</em>

        <div>
        </div>
        </div>
    </body>
</html>

Is that right?

There isn't any way that CodeIgniter would cause this to happen. I have to guess you have some code you're not showing and in that code there is a <div> that isn't closed. The magically appearing closing tag is being supplied by the browser.
Reply
#13
Smile 
(This post was last modified: 07-29-2018, 01:47 AM by misterSerious.)

Quote:Is that right?

There isn't any way that CodeIgniter would cause this to happen. I have to guess you have some code you're not showing and in that code there is a <div> that isn't closed. The magically appearing closing tag is being supplied by the browser.


You were right dave friend! I did have a <div> that wasn't closed somewhere within my code. 

Thank you and everyone else who tried to help me here.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB