Results 1 to 10 of 10

Thread: Need some basic web help

  1. #1
    I'm just looking Tifosi's Avatar
    Join Date
    Feb 2004
    Location
    127.0.0.1
    Posts
    843
    Thanks
    8
    Thanked
    5 times in 4 posts
    • Tifosi's system
      • Motherboard:
      • DFI LanParty UT nF4 SLI-DR
      • CPU:
      • AMD64 Venice 3200 s939
      • Memory:
      • 2x 1GB DDR400 Corsair XMS
      • Storage:
      • OCZ Vertex 2.5" 64GB SSD
      • Graphics card(s):
      • Geforce G210T / Geforce 7800GT
      • PSU:
      • ?
      • Case:
      • Lian Li PC-V1110
      • Operating System:
      • Ubuntu 12.04
      • Monitor(s):
      • Dell 2405FPW
      • Internet:
      • VM

    Need some basic web help

    I've just open a new site with my basic web skills.

    Evoke Reality

    As you can see this page is HTML and at the top is a Javascript menu bar.

    Head
    Code:
    <style>
    all.clsMenuItemNS, .clsMenuItemIE{text-decoration: none; font: bold 12px Arial; color: white; cursor: hand; z-index:100}
    #MainTable A:hover {color: yellow;}
    </style>
    
    <script language="JavaScript">
    
    //Top Nav Bar I v2.1- By Constantin Kuznetsov Jr.
    //Modified by Dynamic Drive for various improvements
    //Visit http://www.dynamicdrive.com for this script
    
    var keepstatic=1 //specify whether menu should stay static (works only in IE4+)
    var menucolor="#000000" //specify menu color
    var submenuwidth=150 //specify sub menus' width
    
    </script>
    Body
    Code:
    <script language="JavaScript" src="menu.js"></script>
    <script language="JavaScript" src="menucontext.js"></script>
    <script language="JavaScript">
    showToolbar();
    </script>
    <script language="JavaScript">
    function UpdateIt(){
    if (ie&&keepstatic&&!opr6)
    document.all["MainTable"].style.top = document.body.scrollTop;
    setTimeout("UpdateIt()", 200);
    }
    UpdateIt();
    </script>
    Now I would like this menu to appear on my gallery pages these are written in PHP (not by me).

    Both pages
    1
    2

    Can some one show me where I need to put the Javascipt from the HTML pages into the PHP pages to get the same effect?

    I've spent 2hous messing about with the PHP but its real trial and error on my behlaf any help greatly appreciated.
    Last edited by Tifosi; 05-05-2005 at 01:41 AM.

  2. #2
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    Before I respond can you please modify your sig within 24 hours as it is too close to the sig image the forum mods and admins use. We didn't put those images up so you could take them and modify them for your own use, they are there to signify people's roles.

    Thanks in advance.

  3. #3
    I'm just looking Tifosi's Avatar
    Join Date
    Feb 2004
    Location
    127.0.0.1
    Posts
    843
    Thanks
    8
    Thanked
    5 times in 4 posts
    • Tifosi's system
      • Motherboard:
      • DFI LanParty UT nF4 SLI-DR
      • CPU:
      • AMD64 Venice 3200 s939
      • Memory:
      • 2x 1GB DDR400 Corsair XMS
      • Storage:
      • OCZ Vertex 2.5" 64GB SSD
      • Graphics card(s):
      • Geforce G210T / Geforce 7800GT
      • PSU:
      • ?
      • Case:
      • Lian Li PC-V1110
      • Operating System:
      • Ubuntu 12.04
      • Monitor(s):
      • Dell 2405FPW
      • Internet:
      • VM
    done

  4. #4
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    Thanks

    Without seeing the code for the PHP page I can't really say. The best bet would be to put the code into one or 2 includes and add it in that way. Best bet is to show use the code for the page and we can comment

  5. #5
    I'm just looking Tifosi's Avatar
    Join Date
    Feb 2004
    Location
    127.0.0.1
    Posts
    843
    Thanks
    8
    Thanked
    5 times in 4 posts
    • Tifosi's system
      • Motherboard:
      • DFI LanParty UT nF4 SLI-DR
      • CPU:
      • AMD64 Venice 3200 s939
      • Memory:
      • 2x 1GB DDR400 Corsair XMS
      • Storage:
      • OCZ Vertex 2.5" 64GB SSD
      • Graphics card(s):
      • Geforce G210T / Geforce 7800GT
      • PSU:
      • ?
      • Case:
      • Lian Li PC-V1110
      • Operating System:
      • Ubuntu 12.04
      • Monitor(s):
      • Dell 2405FPW
      • Internet:
      • VM
    Index.php
    PHP Code:
    <?php

    /* vim: set expandtab tabstop=4 shiftwidth=4: */
    //
    // SimpleViewer
    // ---------------------------------------------------------------------
    // Access your SimpleViewer gallery right through this page. For 
    // embedding purposes it only includes a the SimpleViewer.php 
    // 
    // 
    // Note:
    // This index.php just includes the summary page.
    //
    // ---------------------------------------------------------------------
    // Copyright (c) 2004 Christian Machmeier
    // ---------------------------------------------------------------------
    //
    // $Id: index.php,v 1.1.1.1 2004/05/27 22:20:25 grisu Exp $
    //

    // {{{ Cache control headers

    header("Expires: Mon, 31 Dec 2003 12:34:56 GMT");
    header("Last-Modified: " gmdate("D, d M Y H:i:s") ." GMT");
    header("Pragma: no-cache");
    header("Cache-Control: no-cache");
    header("Cache-Control: post-check=0, pre-check=0"false);

    // }}}

    // Load the SimpleViewer configuration.
    require_once 'SimpleViewerConfig.php';

    // Load the SimpleViewer functions library.
    require_once 'SimpleViewerFunctions.php';

    // Get the current number of albums.
    $dirList getDirList('./'''false'dirs');

    // SimpleViewer is not installed yet.
    if ($dirList['Number'] == 0) {
        
    header('Location:SimpleViewerAdmin.php');
        exit;
    }

    ?>
    <!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="en" lang="en">
        <head>
            <title><?php echo $simpleViewer['title']; ?></title>
            <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
            <link rel="stylesheet" type="text/css" href="SimpleViewerCss.php" />
        </head>
        <body>
            <?php require_once 'SimpleViewer.php'?>
        </body>
    </html>
    and

    simpleViewer.php
    PHP Code:
    <?php

    /* vim: set expandtab tabstop=4 shiftwidth=4: */
    //
    // SimpleViewer
    // ---------------------------------------------------------------------
    // Access your SimpleViewer gallery right through this page by getting
    // a summary of your currently installed albums first. After your choice
    // the requested album will be loaded from the according directory.
    // 
    // Note:
    // This file contains the summary, the albums and the installation link.
    // This file is embedded in the index.php.
    // ---------------------------------------------------------------------
    // Copyright (c) 2004 Christian Machmeier
    // ---------------------------------------------------------------------
    //
    // $Id: SimpleViewer.php,v 1.2 2004/06/06 20:52:35 grisu Exp $
    //

    // Load the SimpleViewer configuration.
    require_once 'SimpleViewerConfig.php';

    // Load the SimpleViewer functions library.
    require_once 'SimpleViewerFunctions.php';

    // An album name was specified.
    if (!empty($_GET['album']) && is_dir($_GET['album'])) {

        
    $albumConfig getConfig('./' $_GET['album'] . '/imageData.xml');

    ?>
        <script language="javascript" type="text/javascript" src="flash_detect.js">
        <!--
            function getFlashVersion() { return null; };
        //-->
        </script>
        <script language="javascript" type="text/javascript">
        <!--
            var flashVersion = getFlashVersion();
            if (flashVersion < 6) {        
                window.location.replace("upgrade.html");
            }
        //-->
        </script>
        <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="<?php echo $simpleViewer['galleryWidth']; ?>" height="<?php echo $simpleViewer['galleryHeight']; ?>" id="viewer" align="middle">
            <param name="movie"       value="viewer.swf" />
            <param name="quality"     value="high" />
            <param name="scale"       value="noscale" />
            <param name="bgcolor"   value="<?php echo str_replace('0x''#'$albumConfig['backgroundColor']); ?>" />
            <param name="FlashVars" value="xmlDataPath=SimpleViewerImageData.php?album=<?php echo $_GET['album'];?>" />
            <embed src="viewer.swf" width="<?php echo $simpleViewer['galleryWidth']; ?>" height="<?php echo $simpleViewer['galleryHeight']; ?>" align="middle" quality="high" scale="noscale" bgcolor="<?php echo str_replace('0x''#'$albumConfig['backgroundColor']); ?>" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" FlashVars="xmlDataPath=SimpleViewerImageData.php?album=<?php echo $_GET['album'];?>" />
        </object>
    <?php
    // No album name was specified
    } else {
    ?>
        <table cellpadding="0" cellspacing="0" width="<?php echo $simpleViewer['galleryWidth']; ?>" height="<?php echo $simpleViewer['galleryHeight']; ?>" border="0">
            <tr>
                <td align="center" valign="middle" style="height: 10px; font: sans-serif;"">
                    <div id="overview">
                        <?php
                        
    // Get the current number of albums.
                        
    $dirList getDirList('./'''false'dirs');
                        
                        
    // SimpleViewer is not installed yet.
                        
    if ($dirList['Number'] == 0) {
                            echo 
    '
                                <h2>SimpleViewer is not installed!</h2>
                                Please log in: <a href="SimpleViewerAdmin.php" class="overview">' 
    $simpleViewer['adminTitle'] . '</a>
                            '
    ;
                        
    // SimpleViewer is installed, show the list of albums.
                        
    } else {
                            echo 
    '
                                <h2>' 
    $simpleViewer['title'] . '</h2>
                                SELECT ALBUM:
                                <ul>
                            '
    ;
                            
                            
    // sort and output the album list.
                            
    natsort($dirList['List']);
                            foreach (
    $dirList['List'] as $k => $v) {
                                
    $xmlData getConfig('./' $v '/imageData.xml');
                                echo 
    '<li><a href="?album=' $v '" class="overview">' $xmlData['title'] . "</a></li>\n";
                            }
                            echo 
    '
                                </ul>
                                GALLERY MANAGEMENT <a href="SimpleViewerAdmin.php" class="overview">LOGIN!</a>
                            '
    ;
                        }
                        
    ?>
                    </div>
                </td>
            </tr>
            <tr>
                <td style="text-align: right; height: 10px; font: sans-serif;">
                    <a href="http://www.redsplash.de/projects/simplevieweradmin/" class="overview" style="margin-right: 5px;" target="_blank">SimpleViewerAdmin <?php echo $simpleViewer['version']; ?></a>
                </td>
            </tr>
        </table>
    <?php
    }
    ?>
    Last edited by Tifosi; 05-05-2005 at 05:00 PM.

  6. #6
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    Just place your head code in between the head tags and the body code immediately after the body tag and it should work

  7. #7
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    You don't need to add anything to SimpleViewer.php

  8. #8
    I'm just looking Tifosi's Avatar
    Join Date
    Feb 2004
    Location
    127.0.0.1
    Posts
    843
    Thanks
    8
    Thanked
    5 times in 4 posts
    • Tifosi's system
      • Motherboard:
      • DFI LanParty UT nF4 SLI-DR
      • CPU:
      • AMD64 Venice 3200 s939
      • Memory:
      • 2x 1GB DDR400 Corsair XMS
      • Storage:
      • OCZ Vertex 2.5" 64GB SSD
      • Graphics card(s):
      • Geforce G210T / Geforce 7800GT
      • PSU:
      • ?
      • Case:
      • Lian Li PC-V1110
      • Operating System:
      • Ubuntu 12.04
      • Monitor(s):
      • Dell 2405FPW
      • Internet:
      • VM
    Hi Iain, I've done that but the menu's don't drop down under their headings

    Should be like these
    but they coming out like this

    Any ideas?

    Also when you click on the 18-55 gallery link on this page the menus don't appear on the subsequent page.
    Last edited by Tifosi; 06-05-2005 at 02:23 PM.

  9. #9
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    At a guess the menu is appearing on the 18-55 gallery link but the Flash movie is appearing above it so you can't see it. This is the problem with Flash, it appears on top of everything else. You can see this by looking at the source

    Code:
    <embed src="viewer.swf" width="100%" height="100%" align="middle" quality="high" scale="noscale" bgcolor="#000000" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" FlashVars="xmlDataPath=SimpleViewerImageData.php?album=1855mm" />
    The height of 100% means that Flash will take up the whole height and hence sit on top of your menu. There's no solution for this I'm afraid as using a framset won't work as the menu drop down will appear inside the frame rather than across them so you wouldn't see the drop down.

    As for the first issue I'm not sure without looking more closely and I'm afraid I don't have the time at the moment. Hopefully someone else will be able to assist.

  10. #10
    I'm just looking Tifosi's Avatar
    Join Date
    Feb 2004
    Location
    127.0.0.1
    Posts
    843
    Thanks
    8
    Thanked
    5 times in 4 posts
    • Tifosi's system
      • Motherboard:
      • DFI LanParty UT nF4 SLI-DR
      • CPU:
      • AMD64 Venice 3200 s939
      • Memory:
      • 2x 1GB DDR400 Corsair XMS
      • Storage:
      • OCZ Vertex 2.5" 64GB SSD
      • Graphics card(s):
      • Geforce G210T / Geforce 7800GT
      • PSU:
      • ?
      • Case:
      • Lian Li PC-V1110
      • Operating System:
      • Ubuntu 12.04
      • Monitor(s):
      • Dell 2405FPW
      • Internet:
      • VM
    Quote Originally Posted by Iain
    The height of 100% means that Flash will take up the whole height and hence sit on top of your menu. There's no solution for this I'm afraid as using a framset won't work as the menu drop down will appear inside the frame rather than across them so you wouldn't see the drop down.
    I thought that was the case and I thought about using frames but realised the problem.

    Hmm back to the drawing board.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Framed web forwarding
    By ricob in forum Networking and Broadband
    Replies: 4
    Last Post: 26-01-2005, 09:30 PM
  2. Replies: 2
    Last Post: 16-11-2004, 05:58 PM
  3. RIAA Web Site Gets Doomed..
    By myth in forum General Discussion
    Replies: 9
    Last Post: 06-08-2004, 02:52 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •