Query strings?

Query strings?

Post by echel » Tue, 06 Aug 2002 19:07:35



I was wondering how to make a query string that when called by an
Internet Browser, it will display the required data it is told to do,
e.g. When expample.aspx?hosting is called it will include data into
the expample.aspx page from hosting.aspx

I hope I am explaining this right.
Thanks in advance.

 
 
 

Query strings?

Post by SoTT » Tue, 06 Aug 2002 19:26:17


You should like example.aspx?page=hosting
and then in your code you can find out wich page you want the data from by
doing:
Request.QueryString("page")

in this case it will return "hosting"

Hope this helps


Quote:> I was wondering how to make a query string that when called by an
> Internet Browser, it will display the required data it is told to do,
> e.g. When expample.aspx?hosting is called it will include data into
> the expample.aspx page from hosting.aspx

> I hope I am explaining this right.
> Thanks in advance.


 
 
 

1. asp query string vs. aspx query string?

in asp I could do stuff like...

http://url?<xml>other stuff here<xml>

<script language='javascript'>
Response.ContentType = "text/xml";
var obj_xml_dom = new ActiveXObject("msxml2.domdocument");
obj_xml_dom.async=false;
if (true == obj_xml_dom.loadXML(
Request.QueryString.Item ))
{
Response.write("<xml> some other stuff here!</xml>")
</script>

However in .net we all must change our code to...


<%
Response.ContentType = "text/xml";
var obj_xml_dom = new ActiveXObject("msxml2.domdocument");
obj_xml_dom.async=false;

/* this next line no longer works? */
if (true == obj_xml_dom.loadXML(Request.QueryString.Item ))
{
Response.write("<xml> some other stuff here!</xml>")
%>

But request.querystring is no longer what it once was.  I
don't need it to be a NameValueCollection because my query
string has no keys in it... who ever said you had to have
a key in a query string?  Anyway how do I turn it into a
valid string I can load with a dom?  I'm pretty new to
the .net server side so please advise?

2. Disk Image software

3. How to fill sql query string dynamically in SqlConnection

4. More Help with Bards Tale III

5. query string with an apostrophe ( ' )

6. ANN: Robot News

7. Help Using XMLDocument.load to access a remote XML db source with a query string

8. good place to find OT docs?

9. How to provide query string parameter to page during debug

10. Pass a selection formula in asp.net query string.

11. Problem reading query string

12. SQL query string in VB.NET

13. remove query string form address bar