Very, very strangely working iframe.



  • What's the point?

    введите сюда описание изображения

    We press the pink trail.

       <?php
    include_once '../scripts/php/conf.php';
    ?>
    

    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>News</title>

        &lt;link rel="stylesheet" href="../scripts/css/news.css"/&gt;
        &lt;link rel="stylesheet" href="../scripts/css/stylesheet.css"/&gt;
        &lt;link rel="stylesheet" href="../scripts/css/jquery.jscrollpane.css"/&gt;
    
        &lt;script type="text/javascript" src="../scripts/js/jquery-1.6.1.min.js"&gt;&lt;/script&gt;
        &lt;script type="text/javascript" src="../scripts/js/jquery.mousewheel.js"&gt;&lt;/script&gt;
        &lt;script type="text/javascript" src="../scripts/js/jquery.jscrollpane.js"&gt;&lt;/script&gt;
    
        &lt;style type="text/css"&gt;
    
            body {
                overflow-x: hidden;
                overflow-y: hidden;
                font-family: 'pixel';
            } 
    
            .scroll-pane {
                position: absolute;
                top: 0px;
                left: 30%;
                width: 70%; 
                height: 100%; 
                overflow: auto;
                background-color: #828898;
            }
    
        &lt;/style&gt;
    
        &lt;script type="text/javascript"&gt;
    
            function openBand(URL) {
                var content = window.top.document.getElementById('content');
                content.src = URL;
                content.style.display = 'block';
            }
    
        &lt;/script&gt;
    &lt;/head&gt;
    
    &lt;body&gt;
    
        &lt;?php
    
            $q = "SELECT * FROM `bands` ORDER BY `id` DESC LIMIT 5";
            $result = mysql_query($q);
    
            echo '&lt;div class="scroll-pane"&gt;';
    
            while($row = mysql_fetch_array($result)) {
    
                $block = '  
                &lt;div class="block"&gt;
                    &lt;img src="../bands/'.$row['band'].'/logo.jpg"&gt;
                    &lt;div&gt;&lt;/div&gt;&lt;p&gt;'.$row['band'].'&lt;/p&gt;
                    &lt;span&gt;Added a new album, just click to see the blades&lt;/span&gt;&lt;br&gt;
                    &lt;a href="#" onClick="openBand(\'http://localhost/NetFM/bands/'.$row['band'].'/'.$row['band'].'.php\')"&gt;...&lt;/a&gt;
                &lt;/div&gt;';
    
                echo $block;
            }
    
            echo '
            &lt;/div&gt;
    
            &lt;script type="text/javascript"&gt;
                jQuery(function() {
                    jQuery(\'.scroll-pane\').jScrollPane();
                });
            &lt;/script&gt;';
    
        ?&gt;
    
    
    &lt;/body&gt;
    

    </html>

    Iframe is downloaded.

    введите сюда описание изображения

    and happens:

    введите сюда описание изображения

    The whole top line disappears.

    How? ?



  • Corrected

    position: fixed;
    

    for iframe




Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2