Solved

classic asp:  retrieve server side content from another asp page

Posted on 2013-02-04
1
456 Views
Last Modified: 2013-02-06
program-directors.asp  creates html, option tags
How do I code this so that the results of program-directors.asp
are returned in the function?



if  id =  "vroutpln_progdire_1" then
      
         fld = "<select id=""" & id  &  """ name=""" &  id &  """>"
          url = "/LLIUHRFM/jx/program-directors.asp"

          set xmlhttp = CreateObject("MSXML2.ServerXMLHTTP")
          xmlhttp.open "GET", url, false
          'xmlhttp.send "" 
          'fld = fld &  xmlhttp.responseText
          'set xmlhttp = nothing

         fld = fld & "</select>"

     
end if  'Select Control No 005
0
Comment
Question by:KeithMcElroy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 35

Accepted Solution

by:
Robert Schutt earned 500 total points
ID: 38854166
If I understand it correctly, what you need to do is provide a full url, for example like this:
xmlhttp.open "GET", "http://" & Request.ServerVariables("SERVER_NAME") & url, false

Open in new window

This can be made more dynamic if you need to call a function with different url's. In some cases (but I think not in your case) you would need to check for https and include the current path if the url doesn't start with a "/".

EDIT: another option could be:
xmlhttp.open "GET", "http://localhost" & url, false

Open in new window

0

Featured Post

[Webinar] How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT

Question has a verified solution.

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

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

734 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