Welcome Guest ( Log In | Register)



 
Reply to this topicStart new topic
> Getting A Link From Dropdownmenu In A Layer ?!1
kvarnerexpress
post Jan 27 2006, 02:06 PM
Post #1


Super Member
*********

Group: Members
Posts: 407
Joined: 13-December 04
Member No.: 2,696



I have been wrestling with this issue some time now and can't figure it out.
I have a dropdownmenu with some data (pulled from a database using php, but that's unimportant).
Now when one selects a item form that menu I want the page to which that item links to be opened in a layer.

There are 2 things Going on:

1. I use javascripts include('layer','content.php'); function to load a page in a layer.
Works like a charme.

2. the dropdown menu CAN open the page to which the items link in the same page using:

<SELECT NAME="SelectURL" onChange="document.location.href=
document.nav.SelectURL.options[document.nav.SelectURL.selectedIndex].value">

Works great too.


WHAT I DID TO COMBINE THIS:

<SELECT NAME="albums" id="albums" class="table" onChange="
include('thumbnaillayer', 'document.nav.SelectURL.options[document.nav.SelectURL.selectedIndex].value ');
">

seemed logical to me.

only what happens in real is this error:

Not Found
The requested URL /ghbstoernooi/document.nav.SelectURL.options[document.nav.SelectURL.selectedIndex].value was not found on this server.


--------------------------------------------------------------------------------

Apache/1.3.29 Server at localhost Port 80

What is going on here?
I can't be too far away form the solution since steps 1 and 2 work great. But I need a little push in the right direction....

Please, any help would be awesome! Thanks a lot in advance!
Go to the top of the page
 
+Quote Post
kvkv
post Feb 5 2006, 06:17 AM
Post #2


Newbie [Level 3]
***

Group: Members
Posts: 40
Joined: 29-January 06
Member No.: 17,841



What you are trying to do is run a server side code in the client. "include" is server side (php) code. Whatever is executed on "onchange" of dropdown *has* to be client side code since your browser doesn't know about server code. That doesn't work. if you want to include something, you can redirect browser to a pageinclude.php script with a parameter (depending on the selection of dropdown) and in your php, depending on parameter, you can include respective file.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Need Help With My Database [resolved](6)
  2. Dreamweaver Cs3: How To Link Content To Layers/apdivs(5)
  3. Div Layer Help(15)
  4. Flash Problem(9)
  5. The Link Building Nightmare…(3)
  6. Suitable Forum(0)
  7. Subnets Behind Layer 2 Switches(1)
  8. Broken Link!(4)
  9. Image Hosting Link On My Website?(2)
  10. Link Between Depression And Learning Disabilities?(3)
  11. ZELDA and LINK(30)
  12. Table/cell Link?(10)
  13. A New Free Game Mo Siang Online, Who Know The Link?(4)
  14. Free Web Hosting: (legend Link) [screened] [approved](2)
  15. Joomla 1.5.2 Broken Link?(3)
  1. Link-building Services In 3 Languages(1)
  2. How To Use A Link To Call Function In Php?(8)
  3. Text-link-ads(0)
  4. Trap17 Link Exchange Script Introduced(26)
  5. Link Image Css Bug In Firefox(7)
  6. American Troops At Their Worst. Videos Of What Our Soldiers Who Represent The Usa Are Doing In Other Countries.(10)
  7. Is Link Right Handed Or Left Handed(7)
  8. Toolbar Not Working (adobe Dreamweaver)(7)
  9. Server Status Link Doesn't Work(1)
  10. Microsoft Launches Internet Explorer 7!(25)
  11. Domain Name Hyperlinking Question?(2)
  12. 7 Layer Salad(3)
  13. Link Exchange(2)
  14. Target Links To A Div Layer(22)
  15. How Do I Add A Paypal Link On My Page?(2)


 



- Lo-Fi Version Time is now: 26th July 2008 - 06:29 AM