Home | Advertising Info6 USERS CURRENTLY ONLINE   
PowerASP
   Site Search Contact Us Thursday, January 16, 2025  

  Active InfoActive Info  Display List of Info MembersMemberlist  Search The InfoSearch  HelpHelp
  RegisterRegister  LoginLogin
Classic ASP - General
 PowerASP Code Help Area : Classic ASP - General
Subject Info: TARGET in href not working as supposed to A d d  -  P o s tAdd P o s t
Author
Message << Prev Info | Next Info >>
hemmli
Newbie
Newbie


Joined: December/13/2004
Location: Norway
Online Status: Offline
Info: 6
Added: December/13/2004 at 10:50am | IP Logged Quote hemmli

I've stumbled upon a weird behaviour in my site.
The site is ASP VBSCRIPT retrieving data from an Access DB. The site is a work in progress and I am currently trying to make a genuine DB driven menu system using a frameset with a MAIN category menu in one frame and the SUB categories in another frame.

Usually I've only refered to ASP documents using the same frame or window. Therefore never seen the behaviour or problem:

When I retrieve link data from the DB in a standard <a href='page.asp?cat=test' target='MenuFrame'> The page I'm calling is opened IN A NEW window and not within the frame which I specify with the Target command.

The entire site uses ASP documents and not html.
I have never experienced this kind of behaviour before and I am wondering whether this has something to do with ASP or not. Also I get the same behaviour on different browsers like MSIE and Opera.

Any Ideas ?
the website URL is www.graphic.no/def.asp
The Main category is in the TOP frame
and the SUB category is in the Left fram.
Back to Top View hemmli's Profile Search for other info by hemmli Visit hemmli's Homepage
 
hemmli
Newbie
Newbie


Joined: December/13/2004
Location: Norway
Online Status: Offline
Info: 6
Added: December/13/2004 at 11:07am | IP Logged Quote hemmli

OKAY I have worked around this issue, but I am still intersted in your views on the subject.

I solved the problem temporarily by using this little trick:

"<a href='#' onClick='javascript:window.open('" & r(0) & "','MenyFrame')>" & r(0) & "</a>"

Where r(0) is the URL sent from the DB and MenyFrame is the frame I wanted to send the information to.

Back to Top View hemmli's Profile Search for other info by hemmli Visit hemmli's Homepage
 
elija
Newbie
Newbie
Avatar

Joined: September/04/2004
Location: United Kingdom
Online Status: Offline
Info: 8
Added: December/13/2004 at 11:30am | IP Logged Quote elija

You have misnamed your frame as "MenyFrame" (notice the "Y") in your frameset. This will cause a new window to open


Elija


Edited by elija on December/13/2004 at 11:30am


__________________
Programmer - a device for turning coffee into algorithms
Back to Top View elija's Profile Search for other info by elija Visit elija's Homepage
 
hemmli
Newbie
Newbie


Joined: December/13/2004
Location: Norway
Online Status: Offline
Info: 6
Added: December/14/2004 at 7:15am | IP Logged Quote hemmli

Misspelled framename: Nope that was not the problem. Nor was my own solution the best working either. The solution however was very simple indeed.

I went back to the original code using the HREF tag and Target. But in order for the TARGET to work I added the following tag under HEAD:

<base target="FrameNAME">

This seems to do the trick
Back to Top View hemmli's Profile Search for other info by hemmli Visit hemmli's Homepage
 
elija
Newbie
Newbie
Avatar

Joined: September/04/2004
Location: United Kingdom
Online Status: Offline
Info: 8
Added: December/14/2004 at 9:14am | IP Logged Quote elija

---  Copy and Paste from view source of your URL  ---

<frameset rows="111,*" cols="*" frameborder="NO" border="0" framespacing="0">
<frame src="/top.asp" name="topFrame" frameborder="no" scrolling="NO" noresize marginwidth="0" marginheight="0">
<frameset rows="*" cols="148,620,*" framespacing="0" frameborder="NO" border="0">
<frame src="/menu.asp" name="MenyFrame" frameborder="no" scrolling="NO" noresize marginwidth="0" marginheight="0" id="MenyFrame">
    <frame src="/Main.asp" name="Hoved" frameborder="no" noresize marginwidth="0" marginheight="0" id="Hoved">
<frame src="/right.html" name="rightFrame" frameborder="no" scrolling="no" noresize marginwidth="0" marginheight="0" id="rightFrame">
</frameset>
</frameset>

--- End Copy and paste ---

Notice the first frame of the second frameset - name and id are MenyFrame, either change this to MenuFrame or use <a href='page.asp?cat=test' target='MenyFrame'> otherwise it will open in a new window.

Elija


__________________
Programmer - a device for turning coffee into algorithms
Back to Top View elija's Profile Search for other info by elija Visit elija's Homepage
 
hemmli
Newbie
Newbie


Joined: December/13/2004
Location: Norway
Online Status: Offline
Info: 6
Added: December/14/2004 at 10:12am | IP Logged Quote hemmli

Okay, I stand (or sit if you prefer) corrected.
I forgot to specify that the misspelling of the words
menuframe and menyframe are only in my first posting.
And that I have checked my entire site for that error.
And it isn't there.

Could this be some sort of browser cahce problem?
As I recently posted I've gotten it to work now, but
I still have no clue to why it didn't or does work.

Still, thank you for your entusiasm.
Back to Top View hemmli's Profile Search for other info by hemmli Visit hemmli's Homepage
 

Page of 2 Next >>
  A d d  -  P o s tAdd P o s t
Printable version Printable version

Info Jump
You cannot add new info in this area
You cannot add to info in this area
You cannot delete your info in this area
You cannot edit your info in this area
You cannot create polls in this area
You cannot vote in polls in this area

   Active Server Pages Rule The World
Contact Us  
All artwork, design & content contained in this site are Copyright © 1998 - 2025 PowerASP.com and Christopher J. Williams
Banner ads ,other site logos, etc are copyright of their respective companies.
STATS Unless otherwise noted - All Rights Reserved.

Active Server Pages ASP a directory of ASP tutorials applications scripts components and articles for the novice to professional developer. CJWSoft ASPProtect ASPBanner ASPClassifieds www.aspprotect.com, www.cjwsoft.com,www.aspclassifieds.com,www.aspphotogallery.com