Solved

Neet to pass in the IP address of the HTTP server to my applet.

Posted on 2001-07-06
13
200 Views
Last Modified: 2012-05-04
I do not want to hard code the IP address of the HTTP server into my html page. How can I provide this value dynamically?
0
Comment
Question by:dhymes
  • 4
  • 3
  • 2
  • +3
13 Comments
 
LVL 18

Accepted Solution

by:
bruno earned 25 total points
ID: 6260269
Are you using ASP?


<%=request.servervariables("REMOTE_HOST")%>


BRUNO
0
 
LVL 22

Expert Comment

by:CJ_S
ID: 6262284
Why do you need that? Why don't you just use relative paths?

<img src='images/myimage.gif'>

Regards,
CJ
0
 
LVL 2

Author Comment

by:dhymes
ID: 6262545
What would a relative path have to do with obtaining the IP address of the http server? Anyway, it is looking like this can't be done with straight html.
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 5

Expert Comment

by:aryumin
ID: 6264282
If you can use SSI directives in your html pages, use
<!-- #echo var="LOCAL_ADDR" -->
0
 
LVL 18

Expert Comment

by:bruno
ID: 6265180
>>. How can I provide this
value dynamically?


>>Anyway, it is
looking like this can't be done with straight html.



those two things contradict.  I provided you a way to do it dynamically, which is what you asked for.  

If you want a way to do it with NO server side scripting language, or DHTML, that will not be possible I don't think.....


BRUNO

0
 
LVL 2

Author Comment

by:dhymes
ID: 6267327
I was hoping that I would not need any server-side scripting tools, but since HTP only passes static pages I guess scripting would be the only way.

So now the question becomes, does IIS provide server-side scripting (ASP) by default or will I need to install or setup additonal software in additon to IIS?
0
 
LVL 2

Author Comment

by:dhymes
ID: 6267336
I was hoping that I would not need any server-side scripting tools, but since HTP only passes static pages I guess scripting would be the only way.

So now the question becomes, does IIS provide server-side scripting (ASP) by default or will I need to install or setup additonal software in additon to IIS?
0
 
LVL 5

Expert Comment

by:aryumin
ID: 6267944
IIS5 (Windows 2000) does, for NT 4 you need to install NT Option Pack.
If you have IIS3 (Windows NT4 + SP3 or above) you may use SSI directives without any upgrade.
Open regedit, go to
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC\Parameters
and check the following:
1. The ServerSideIncludesEnabled key exists and set to 1 (REG_DWORD)
2. The ServerSideIncludesExtension key exists and set to .stm
For enable SSI directives rename your file to .stm or change the value of a corresponding key in registry.
0
 
LVL 18

Expert Comment

by:bruno
ID: 6269239
more info on the way that aryumin proposed...

http://www.bignosebird.com/sdocs/echo.shtml


BRUNO
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 6537478
To close this out, I will be making a recommendation to CS
in about a week.  I would appreciate any comments from the
participants on how it should be disposed of.

Cd&
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 6616285
It is time to clean this abandoned question up.  

I am putting it on a clean up list for CS.

<recommendation>
split brunobear and aryumin

</recommendation>

If anyone participating in the Q disagrees with the recommendation,
please leave a comment for the mods.

Cd&
0
 
LVL 1

Expert Comment

by:Computer101
ID: 6616677
Points split for a split between experts.

aryumin, a question for you in this topic area.

Thank you
Computer101
Community Support Moderator
0
 
LVL 18

Expert Comment

by:bruno
ID: 6617053
thank you.  :-)
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Browser Chrome downloads colored link 5 48
Scroll 5 news at a time. 4 33
html Uncheck Checkbox 2 25
Set time on Session (ASP) 14 23
This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question