473,563 Members | 2,857 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

document.locati on.href not working!?!?!?!

can someone PLEASEEEEEEEEEE tell me why this isn't working???

-------------------- function ------------------------

function goBlank(){

newlocation = "blank.asp" ;
top.window.docu ment.location.h ref=newlocation ;
return true;
}

-------------------------- html ------------------

<td><div align="center" ><a href="javascrip t:;" ><span
class="popupBut ton" style="text-decoration: none; line-height: 24px;"
onClick="checki n();" >&nbsp;&nbsp;&n bsp;Check In
&nbsp;&nbsp;&nb sp;</span></a></div></td>

I have tried every conceivable combination and it just wont work.. I
can see the status bar flash, like its loading a new page, but the page
doesnt change..

thanks in advance...

Jul 23 '05 #1
3 23279
Lee
Brian said:

can someone PLEASEEEEEEEEEE tell me why this isn't working???

-------------------- function ------------------------

function goBlank(){

newlocation = "blank.asp" ;
top.window.doc ument.location. href=newlocatio n ;
return true;
}

-------------------------- html ------------------

<td><div align="center" ><a href="javascrip t:;" ><span
class="popupBu tton" style="text-decoration: none; line-height: 24px;"
onClick="check in();" >&nbsp;&nbsp;&n bsp;Check In
&nbsp;&nbsp;&n bsp;</span></a></div></td>

I have tried every conceivable combination and it just wont work.. I
can see the status bar flash, like its loading a new page, but the page
doesnt change..


You haven't showed a function named checkin().
You seem to be abusing an <a> tag just to get the pointer icon.
I tend not to trust relative pathnames.

Jul 23 '05 #2
sorry.. that was the wrong link.... here is the correct one...
----------------------------------------------------------------------------------

<div align="right">< span class="popupBut ton" style="text-decoration:
none; line-height: 24px;" onClick="goBlan k();" >Close
Window</span></div>
-----------------------------------------------------------------------------------------------------------
I dont know why i have the <a> tag there.. I'm using CSS to create the
hand. i just removed it.. I did try absolute paths as well.. I also
tried, "document.locat ion.href" and "window.locatio n.href" and
"self.location. href".. I tried putting it directly in the <span tag and
creating this function... i just dont get it..

Jul 23 '05 #3
LOL.. Thank you.. you just helped me answer it.. I took the <a> tag out
and it worked.. that is weird.. I remember I had tried putting the
onClick event in the <a> tag and it didnt work.. I guess i just kept
the <a> tag there.. thanks for your help..

Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
8538
by: Robert Oschler | last post by:
I have a comparison web page that has several iframes that contain documents from external domain web sites. Some of the web sites are "trusted". If they want to change the top level document location (document.location.href) via Javascript or using "_TOP" as the target for a SUBMIT operation, etc., then I want to allow it. The other web...
1
1347
by: kurt | last post by:
greetings, I'm working on a bookmarklet that needs to overwrite the current document with a frameset where the src of one of the frames is the current URL. What I've come up with works in Mozilla (Firefox 1.0pr). But in IE6, though View Source shows that the new frameset is there with the correct URL inserted, nothing displays. It's a white...
8
8207
by: Phil Powell | last post by:
if (document.location.href.indexOf('?') >= 0) document.location.href = document.location.href.substring(0, document.location.href.indexOf('?')); if (document.location.href.indexOf('#') >= 0) { document.location.href = document.location.href.substring(0, document.location.href.indexOf('#')) + '?' + newUrl; } else { document.location.href =...
2
2200
by: Muffinman | last post by:
Hi, I want to split the result from window.frames.document.location;, this in order to find out which page is currently opened in the specific frame. When I do it like this: var source = window.frames.document.location; // var source = "W3Schools is great!"; index_source = source.split('/');
3
3587
by: Paul Thompson | last post by:
I am working with a special tool which pre-processes the page. Using document.write, I am composing the page while it is loading, so I need to force a reprocess of the page AFTER the page loads. Is there some way to do that? That is, I want the browser to essentially act as if the composed page was the original page. Here is a brief...
2
41480
by: yogesh.bhardwaj | last post by:
Hello all I am trying to modify the link URL when a user clicks on the link. Following is the code: <a onClick="document.location.href=modifyURL(this.href);" href="SOME_DYNAMIC_URL" %>Link</a> The javascript function, modifyURL(href), works fine and returns the desired URL, but for some reason, the value of 'href' is not getting
9
36716
by: alu | last post by:
Could someone explain the discrepancies within and between the stated definitions / usage of 'document.location' , 'document.URL' vs. their actual functionality? Should they be read-only when in fact they are not? Is 'document.URL' also deprecated, and should therefore never be used? What is the last word re: the proper syntax for returning...
1
2166
by: captainwin | last post by:
Here's the problem: - Website is ASP.NET 1.0 - Server is Windows Server 2003 - Browser is IE 6/7 - Client requests a mail merged MS Word 97 - 2003 document on the website, and the document gets created on the server. - Need to send the document to the client browser and delete the file from the server. Previously, the web application...
0
7583
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
1
7638
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7948
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6250
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3642
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2082
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1198
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.