TalkPHP
 
 
Account Login
Latest Articles
» The basic usage of PHPTAL, a XML/XHTML template library for PHP
» Vulnerable methods and the areas they are commonly trusted in.
» Simple way to protect a form from bot
» The Basics On: How Session Stealing Works
» How to keep your forms from double posting data
IRC Channel
IRC Speech Bubble Join the friendly bunch on IRC...
(#TalkPHP on Freenode)

...Also available via a web interface.

See this thread for information on the TalkPHP Free Hugs Initiative™. Subject to availability.
Associates
Associates
CSS Tutorials
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 03-09-2010, 07:14 PM   #1 (permalink)
The Wanderer
 
erice's Avatar
 
Join Date: Mar 2010
Posts: 5
Thanks: 0
erice is on a distinguished road
Default new and having problems

I using php to link external files.
I created a menu file and worked great, but then I found out I need to have sub menus, I created that using java now when I reattach the file the menu is off the grid. So I created another file doing the java a diffrent way now I have the buttons in the correct location but the drop downs do not work.

also when attaching css to the text do you do that in the file you are attaching or should you do that in the main doc because I assigned all links on the main page to be white but in the attached php page I want the links to be gray but there turning white


any ideal

thanks
erice is offline  
Reply With Quote
Old 03-11-2010, 11:39 AM   #2 (permalink)
The Visitor
 
Join Date: Mar 2010
Posts: 2
Thanks: 0
tanu is on a distinguished road
Default

I am too new and having the problem so please tell me in detail....

_______________
boys room décor
Double Hung Windows
tanu is offline  
Reply With Quote
Old 03-11-2010, 03:45 PM   #3 (permalink)
The Wanderer
 
erice's Avatar
 
Join Date: Mar 2010
Posts: 5
Thanks: 0
erice is on a distinguished road
Default

I attached a image that can explain what I was saying
when I include the menu that I used java, it is off the page but if I use a basic menu it works perfect but I need the drop down menu
I even tried creating a new page with just the menu and a image but but got the same result the menu is off to the side

open for any advice you can give

<?php include($DOCUMENT_ROOT . "menus/graysolutionsmenu.php");?>
this what I am using and tried other ways but the same result
Attached Thumbnails
new-having-problems-what.jpg  
erice is offline  
Reply With Quote
Old 03-15-2010, 03:54 AM   #4 (permalink)
The Contributor
 
Join Date: Jun 2009
Location: Seattle, WA
Posts: 76
Thanks: 1
rguy84 is on a distinguished road
Default

This is a multi faceted problem, however in the third post the PHP is incorrect. Try:
PHP Code:
<?php include($_SERVER['DOCUMENT_ROOT']."/menus/graysolutionsmenu.php");?>
__________________
Ryan | Blog | Twitter
Send a message via AIM to rguy84 Send a message via MSN to rguy84 Send a message via Yahoo to rguy84 Send a message via Skype™ to rguy84
rguy84 is offline  
Reply With Quote
Old 03-15-2010, 12:15 PM   #5 (permalink)
The Wanderer
 
erice's Avatar
 
Join Date: Mar 2010
Posts: 5
Thanks: 0
erice is on a distinguished road
Default no change

thanks for the sugestion but it is doing the samething
erice is offline  
Reply With Quote
Old 03-15-2010, 06:44 PM   #6 (permalink)
is cute and cuddly
 
delayedinsanity's Avatar
 
Join Date: Mar 2008
Location: Vegas, Baby
Posts: 963
Thanks: 31
delayedinsanity is on a distinguished road
Default

Quote:
This is a multi faceted problem, however in the third post the PHP is incorrect.
Unless of course he has register_globals turned on, then it's completely correct and he has a much more severe underlying problem - a poorly configured PHP installation that probably has a plethora of other deprecated and insecure options turned on like magic_quotes_gpc and the like.

Pastebin the entire script or post a link if you could - it looks like you're having a CSS issue and not a PHP one, but it's impossible to tell without having a victim to sacrifice... er, I mean code to look at.
delayedinsanity is offline  
Reply With Quote
Old 03-15-2010, 07:24 PM   #7 (permalink)
The Wanderer
 
erice's Avatar
 
Join Date: Mar 2010
Posts: 5
Thanks: 0
erice is on a distinguished road
Default

here is the coed for the menu
thanks the book I read said nothing about this problem

<!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">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>menusolutions</title>

<!--start of the js drop down menu ------------------------------------------------------------------------------------------------------------
<style type="text/css">

#dropmenudiv{
position:absolute;
border:1px solid gray;
border-bottom-width: 0px;
font:normal 10px Verdana;
line-height:15px;
z-index:110;
}

#dropmenudiv a{
width: 100%;
display: block;
text-indent: 3px;
border-bottom: 1px solid gray;
padding: 1px 0;
text-decoration: none;
font-weight: bold;
}

#dropmenudiv a:hover{
background-color: #999999;
}

a:link {
text-decoration: none;
color: #FFFFFF;
}
a:visited {
text-decoration: none;
color: #FFFFFF;
}
a:hover {
text-decoration: none;
color: #FFFFFF;
}
a:active {
text-decoration: none;
color: #FFFFFF;
}
body,td,th {
color: #FFFFFF;
}
</style>
<script type="text/javascript">

