Data visualization with SAS programming

hyperlinks to other graphs within same html output

Reply
Contributor
Posts: 47

hyperlinks to other graphs within same html output

Hi all,

I have about 15 graphs in one html file. What I want to do is have a list of names of those graphs and be able to instantly scroll down to those graphs. Rob allison had done something similar with linking to other websites:
http://robslink.com/SAS/democd23/overlib.htm
http://robslink.com/SAS/democd23/overlib_info.htm

but what about linking to graphs within the same file?

Thanks in advance,
Sachin
SAS Super FREQ
Posts: 8,818

Re: hyperlinks to other graphs within same html output

Hi:
Have you looked at FRAME=, BODY= and CONTENTS= options with ODS HTML -- that would make links that pointed to ALL the output created within 1 ODS HTML step. Something similar to this:
[pre]
ods html path='' (url=none)
body='body.html'
contents='toc.html'
frame='frm.html' style=sasweb;
... one step or more than one step ...

ods html close;
[/pre]

Then, if you open the FRM.HTML file, you should see links to all the output that was created, so whether you had 1 step or 20 steps in your ODS HTML "sandwich" there would be a navigation link on the left side that would contain a clickable link to a named anchor that would display on the right-hand side of the frame when you clicked on the link. Even if you use the NEWFILE= option, the FRAME= and CONTENTS= links will contain the correct pointers.

cynthia
SAS Employee
Posts: 980

Re: hyperlinks to other graphs within same html output

To link to graphs in the same html file/webpage, you can use html 'anchors'.

Here is an example...

http://robslink.com/SAS/democd23/anchor.htm
http://robslink.com/SAS/democd23/anchor_info.htm

In this case, each bar in the bar chart drills-down to an html anchor for that state-map lower in the same webpage. Similarly, you could use a table/list instead of a bar chart.
Ask a Question
Discussion stats
  • 2 replies
  • 142 views
  • 0 likes
  • 3 in conversation