473,374 Members | 1,651 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,374 software developers and data experts.

DNS lookup...

I have a web page that queries a database returning a recordset containing a
whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely clueless
how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.

Any suggestions most welcome

Thanks

Griff
Jul 19 '05 #1
10 7794
I don't think you can do this directely then....
BUT.... perhaps you could do the nslookup piped to a text file? Beyond that
you will need an additional component because I dont believe there is any
builtin method for this in asp/vbscript.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2***************@TK2MSFTNGP12.phx.gbl...
I have a web page that queries a database returning a recordset containing a whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely clueless
how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.

Any suggestions most welcome

Thanks

Griff

Jul 19 '05 #2
perhaps you could do the nslookup piped to a text file?

That would be sufficient....any ideas how to do that part?

Thanks

Griff
Jul 19 '05 #3
"nslookup www.darkfalz.com > c:\yourFile.txt"

Run this in a command call from vbscript
(http://www.darkfalz.com/1100)
--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2******************@TK2MSFTNGP12.phx.gbl...
perhaps you could do the nslookup piped to a text file?

That would be sufficient....any ideas how to do that part?

Thanks

Griff

Jul 19 '05 #4
if the data set is updated on a schedule you could create a scheduled job to
nslookup this list of IPs. How is your database updated?

"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2******************@TK2MSFTNGP12.phx.gbl...
perhaps you could do the nslookup piped to a text file?

That would be sufficient....any ideas how to do that part?

Thanks

Griff

Jul 19 '05 #5
It's a very small database that's just used for ADMIN purposes.

However, we're in the process of moving many of our customers from one
server to another. We therefore are requesting DNS record changes by the
handfull on a daily basis.

What we don't want to do is to have a field that contains this information
because when would we change the value? If we change the IP address when we
request the DNS change then the value will be out-of-date until the DNS
record has filtered through. The ideal situation would be to dynamically
update the value every time the record is looked at, thus ensuring that
we're using the "current" value visible to the whole world.

Griff
Jul 19 '05 #6
Hi GriffithsJ,

Use Windows Scripting Host, so you can execute prompt comands by asp
directly or by .BAT or .CMD file(batch files).
take a look here:
http://www.aspfaq.com/show.asp?id=2059

good luck,

--

««««««««»»»»»»»»»»»»»»
Vlmar Brazão de Oliveira
Desenvolvimento Web
HI-TEC
"GriffithsJ" <Gr************@hotmail.com> escreveu na mensagem
news:#C*************@TK2MSFTNGP12.phx.gbl...
I have a web page that queries a database returning a recordset containing a whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely clueless
how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.

Any suggestions most welcome

Thanks

Griff

Jul 19 '05 #7
"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2***************@TK2MSFTNGP12.phx.gbl...
I have a web page that queries a database returning a recordset containing a whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely clueless
how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.


<%
Set objWShell = Server.CreateObject("WScript.Shell")
Set objCmd = objWShell.Exec("nslookup yourip")
strPResult = objCmd.StdOut.Readall()
set objCmd = nothing: Set objWShell = nothing
response.write replace(strPResult,vbCrLf,"<br>")
%>

--
Tom Kaminski IIS MVP
http://www.iistoolshed.com/ - tools, scripts, and utilities for running IIS
http://mvp.support.microsoft.com/
http://www.microsoft.com/windowsserv...y/centers/iis/

Jul 19 '05 #8
http://www.asp101.com/articles/jason...ns/default.asp
"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2***************@TK2MSFTNGP12.phx.gbl...
I have a web page that queries a database returning a recordset containing a whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely clueless
how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.

Any suggestions most welcome

Thanks

Griff

Jul 19 '05 #9
BP
Hi,
I just found a dll that allows just that within scripting.
have a look, it's free

ddns: http://www.dastrup.com/html/ddns.asp

Brgds
Bruno
"TomB" <sh*****@hotmailXXX.com> wrote in message
news:uR**************@tk2msftngp13.phx.gbl...
http://www.asp101.com/articles/jason...ns/default.asp
"GriffithsJ" <Gr************@hotmail.com> wrote in message
news:%2***************@TK2MSFTNGP12.phx.gbl...
I have a web page that queries a database returning a recordset containing
a
whole series of URLs (host headers).

I want to display these in a table with one of the columns holding the
current I.P. address for each URL. I know how to get a list of these IP
addresses from the cmd prompt using "nslookup" but I'm absolutely

clueless how to get hold of these values in my ASP page.

I'm limited to the fact that this must be only ASP (VBScript, not .NET),
i.e. I can't call install any components.

Any suggestions most welcome

Thanks

Griff


Jul 19 '05 #10
Fantastic - I'll have a look at that.

Thanks

Griff
Jul 19 '05 #11

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

Similar topics

1
by: Srini | last post by:
I was reading the "Exceptional C++" of Herb Sutter. In an example, he mentions the following. // In some library header: namespace N { class C{}; } int operator+(int i, N::C) { return i+1; }...
2
by: CoreyWhite | last post by:
The future of computer architecture will use lookup tables. Currently computer processor speed outweighs the benefits of using computer memory for lookup tables, except in some cases. As computer...
8
by: Lucas Lemmens | last post by:
Dear pythonians, I've been reading/thinking about the famous function call speedup trick where you use a function in the local context to represent a "remoter" function to speed up the 'function...
9
by: Koen | last post by:
Hi all, My application uses a lot of lookup tables. I've splitted the frontend (forms, reports, etc) from the backend (data). The database has around 10 different users. The values in the...
3
by: my-wings | last post by:
I've been reading about how evil Lookup fields in tables are, but I've got to be missing something really basic. I know this subject has been covered before, because I've just spent an hour or two...
1
by: Zachary Turner | last post by:
I want to make a Lookup Field based on another Lookup field. In other words, I have this table A with two fields: ID and Name, where ID is an Autonumber and Name is a friendly name. Then I have a...
3
by: google | last post by:
I have a database with four table. In one of the tables, I use about five lookup fields to get populate their dropdown list. I have read that lookup fields are really bad and may cause problems...
13
by: paul.joseph.davis | last post by:
Hi, I've just had my first encounter with two-phase lookup and I'm scratching my head a bit. The idea behind two phase look up is pretty easy to understand, but I have a case that fails to...
11
by: ianoble | last post by:
I've been trying to piece together various code snippets to create a lookup table inside my xslt without the need for a supplemental xml file. Here is what I have so far. As of now, it does not...
1
by: joeino | last post by:
I want to do a lookup query and append the record to a history table before editing the data. I created a macro to run the lookup query to append the record to history and it works fine. I did the...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.