//menu 1 <!--menu section start------------------------------------------------------------
var menu1=new Array()
menu1[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu1[1]='<a href="sales_Orbus.html">Orbus</a>'
menu1[2]='<a href="sales_display_one.html">Display one</a>'
menu1[3]='<a href="sales_entasi.html">Entasi</a>'


//menu 2
var menu2=new Array()
menu2[0]='<a href="sales_banner_nimlok.html">Nimlok</a>'
menu2[1]='<a href="sales_banner_moss.html">Moss</a>'


//menu 3
var menu3=new Array()
menu3[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu3[1]='<a href="sales_Orbus.html">Orbus</a>'
menu3[2]='<a href="sales_display_one.html">Display one</a>'
menu3[3]='<a href="sales_entasi.html">Entasi</a>'

//menu 4
var menu4=new Array()
menu4[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu4[1]='<a href="sales_Orbus.html">Orbus</a>'
menu4[2]='<a href="sales_display_one.html">Display one</a>'
menu4[3]='<a href="sales_entasi.html">Entasi</a>'

//menu 5
var menu5=new Array()
menu5[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu5[1]='<a href="sales_Orbus.html">Orbus</a>'
menu5[2]='<a href="sales_display_one.html">Display one</a>'
menu5[3]='<a href="sales_entasi.html">Entasi</a>'

//menu 6
var menu6=new Array()
menu6[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu6[1]='<a href="sales_Orbus.html">Orbus</a>'
menu6[2]='<a href="sales_display_one.html">Display one</a>'
menu6[3]='<a href="sales_entasi.html">Entasi</a>'

//menu 7
var menu7=new Array()
menu7[0]='<a href="sales_nimlok.html">Nimlok</a>'
menu7[1]='<a href="sales_Orbus.html">Orbus</a>'
menu7[2]='<a href="sales_display_one.html">Display one</a>'
menu7[3]='<a href="sales_entasi.html">Entasi</a>'



var menuwidth='150px'
var menubgcolor='#4c4d4f'
var disappeardelay=250
var hidemenu_onclick="yes"



var ie4=document.all
var ns6=document.getElementById&&!document.all

if (ie4||ns6)
document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';backg round-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)"></div>')

function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}


function showhide(obj, e, visible, hidden, menuwidth){
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top="-500px"
if (menuwidth!=""){
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
}
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
obj.visibility=visible
else if (e.type=="click")
obj.visibility=hidden
}

function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWid th-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeig ht-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeigh t
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){
edgeoffset=dropmenuobj.contentmeasure+obj.offsetHe ight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.y+obj.offsetHeight-topedge
}
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
populatemenu(menucontents)

if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)

dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
}

return clickreturnvalue()
}

function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}

function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}

function dynamichide(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu()
}

function hidemenu(e){
if (typeof dropmenuobj!="undefined"){
if (ie4||ns6)
dropmenuobj.style.visibility="hidden"
}
}

function delayhidemenu(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay)
}

function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
}

if (hidemenu_onclick=="yes")
document.onclick=hidemenu
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_nbGroup(event, grpName) { //v6.0
var i,img,nbArr,args=MM_nbGroup.arguments;
if (event == "init" && args.length > 2) {
if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array();
nbArr[nbArr.length] = img;
for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = args[i+1];
nbArr[nbArr.length] = img;
} }
} else if (event == "over") {
document.MM_nbOver = nbArr = new Array();
for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up);
nbArr[nbArr.length] = img;
}
} else if (event == "out" ) {
for (i=0; i < document.MM_nbOver.length; i++) {
img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; }
} else if (event == "down") {
nbArr = document[grpName];
if (nbArr)
for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; }
document[grpName] = nbArr = new Array();
for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
nbArr[nbArr.length] = img;
} }
}
</script>







</head>

<body onload="MM_preloadImages('../images_2.10/rentalb.jpg','../images_2.10/eventsb.jpg','../images_2.10/mobileb.jpg','../images_2.10/musb.jpg','../images_2.10/graphicsb.jpg')">








<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu1, '100px')" onmouseout="delayhidemenu()"><img name="custom_exhibit" src="../images_2.10/exhibits.jpg" width="129" height="17" border="0" id="exhibit" alt="" /></a></td>


<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs2" alt="" /></td>


<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu2, '100px')" onmouseout="delayhidemenu()"><img name="enviroments" src="../images_2.10/enviroments.jpg" width="128" height="17" border="0" id="custom_exhibit2" alt="" /></a></td>

<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs3" alt="" /></td>

<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu3, '100px')" onmouseout="delayhidemenu()"><img name="museums" src="../images_2.10/mus.jpg" width="129" height="17" border="0" id="museums" alt="" /></a></td>

<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs4" alt="" /></td>

<td colspan="6"><a href="displaycraft_change_v12.php" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu4, '100px')" onmouseout="delayhidemenu()"><img name="graphic" src="../images_2.10/graphics.jpg" width="128" height="17" border="0" id="custom_exhibit2" alt="" /></a></td>

<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs6" alt="" /></td>

<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu5, '100px')" onmouseout="delayhidemenu()"><img name="rental" src="../images_2.10/rental.jpg" width="129" height="17" border="0" id="rental" alt="" /></a></td>

<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs6" alt="" /></td>


<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu6, '100px')" onmouseout="delayhidemenu()"><img name="events" src="../images_2.10/events.jpg" width="128" height="17" border="0" id="custom_exhibit2" alt="" /></a></td>

<td><img name="exhibitsb" src="../images_2.10/gs2.jpg" width="1" height="17" border="0" id="gs6" alt="" /></td>


<td colspan="6"><a href="file:///C|/displacraft/sales/l" onclick="return clickreturnvalue()" onmouseover="dropdownmenu(this, event, menu7, '100px')" onmouseout="delayhidemenu()"><img name="mobile" src="../images_2.10/mobile.jpg" width="129" height="17" border="0" id="mobile" alt="" /></a></td>



</body>
</html>
erice is offline  
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 09:29 AM.

 
     

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Inactive Reminders By Icora Web Design