473,545 Members | 1,878 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Inside Anchors

Now I have a question myself :)

I am working on a website for a Hotel and on the first page we have a
flash movie that shows the latest news items. The news items are
retrieved from the database and shown in the movie.
The news items do all have a summary and some of them can have a more
detailed text.

If there is detailed text available I want to open the detailed text of
the news item, after clicking the item in the flash movie. This is
working without problems.

But if there is no detailed text I want to jump to the list with news
items and then jump to that specific news item with the anchor.

An example url for linking to the news-item is:

http://www.example.com/index2.php?p=...&language=NL#3
(note: the target of this link = "_top")

index2.php is the frameset containing a header, a left navigation and
content frame. All parameters in this URL are passed on into the file
which is loaded in the content frame.

news is the news.php file which is included into the content.php file in
the content frame. This file has all parameters available.

The news.php has a <a name="3"></a> just before the corresponding
news-item, but I can't get it to work.

The strange thing however is that if I use the anchored link in the
document itself, it is working. (on the top of the list with news-items
there are all hyperlinks in the style:

http://www.example.com/content.php?p...&language=NL#3
And this hyperlink is working (document is opened in the same frame)

Has it to do with the fact that the frameset is called (because of
refresh navigational items), even if the parameters are all passed on or
am I missing something trivial?

Thanks....

Mark
Jul 17 '05 #1
1 2432
In reply to my own problem (or should I say challenge :P), which I have
also been able to solve, hereby my solution.

This was some lack of thinking on my behalf, because I should have known
that you can't use an #anchor as a parameter and give that to a frameset
where three other documents are requested. So the anchor already is lost
there. So I added another document, which is included in the frameset to
a PHP parameter and inserted a prenews document which retrieves all the
parameters (all parameters are passed on in this document) and then a
javascript document.locati on.replace('url ') will be executed with of
course the url rewritten with the #anchor added. Because I am now in the
same frame of the frameset, the document jumps to the correct anchor
inside the document

Mark

Mark Kuiphuis wrote:
Now I have a question myself :)

I am working on a website for a Hotel and on the first page we have a
flash movie that shows the latest news items. The news items are
retrieved from the database and shown in the movie.
The news items do all have a summary and some of them can have a more
detailed text.

If there is detailed text available I want to open the detailed text of
the news item, after clicking the item in the flash movie. This is
working without problems.

But if there is no detailed text I want to jump to the list with news
items and then jump to that specific news item with the anchor.

An example url for linking to the news-item is:

http://www.example.com/index2.php?p=...&language=NL#3

(note: the target of this link = "_top")

index2.php is the frameset containing a header, a left navigation and
content frame. All parameters in this URL are passed on into the file
which is loaded in the content frame.

news is the news.php file which is included into the content.php file in
the content frame. This file has all parameters available.

The news.php has a <a name="3"></a> just before the corresponding
news-item, but I can't get it to work.

The strange thing however is that if I use the anchored link in the
document itself, it is working. (on the top of the list with news-items
there are all hyperlinks in the style:

http://www.example.com/content.php?p...&language=NL#3

And this hyperlink is working (document is opened in the same frame)

Has it to do with the fact that the frameset is called (because of
refresh navigational items), even if the parameters are all passed on or
am I missing something trivial?

Thanks....

Mark

Jul 17 '05 #2

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

Similar topics

7
2315
by: Ben Wilson | last post by:
To anyone who can help me, you have my thanks in advance. I am implementing a "301 Moved Permanently" redirect in my website due to a change of our domain names. Unfortunately, I am having a problem with reconstructing the target "Location" http header because I'm missing just one thing. My links look as follows: ...
1
1276
by: Peter Jakobi | last post by:
Hello, I want to place two lines relative to another. The problem is, that these two lines are in different groups. Is there an possibility to set the x and y values of the second line with the values of the first line + an offset. Something like that for example:
5
7566
by: metalseb | last post by:
Hi folks I want to implement a full CSS navbar on the top of my page. Basically, this is a DIV with links on <li> tags shown in inline display. Things are going right, but if I want to show a dashed border around the links on hover, the li elements move horizontally. Hovering on the first element shift the two remaining ones to the right,...
2
1881
by: learner | last post by:
Hi, A document has many Anchors. I want to take a particular action only if some particular anchors are clicked. I mean if some anchors are clicked, i want an alert box to pop up with ok and cancel. and if ok is clicked i have to view that link, if cancel, then it should not open that link. How to do this?
21
2435
by: adrian suri | last post by:
Hi just started to experement with styleshhets, and have defined hover a:hover { Color : red; Text-decoration : none; Border-top-width : medium; Border-right-width : medium;
3
4758
by: ryan.mclean | last post by:
Hi all, I hope somebody here can help me, I am attempting to obtain a reference to the anchors inside of a table. Here is what I have: table = document.getElementById(a_strTableId); for(var i = 0; i < table.rows.length; i++) { for(var j = 0; j < table.rows.cells.length; j++) { a = table.rows.cells.getElementsByTagName("A")...
0
1038
by: udit_handa | last post by:
I am creating a scheduler using tables and Adding server side html Anchors in a page. As long as i click other buttons created at design time the viewstate is maintained but these server side dynamic anchors are unable to maintain viewstate.Can anyone suggest me on how to work with this. Thanx.
12
2355
by: Rich | last post by:
Strangely, on-page anchors will work on MSIE, but not on Netscape7.2 or Firefox1.5. All anchors are numbers e.g. <a href="#21">TOPIC</a> supposed to connect down to <a name="#21>beginning of text</a> . Could be further complicated by the ASP and SQL designation of URL. like: http://sampleURL.org/FAQs.asp?FAQMID=11&NumFaq=10&bmode=Main W3C...
3
16539
by: windandwaves | last post by:
does it matter if I write var anchors = document.getElementsByTagName("A"); or var anchors = document.getElementsByTagName("a"); Or is there a better way to catch both <a hrefs and <A HREFS
0
7486
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7416
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
7442
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
7776
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
6001
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...
1
5347
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
4965
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
3473
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
3456
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

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.