SitePoint Sponsor

User Tag List

Results 1 to 11 of 11
  1. #1
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    problem with asp form

    Hi, I have taken over the maintenance of a website and recently we did a redesign. I am not a programmer and this is where I am running into a problem.

    On the website, the original designer created a page that contains an asp form. It allows the HR person at the company to open the form page and add new positions to the website. She opens a page called "jobs_edit.asp" and just fills in the box and hits submit and then the new position appears on the "Current Openings" web page (which is actually "jobopenings.asp" file).

    All the files are on the root folder, except the files that are connected to this form page. These are all in a folder called "/oaknoll". I tried to do a test run to see if I could enter a description for one of the positions. but I get an error message after I hit the submit button. I am afraid to mess with the code as I don't want to screw the whole thing up.

    Here are the folders and files in the "Oaknoll" folder:

    Folder: Admin - file "jobsupdate.asp"
    Folder: Data - file "oaknoll.mdb
    Folder: Include files: "ADOVBS.INC", "DSN.asp", "validator.asp"
    file: aspbackup.asp
    file: jobopenings.asp
    file: jobs_edit.asp
    file: test.asp



    Could someone take a look and tell me why it is not working correctly? Any suggestions?

    Here is the website: http://www.oaknoll.com


    The job postings appear on a page under the "EMPLOYMENT" tab called "current positions".

    Here is the code from the current positions page:

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <!-- #include virtual="/oaknoll/include/DSN.asp" -->
    
    <%
    
    Response.Expires = 0
    
    function formatJobs (strIn)
    	dim temp
    	If strIn = "" or isnull (strIn) or isempty (strIn) Then
    		temp = "- no current openings</p>"
    	Else
    		temp = "</p><p><blockquote>" & strIn & "</blockquote>"
    	End If
    	formatJobs = temp
    end function
    
    dim cn, rs, sql
    
    'Open and verify connection to DB
    set cn = server.CreateObject("ADODB.Connection")
    cn.Open cnString("/data", "oaknoll.mdb")
    
    sql = "SELECT * FROM jobopenings"
    set rs = cn.Execute(sql)
    
    %>
    
    
    <html lang="en">
    <head>
    <title>Oaknoll - An Adult Retirement Community</title>
    <meta name="Keywords"
     content="oaknoll, iowa city, retirement, elderly, iowa, LifeCare, retirement community, nursing home, apartment, independent living, resident, geriatric, aging, community, retire, retired, elder,  health care">
    <meta name="Description"
     content="Oaknoll is an adult retirement community in Iowa City, Iowa.">
    <meta name="Author" content="Heather Clark for Gazette Communications">
    <meta name="robots" content="index,follow">
    
    
    <!-- include Cycle plugin -->
    
    <!-- include jQuery library -->
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>
    <!-- include Cycle plugin -->
    <script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.latest.js"></script>
    <script type="text/javascript">
    $(document).ready(function() {
        $('.slideshow').cycle({
    		fx: 'fade' // choose your transition type, ex: fade, scrollUp, shuffle, etc...
    	    	
    			});
    
    
    $('#s3').cycle({ 
        fx:    'fade', 
        speed:  5500,
    	cleartype: 1,
    cleartypeNoBg: false,
    height: 'auto',
    containerResize: 0,
    
    timeout: 8000,
    
    sync: 0,
    
    fadeOut:'slow', 
    
    
    
    nowrap: 0,
    randomizeEffects: 0,
    pause: 0
    	
    	
     });
    
    });
    </script>
    
    		
    
    <!--Vertical Slider Navigation javascript - code on external page-->    
        
    <script type="text/javascript" src="js/external_navigation_menu_javascript.js"></script>
    
     <!--endofVerticalSliderNavigationjavascript-->  
    
      
      
    <!--tocorrecttheunsightlyFlashofUnstyledContenthttp://www.bluerobot.com/web/css/fouc.asp-->
    	<script type="text/javascript"> </script>
    	
    
    	
    
    <!--[if lt IE 7]>
    <link rel="stylesheet" type="text/css" href="ie6.css" />
    <![endif]-->
    
    
    <link rel="stylesheet" href="../css/oaknoll_newsite.css" type="text/css" />
    <link rel="stylesheet" href="../css/nav_css.css" type="text/css" />
    <link rel="stylesheet" href="../css/employment.css" type="text/css" />
    
    
    
    </head>
    <body>
    
    <div id="container">
    
     <!--#include virtual="includes/header_asp.asp"-->
    		
          
           
            
    		<div id="main">
             
             
            <div id="box1">
           <div class="slideshow">
    		<img src="../images/sls/nurse_station.jpg" width="400" height="300" alt="Nurses Station" class="first" />
    		
    	   </div> <!--end-of-slideshow-->
            </div><!--end-box-1-->
            
            <div id="box2">                
       	  <div class="buttonbox"><img src="../images/4_special_buttons.jpg" alt="internet buttons" width="181" height="300" border="0" usemap="#Map" />
            <map name="Map" id="Map">
              <area shape="rect" coords="14,8,178,70" href="http://www.touchtown.tv/tv/tv/webshow/tv1.jsp?tag=OAKNOLL_WEB" target="_blank" alt="Link to Oaknoll Announcements" border="none" />
              <area shape="rect" coords="14,86,177,145" href="http://www.facebook.com/Oaknoll?ref=sgm" target="_blank" alt="Link to Oaknoll's Facebook Page" border="none"/>
              <area shape="rect" coords="16,161,172,213" href="http://oaknoll.blogspot.com/" target="_blank" alt="Link to the Oaknoll Blog" />
              <area shape="rect" coords="18,233,175,297" href="../hawkeye.asp" alt="Link to Golden Hawkeye Birthday Club" />
            </map>
       	  </div><!--BUTTONBOX--> 
            </div><!--end-box-2-->
            
      
    
    
    <br>
    
      <h1 style="clear:left;">Current Job Openings...</h1>
              
              <p><b><u>Opportunities in Nursing</u> </b><%= formatJobs(cstr(rs("nursing"))) %> </p>
              <p> <b><u>Opportunities in Food & Nutrition</u></b><%= formatJobs(cstr(rs("food"))) %> </p>
              <p><b><u>Opportunities in Recreation and Social Services</u></b><%= formatJobs(cstr(rs("recreation"))) %> </p>
              <p><b><u>Opportunities in Building and Grounds</u></b><%= formatJobs(cstr(rs("building"))) %> </p>
              <p><b><u>Opportunities in Housekeeping and Laundry</u></b><%= formatJobs(cstr(rs("housekeeping"))) %> </p>
             <p><b><u>Opportunities in Administration</u></b><%= formatJobs(cstr(rs("admin"))) %> </p>
    		  
    		  <p> <b><i>To Apply:</i></b> <br />
                <br />
                <b><i> Click 
                <a href="../pdf/Application_2012_for_website.pdf" target="_blank">here</a> for 
                application.</i></b> </p>
    		  <p align="left">            Print the application and mail the completed form to: </p>
              
              <table width="213" border="0" cellspacing="0" cellpadding="10" align="left">
                <tr> 
                  <td><p>Oaknoll Retirement Residence<br />
                      Attn: Human Resources<br />
                      1 Oaknoll Court<br />
                      Iowa City, Iowa 52246</p></td>
                </tr>
                <tr>
                  <td><p>or fax your application to: <br />
                    (319) 466-3023<br />
                    Attn: Human Resources</p></td>
                </tr>
              </table>
            
      
      </div>
            
            
         <!--#include virtual="includes/menu_asp.asp"-->
    
     
            
    	 <!--#include virtual="includes/footer_asp.asp"-->     
          
    
      
      </div><!--end-of-main-->
    </div><!--end-of-container-->
      
    </div>
    </body>
    </html>

    Here is the code from the "jobs_edit.asp" page:


    Code:
    <?xml version="1.0" encoding="iso-8859-1"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
    <!-- #include virtual="/oaknoll/include/DSN.asp" -->
    
    <head>
    <title>Oaknoll - An Adult Retirement Community</title>
    
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="Keywords"
     content="oaknoll, iowa city, retirement, elderly, iowa, LifeCare, retirement community, nursing home, apartment, independent living, resident, geriatric, aging, community, retire, retired, elder,  health care, assisted living, nursing care">
    <meta name="Description"
     content="Oaknoll is an adult retirement community in Iowa City, Iowa.">
    <meta name="robots" content="index,follow">
    
    <!-- code for employment update form begins here -->
    
    
    <%
    
    Response.Expires = 0
    
    function brtagFixer(strIn)
        
        dim temp
        
    	temp = replace(strIn, "<br>", vbcrlf)
    
        brtagFixer = temp
          
      end function
    
    dim cn, rs, sql
    
    'Open and verify connection to DB
    set cn = server.CreateObject("ADODB.Connection")
    cn.Open cnString("\data", "oaknoll.mdb")
    
    sql = "SELECT * FROM jobopenings"
    set rs = cn.Execute(sql)
    
    %>
    
    
    <!-- code for employment update form ends here -->
    
    
    
    
    
    <!-- include Cycle plugin SLIDESHOW -->
    
    <!-- include jQuery library -->
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>
    <!-- include Cycle plugin -->
    <script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.latest.js"></script>
    <script type="text/javascript">
    $(document).ready(function() {
        $('.slideshow').cycle({
    		fx: 'fade' // choose your transition type, ex: fade, scrollUp, shuffle, etc...
    	    	
    			});
    
    
       
    $('#s3').cycle({ 
        fx:    'fade', 
    	
        speed:  8500,
    	
    	cleartype: 1,
    cleartypeNoBg: false,
    height: 'auto',
    containerResize: 0,
    
    timeout: 2000,
    
    sync: 0,
    
    fadeOut:'slow', 
    
    
    
    nowrap: 0,
    randomizeEffects: 0,
    pause: 2
    	
    
    
    });
    	
    	
    	
    
    
    });
    </script>
    
    
     <!--Vertical Slider Navigation javascript - code on external page-->    
        
    <script type="text/javascript" src="js/external_navigation_menu_javascript.js"></script>
    
     <!--endofVerticalSliderNavigationjavascript-->  
    
    
    		
     
      
    <!--tocorrecttheunsightlyFlashofUnstyledContenthttp://www.bluerobot.com/web/css/fouc.asp-->
    	<script type="text/javascript"> </script>
    	
    
    	
    
    <!--[if lt IE 7]>
    <link rel="stylesheet" type="text/css" href="ie6.css" />
    <![endif]-->
    
    
    <link rel="stylesheet" href="../css/oaknoll_newsite.css" type="text/css" />
    <link rel="stylesheet" href="../css/nav_css.css" type="text/css" />
    
    </head>
    
    <body>
    
    <div id="container">
    
     <!--#include virtual="includes/header_asp.asp"-->
    		
          
           
            
    		<div id="main">
             
             
            <div id="box1">
           <div class="slideshow">
    		<img src="../images/sls/nurse_station.jpg" width="400" height="300" alt="Nurses Station" class="first" />
    		</div> <!--end-of-slideshow-->
            </div><!--end-box-1-->
            
            <div id="box2">                
       	  <div class="buttonbox"><img src="../images/4_special_buttons.jpg" alt="internet buttons" width="181" height="300" border="0" usemap="#Map" />
            <map name="Map" id="Map">
              <area shape="rect" coords="14,8,178,70" href="http://www.touchtown.tv/tv/tv/webshow/tv1.jsp?tag=OAKNOLL_WEB" target="_blank" alt="Link to Oaknoll Announcements" border="none" />
              <area shape="rect" coords="14,86,177,145" href="http://www.facebook.com/Oaknoll?ref=sgm" target="_blank" alt="Link to Oaknoll's Facebook Page" border="none"/>
              <area shape="rect" coords="16,161,172,213" href="http://oaknoll.blogspot.com/" target="_blank" alt="Link to the Oaknoll Blog" />
              <area shape="rect" coords="18,233,175,297" href="hawkeye.asp" alt="Link to Golden Hawkeye Birthday Club" />
            </map>
       	  </div><!--BUTTONBOX--> 
            </div><!--end-box-2-->
            
      
       
       <h1 style="clear:left;">Update Job Opportunites...</h1>
      
      
       <form action="jobsupdate.asp" method="post">
                <p><b><i><font size="+2">Current Job Openings </font></i></b></p>
               
    		    <p><b><u><font size="2">Opportunities in Nursing</font></u></b></p>
                <blockquote> 
                  <textarea name="nursing" cols="50" rows="8"><%= brtagfixer(cstr(rs("nursing"))) %></textarea>
                </blockquote>
                <p> <b><u><font size="2">Opportunities in Food & Nutrition</font></u></b> 
                </p>
                <p> </p>
                <blockquote> 
                  <textarea name="food" cols="50" rows="8"><%= brtagfixer(cstr(rs("food"))) %></textarea>
                </blockquote>
                <p><b><u><font size="2">Opportunities in Recreation</font></u></b> 
                </p>
                <p> </p>
                <blockquote> 
                  <textarea name="recreation" cols="50" rows="8"><%= brtagfixer(cstr(rs("recreation"))) %></textarea>
                </blockquote>
              
    		   <p><b><u><font size="2">Opportunities in Building and Grounds</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="building" cols="50" rows="8"><%= brtagfixer(cstr(rs("building"))) %></textarea>
                </blockquote>
    		  
    		  		  
    		    <p><b><u><font size="2">Opportunities in Housekeeping and Laundry</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="housekeeping" cols="50" rows="8"><%= brtagfixer(cstr(rs("housekeeping"))) %></textarea>
                </blockquote>
               
               			
    			
    			 <p><b><u><font size="2">Opportunities in Administration</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="admin" cols="50" rows="8"><%= brtagfixer(cstr(rs("admin"))) %></textarea>
                </blockquote>
    			
                <p align="center"> 
                  <input type="submit" name="Submit" value="Submit Changes" />
                  &nbsp;&nbsp; 
                  <input type="reset" name="reset" value="Discard Changes" />
                </p>
              </form>
      
      
            
    </div>
            
            
         
          
    
       <!--#include virtual="includes/menu_asp.asp"-->
    
     
            
    	 <!--#include virtual="includes/footer_asp.asp"-->
      
     
      </div><!--end-of-main-->
    </div><!--end-of-container-->
    </body>
    </html>
    When I try to do a test on the jobs_edit.asp form and hit submit, I get an error message. In the browser URL address is a link to http://www.oaknoll.com/oaknoll/jobsupdate.asp. On the server, the jobsupdate.asp file is actually located in the oaknoll file in another file called "admin". http://www.oaknoll.com/oaknoll/admin/jobsupdate.asp.


    Here is the code for the jobsupdate.asp page if it helps....

    Code:
    <!-- #include virtual="oaknoll/include/ADOVBS.INC" -->
    <!-- #include virtual="oaknoll/include/validator.asp" -->
    <!-- #include virtual="oaknoll/include/DSN.asp" -->
    
    <%
    On Error Resume Next
    
    Response.Buffer = true
    Response.Expires = 0
    
    dim cn                                  'Connection object
    dim rs                                  'Recordset objects
    dim sql                                 'Work variable for SQL statement
    
    dim nursing, food, recreation, housekeeping, building, admin
    
    dim updtStatus                          'Return value for success/fail
    dim rowsAffected                        'Number of rows updated by command
    dim updtError
    
    'Initialize variables
    
    nursing			= request("nursing")
    food			= request("food")
    recreation		= request("recreation")
    housekeeping	= request("housekeeping")
    building		= request("building")
    admin			= request("admin")
    
    updtStatus = ""
    
    'Open and verify connection to DB
    set cn = server.CreateObject("ADODB.Connection")
    cn.Open cnString("\data", "oaknoll.mdb")
    if cn.State = adStateClosed then
      Response.Write("ERROR: Database is NOT open")
    end if
    
    sql = ""                                'Clear out temp SQL buffer
    %>
    
    <html><head><title>Updating</title>
    </head>
    <body bgcolor="white" leftMargin="0" link="#006600" text="#000000" topMargin="0" vLink="#800080" MARGINWIDTH="0" MARGINHEIGHT="0">
    
    <font size="2"><b><i>Updating... Please Wait</i></b></font>
    
    <%
    'Build the SQL command for the item we're updating
          sql =       "UPDATE jobopenings"
          sql = sql & "  SET nursing = '"		& stringFixer(nursing) & "',"
          sql = sql & "      food = '"			& stringFixer(food) & "', "
          sql = sql & "      recreation = '"	& stringFixer(recreation) & "', "
          sql = sql & "      housekeeping = '"	& stringFixer(housekeeping) & "', "
    	  sql = sql & "      building = '" 		& stringFixer(building) & "', "
    	  sql = sql & "      admin = '" 		& stringFixer(admin) & "'"
       
       'response.write("sql:<br>" & sql)
       'response.end
      
    'Run the SQL command
      cn.Execute sql, rowsAffected, adExecuteNoRecords
      
      if err.number <> 0 and err.number <> 3021 then
        Response.Write "<b>An error occurred while updating the database.<br>"
        Response.Write "Please notify the system administrator.</b><br>"
        Response.Write "<br>"
        Response.Write "Error Number: " & err.number & "<br>"
        Response.Write "Error Text: <br>"
      
        for errCt = 0 to cn.Errors.Count - 1
          Response.Write cn.Errors.Item(errCt).Description & "<br>"
        next
        
        msg = "An error occurred while updating the database.<br>"
        msg = msg & "  Please notify the system administrator."
        msg = msg & " [" & err.number & "]"
        
        'updtError = true
        updtStatus = "ERR"
      else
        Response.Write rowsAffected & " records were updated."
        'updtError = false
        updtStatus = "OK"
      end if
    
    'Close connection to DB
    cn.Close
    
    'Garbage collection
    set rs = nothing
    set cn = nothing
    
    'Redirect back to maintenance screen
    if updtStatus <> "ERR" then
          Response.Redirect "jobs_edit.asp"
    end if
    %>
    </body></html>

    Sorry about all the code. I'm just not sure what you would need to help figure this problem out.

    Thanks for any suggestions you might be able to provide.

    Sarb

  2. #2
    SitePoint Enthusiast
    Join Date
    Jan 2012
    Posts
    45
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    What is the error message ?

  3. #3
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Active Server Pages error 'ASP 0126'

    Include file not found

    /jobs_edit.asp, line 3

    The include file '../includes/DSN.asp' was not found.

  4. #4
    SitePoint Enthusiast
    Join Date
    Aug 2011
    Location
    OH, USA
    Posts
    72
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by sarb View Post
    Active Server Pages error 'ASP 0126'

    Include file not found

    /jobs_edit.asp, line 3

    The include file '../includes/DSN.asp' was not found.
    change your include to
    <!-- #include virtual="oaknoll/include/DSN.asp" -->

  5. #5
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I am not really sure why the error message says "The include file '../includes/DSN.asp' was not found."
    because the code at the top of the page doesn't say that, it says:

    "<!-- #include virtual="/oaknoll/include/DSN.asp" -->" Which is what you indicated it should say.

    See the code below.



    Code:
    <?xml version="1.0" encoding="iso-8859-1"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
    <!-- #include virtual="/oaknoll/include/DSN.asp" -->
    
    <head>
    <title>Oaknoll - An Adult Retirement Community</title>
    
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="Keywords"
     content="oaknoll, iowa city, retirement, elderly, iowa, LifeCare, retirement community, nursing home, apartment, independent living, resident, geriatric, aging, community, retire, retired, elder,  health care, assisted living, nursing care">
    <meta name="Description"
     content="Oaknoll is an adult retirement community in Iowa City, Iowa.">
    <meta name="robots" content="index,follow">
    
    <!-- code for employment update form begins here -->
    
    
    <%
    
    Response.Expires = 0
    
    function brtagFixer(strIn)
        
        dim temp
        
    	temp = replace(strIn, "<br>", vbcrlf)
    
        brtagFixer = temp
          
      end function
    
    dim cn, rs, sql
    
    'Open and verify connection to DB
    set cn = server.CreateObject("ADODB.Connection")
    cn.Open cnString("\data", "oaknoll.mdb")
    
    sql = "SELECT * FROM jobopenings"
    set rs = cn.Execute(sql)
    
    %>
    
    
    <!-- code for employment update form ends here -->
    
    
    
    <!-- include Cycle plugin SLIDESHOW -->
    
    <!-- include jQuery library -->
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>
    <!-- include Cycle plugin -->
    <script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.latest.js"></script>
    <script type="text/javascript">
    $(document).ready(function() {
        $('.slideshow').cycle({
    		fx: 'fade' // choose your transition type, ex: fade, scrollUp, shuffle, etc...
    	    	
    			});
    
    
       
    $('#s3').cycle({ 
        fx:    'fade', 
    	
        speed:  8500,
    	
    	cleartype: 1,
    cleartypeNoBg: false,
    height: 'auto',
    containerResize: 0,
    
    timeout: 2000,
    
    sync: 0,
    
    fadeOut:'slow', 
    
    
    
    nowrap: 0,
    randomizeEffects: 0,
    pause: 2
    	
    
    
    });
    	
    	
    	
    
    
    });
    </script>
    
    
     <!--Vertical Slider Navigation javascript - code on external page-->    
        
    <script type="text/javascript" src="js/external_navigation_menu_javascript.js"></script>
    
     <!--endofVerticalSliderNavigationjavascript-->  
    
    
    		
     
      
    <!--tocorrecttheunsightlyFlashofUnstyledContenthttp://www.bluerobot.com/web/css/fouc.asp-->
    	<script type="text/javascript"> </script>
    	
    
    	
    
    <!--[if lt IE 7]>
    <link rel="stylesheet" type="text/css" href="ie6.css" />
    <![endif]-->
    
    
    <link rel="stylesheet" href="../css/oaknoll_newsite.css" type="text/css" />
    <link rel="stylesheet" href="../css/nav_css.css" type="text/css" />
    
    </head>
    
    <body>
    
    <div id="container">
    
     <!--#include virtual="includes/header_asp.asp"-->
    		
          
           
            
    		<div id="main">
             
             
            <div id="box1">
           <div class="slideshow">
    		<img src="../images/sls/nurse_station.jpg" width="400" height="300" alt="Nurses Station" class="first" />
    		</div> <!--end-of-slideshow-->
            </div><!--end-box-1-->
            
            <div id="box2">                
       	  <div class="buttonbox"><img src="../images/4_special_buttons.jpg" alt="internet buttons" width="181" height="300" border="0" usemap="#Map" />
            <map name="Map" id="Map">
              <area shape="rect" coords="14,8,178,70" href="http://www.touchtown.tv/tv/tv/webshow/tv1.jsp?tag=OAKNOLL_WEB" target="_blank" alt="Link to Oaknoll Announcements" border="none" />
              <area shape="rect" coords="14,86,177,145" href="http://www.facebook.com/Oaknoll?ref=sgm" target="_blank" alt="Link to Oaknoll's Facebook Page" border="none"/>
              <area shape="rect" coords="16,161,172,213" href="http://oaknoll.blogspot.com/" target="_blank" alt="Link to the Oaknoll Blog" />
              <area shape="rect" coords="18,233,175,297" href="hawkeye.asp" alt="Link to Golden Hawkeye Birthday Club" />
            </map>
       	  </div><!--BUTTONBOX--> 
            </div><!--end-box-2-->
            
      
       
       <h1 style="clear:left;">Update Job Opportunites...</h1>
      
      
       <form action="jobsupdate.asp" method="post">
                <p><b><i><font size="+2">Current Job Openings </font></i></b></p>
               
    		    <p><b><u><font size="2">Opportunities in Nursing</font></u></b></p>
                <blockquote> 
                  <textarea name="nursing" cols="50" rows="8"><%= brtagfixer(cstr(rs("nursing"))) %></textarea>
                </blockquote>
                <p> <b><u><font size="2">Opportunities in Food & Nutrition</font></u></b> 
                </p>
                <p> </p>
                <blockquote> 
                  <textarea name="food" cols="50" rows="8"><%= brtagfixer(cstr(rs("food"))) %></textarea>
                </blockquote>
                <p><b><u><font size="2">Opportunities in Recreation</font></u></b> 
                </p>
                <p> </p>
                <blockquote> 
                  <textarea name="recreation" cols="50" rows="8"><%= brtagfixer(cstr(rs("recreation"))) %></textarea>
                </blockquote>
              
    		   <p><b><u><font size="2">Opportunities in Building and Grounds</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="building" cols="50" rows="8"><%= brtagfixer(cstr(rs("building"))) %></textarea>
                </blockquote>
    		  
    		  		  
    		    <p><b><u><font size="2">Opportunities in Housekeeping and Laundry</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="housekeeping" cols="50" rows="8"><%= brtagfixer(cstr(rs("housekeeping"))) %></textarea>
                </blockquote>
               
               			
    			
    			 <p><b><u><font size="2">Opportunities in Administration</font></u></b></p>
                <p> </p>
                <blockquote> 
                  <textarea name="admin" cols="50" rows="8"><%= brtagfixer(cstr(rs("admin"))) %></textarea>
                </blockquote>
    			
                <p align="center"> 
                  <input type="submit" name="Submit" value="Submit Changes" />
                  &nbsp;&nbsp; 
                  <input type="reset" name="reset" value="Discard Changes" />
                </p>
              </form>
      
      
            
    </div>
            
            
         
          
    
       <!--#include virtual="includes/menu_asp.asp"-->
    
     
            
    	 <!--#include virtual="includes/footer_asp.asp"-->
      
     
      </div><!--end-of-main-->
    </div><!--end-of-container-->
    </body>
    </html>

    There is this section a little further down, that doesn't have the full folder spelled out. Would that make a difference?

    Code:
    <!-- code for employment update form begins here -->
    
    
    <%
    
    Response.Expires = 0
    
    function brtagFixer(strIn)
        
        dim temp
        
    	temp = replace(strIn, "<br>", vbcrlf)
    
        brtagFixer = temp
          
      end function
    
    dim cn, rs, sql
    
    'Open and verify connection to DB
    set cn = server.CreateObject("ADODB.Connection")
    cn.Open cnString("\data", "oaknoll.mdb")
    
    sql = "SELECT * FROM jobopenings"
    set rs = cn.Execute(sql)
    
    %>
    
    
    <!-- code for employment update form ends here -->

    Thanks,
    Sarahb

  6. #6
    SitePoint Enthusiast
    Join Date
    Aug 2011
    Location
    OH, USA
    Posts
    72
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    because system confused you have http://www.oaknoll.com/oaknoll/include/ path and I gues phisical path oaknoll\oaknoll\include\ your application virtual folder "oaknoll" and #include virtual="/oaknoll/include/DSN.asp" will point you to http://www.oaknoll.com/include/DSN.
    the link http://www.oaknoll.com/oaknoll/jobopenings.asp works now

  7. #7
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ok, so I went to the browser and typed in "http://www.oaknoll.com/oaknoll/jobs_edit.asp". The page with the form opened up ok. So far so good. But when I typed "this is a test" in the first box and then hit submit. I got the following error message:



    "The page cannot be found
    The page you are looking for might have been removed, had its name changed, or is temporarily unavailable.

    Please try the following:

    Make sure that the Web site address displayed in the address bar of your browser is spelled and formatted correctly.
    If you reached this page by clicking a link, contact the Web site administrator to alert them that the link is incorrectly formatted.
    Click the Back button to try another link.

    HTTP Error 404 - File or directory not found.
    Internet Information Services (IIS)

    Technical Information (for support personnel)

    Go to Microsoft Product Support Services and perform a title search for the words HTTP and 404.
    Open IIS Help, which is accessible in IIS Manager (inetmgr), and search for topics titled Web Site Setup, Common Administrative Tasks, and About Custom Error Messages."



    The URL of this page with this error message says:

    "http://www.oaknoll.com/oaknoll/jobsupdate.asp"

    The file "jobsupdate.asp" is in another folder which is called "admin". So the URL should actually read:

    "http://www.oaknoll.com/oaknoll/admin/jobsupdate.asp". But I don't know where in the code to correct this...



    Thanks,
    Sarahb

  8. #8
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Any thoughts??

  9. #9
    SitePoint Guru
    Join Date
    Jun 2007
    Posts
    691
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You need to correct it in the form tag located on the page /jobs_edit.asp

    if you are unfamiliar with this level of programming, you should probably hire someone to assist.

  10. #10
    SitePoint Addict
    Join Date
    Sep 2007
    Posts
    203
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I assume then it's not just a matter of adding a admin/ in front of the "sql = "SELECT * FROM jobopenings" code...

    Sarb

  11. #11
    SitePoint Guru
    Join Date
    Jun 2007
    Posts
    691
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by sarb View Post
    I assume then it's not just a matter of adding a admin/ in front of the "sql = "SELECT * FROM jobopenings" code...

    Sarb
    no


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •