Solved

CGI AND ASP

Posted on 1998-05-13
6
168 Views
Last Modified: 2013-12-25
I have two file welcome.html and chkpwd.asp
In the first file i have this code:
<FORM METHOD="POST"  ACTION="http//......................./cgi-bin/chkpwd.asp">
<INPUT TYPE="text" SIZE=20 NAME="Utente">
<INPUT TYPE="password" SIZE=20 NAME="password">
<INPUT TYPE="submit"  NAME="Send" VALUE="Procedi">
</FORM>
These parameters will go into stdin and PATH_INFO.
From the second file chkpwd.asp what is the function (like scanf(%s, stringa_input) c language)
to read the values of the parameters from stdin or  PATH_INFO variable ??
0
Comment
Question by:grafiti051398
  • 3
  • 2
6 Comments
 
LVL 5

Expert Comment

by:julio011597
ID: 1828428
Don't know ASP, but usually you read from stdin with fgets() from <stdio.h>, THEN process the read buffer. For env vars instead, you read with getenv() from <stdlib.h>.

HTH, julio
0
 

Author Comment

by:grafiti051398
ID: 1828429
Thanks, but I would like what is the function in ASP language.
0
 
LVL 5

Expert Comment

by:julio011597
ID: 1828430
Oops! i believed ASP was but a protocol... one never stops learning :)

Good luck, julio
0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 

Author Comment

by:grafiti051398
ID: 1828431
Edited text of question
0
 
LVL 28

Accepted Solution

by:
sybe earned 200 total points
ID: 1828432
Request.ServerVariables("PATH_INFO")

I use this ASP script often to test request variables from a form:
It shows ServerVariables, Form and Querystring variables


<TABLE BORDER=1 WIDTH=100%>

<TR>
      <TH COLSPAN=2> HTTP / Server Variables</TH>
</TR>


<TR>
      <TD><B>Server Variable</B></TD>
      <TD><B>Value</B></TD>
</TR>
      <% For Each name In Request.ServerVariables %>
<TR>
      <TD> <%= name %> </TD>
      <TD> <%= Request.ServerVariables(name) %> </TD>
</TR>

<% Next %>
</TABLE>

<P>&nbsp;</P>

<TABLE BORDER=1 WIDTH=100%>

<TR>
      <TH COLSPAN=2> Querystring</TH>
</TR>

<TR>
      <TD><B>Name</B></TD>
      <TD><B>Value</B></TD>
</TR>
      <% For Each name In Request.Querystring %>
<TR>
      <TD> <%= name %> </TD>
      <TD> <%= Request.Querystring(name) %> </TD>
</TR>

<% Next %>
</TABLE>


<P>&nbsp;</P>

<TABLE BORDER=1 WIDTH=100%>

<TR>
      <TH COLSPAN=2> Form Data</TH>
</TR>

<TR>
      <TD><B>Name</B></TD>
      <TD><B>Value</B></TD>
</TR>
      <% For Each name In Request.Form %>
<TR>
      <TD> <%= name %> </TD>
      <TD> <%= Request.Form(name) %> </TD>
</TR>

<% Next %>
</TABLE>

0
 

Author Comment

by:grafiti051398
ID: 1828433
Sybe, I have resolved my problem testing my code with your code.

Thanks Sybe
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

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

Suggested Solutions

Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

776 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