473,471 Members | 1,737 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

China to English Coding error messages

1 New Member
I have been given the task of "repairing" a webpage that was created in China and copied to an ASP Server in the USA. Part of the script was in Chinese when I started, but I think it's all English now:

Expand|Select|Wrap|Line Numbers
  1. <%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
  2. <!--#include file="inc/readImg.asp" -->
  3. <!--#include file="inc/dbconn.asp" -->
  4. <html>
  5. <head>
  6. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  7. <title>-=- KAKADU -=-</title>
  8. <link href="css/aobeike.css" rel="stylesheet" type="text/css">
  9. </head>
  10. <body>
  11.  
  12. <table width="1000" height="1194" border="0" cellpadding="0" cellspacing="0" background="images/beijing.jpg">
  13.   <tr>
  14.     <td width="111" valign="top"> </td>
  15.     <td valign="top"><table width="778" border="0">
  16.       <tr>
  17.         <td height="25"> </td>
  18.       </tr>
  19.       <tr>
  20.         <td> </td>
  21.       </tr>
  22.       <tr>
  23.         <td>
  24.                 <!--start website navigation-->
  25.                 <table width="778" border="0">
  26.           <tr>
  27.             <td width="170"> </td>
  28.             <td width="577" class="yaoqiu"><div align="right"><a href="productlist.asp?Category=jackets" class="yaoqiu">Jackets</a>  /  <a href="productlist.asp?Category=shirts" class="yaoqiu">Shirts</a>  /  <a href="productlist.asp?Category=pants" class="yaoqiu">Pants</a>  /   <a href="productlist.asp?Category=bags" class="yaoqiu">Bags</a>  /  <a href="productlist.asp?Category=vests" class="yaoqiu">Vests</a>  /   <a href="productlist.asp?Category=hats" class="yaoqiu">Hats</a>  /  A<a href="productlist.asp?Category=accessories" class="yaoqiu">ccessories</a>  /  <a href="company.html" class="yaoqiu">Home</a></div></td>
  29.             <td width="17"> </td>
  30.           </tr>
  31.         </table>
  32.                 <!--end website navigation-->
  33.           </td>
  34.       </tr>
  35. <%
  36.   page=request("page")
  37.   Category=request("Category")
  38.     if Category<>"" then
  39.       temp=Ucase(left(Category,1))
  40.         'Category=temp & right(Category,len(Category)-1)
  41.     end if
  42. %>
  43.       <tr>
  44.         <td>
  45. <%
  46.   if Category<>"" then
  47. %>
  48.                    <span style="font-size:30px;font-family:Monotype Corsiva;"><%=temp & right(Category,len(Category)-1)%></span>
  49. <%
  50.   end if
  51. %>
  52.           </td>
  53.       </tr>
  54.     </table>
  55. <!--start product list-->
  56. <%
  57.   if Category<>"" then
  58.       openconn
  59.         set rs=server.createobject("adodb.recordset")
  60.         sql="select * from [product] where category='" & category & "' order by updateTime desc"
  61.         rs.open sql,conn,1,1
  62.     if not rs.eof then
  63.           rs.pagesize=12
  64.       rs.absolutepage=1
  65.       if page<>"" then
  66.         rs.absolutepage=page
  67.       end if
  68.       page=rs.absolutepage
  69. %>
  70. <table width="778" border="0">
  71. <%
  72.   n=1
  73.   do while not rs.eof and n<5
  74. %>
  75.   <tr>
  76. <%
  77.     for j=1 to 3 
  78. %>
  79.     <td align="center" width="33%">
  80. <%
  81.   if not rs.eof then
  82. %>
  83.  <table  border="0">
  84.   <tr>
  85.     <td align="center">
  86. <%
  87.     imgFile=rs("Img")
  88.     productImg=imgFile
  89.   if imgFile<>"" then
  90.     imgFile=server.mappath(imgFile)
  91.     set f=server.createobject("Scripting.FileSystemObject")
  92.     if f.FileExists(imgFile) then
  93.       set getImgsize=new GPS
  94.       pd=getImgsize.getImageSize(imgFile)
  95.       temp=pd(1)/pd(2)
  96.       if temp>1 and pd(1)>200 then
  97.         PWidth=200
  98.         PHeight=200/temp
  99.       elseif temp<1 and pd(2)>200 then
  100.         PHeight=200
  101.         PWidth=200*temp
  102.             elseif temp=1 and pd(1)>200 then
  103.                PWidth=200
  104.                  PHeight=200
  105.             else
  106.               PWidth=pd(1)
  107.                 PHeight=pd(2)
  108.       end if
  109.  
  110.       set getImgsize=nothing
  111.       end if
  112.     set f=nothing
  113.     end if
  114. %>
  115. <a href="<%=rs("html")%>"><img src="<%=productImg%>" width="<%=PWidth%>" height="<%=PHeight%>" border="0">    </a>    </td>
  116.   </tr>
  117.   <tr>
  118.     <td align="center"><div class="yaoqiu1" style="font-family:Monotype Corsiva;font-size:20px;"><%=rs("productName")%></div></td>
  119.   </tr>
  120. </table>   
  121.  <%
  122.     rs.movenext
  123.     end if
  124. %>
  125.  
  126.  
  127.         </td>
  128. <%
  129.     next
  130. %>
  131.   </tr>
  132. <%
  133.     n=n+1
  134.   loop
  135. %>
  136. </table>
  137. <table width="778" border="0">
  138.   <tr>
  139.     <td width="650"> </td>
  140.     <td width="118"> </td>
  141.   </tr>
  142. </table>
  143.  
  144. <table width="600" height="56" border="0" align="center">
  145.   <tr>
  146.     <td><table width="95%" align=center>
  147.       <form action="<%=request("Script_name")%>?Category=<%=Category%>" method="post">
  148.         <tr>
  149.           <td width="80" align="center" class="yaoqiu"><%
  150.   if page>1 then
  151. %>
  152.                 <a href="<%=request("Script_name")%>?page=1&Category=<%=Category%>">First</a>
  153.                 <%
  154.   else
  155. %>
  156.             First
  157.             <%
  158.   end if
  159. %>
  160.           </td>
  161.           <td width="80" align="center" class="yaoqiu"><%
  162.   if page>1 then
  163. %>
  164.                 <a href="<%=request("Script_name")%>?page=<%=page-1%>&Category=<%=Category%>">Previous</a>
  165.                 <%
  166.   else
  167. %>
  168.             Previous
  169.             <%
  170.   end if
  171. %>
  172.           </td>
  173.           <td width="80" align="center" class="yaoqiu"><%
  174.   if page<rs.pagecount then
  175. %>
  176.                 <a href="<%=request("Script_name")%>?page=<%=page+1%>&Category=<%=Category%>">Next</a>
  177.                 <%
  178.   else
  179. %>
  180.             Next
  181.             <%
  182.   end if
  183. %>
  184.           </td>
  185.           <td width="80" align="center" class="yaoqiu"><%
  186.       if page<rs.pagecount then
  187. %>
  188.                 <a href="<%=request("Script_name")%>?page=<%=rs.pagecount%>&Category=<%=Category%>">Last</a>
  189.                 <%
  190.   else
  191. %>
  192.             Last
  193.             <%
  194.   end if
  195. %>
  196.           </td>
  197.           <td width="105" align="center" class="yaoqiu"><div align="right">Goto</div></td>
  198.           <td width="38" class="yaoqiu"><div align="right">
  199.             <select name="page" onChange="javascript:submit();">
  200.               <%
  201.   for i=1 to rs.pagecount
  202. %>
  203.               <option value="<%=i%>"
  204. <%
  205.   if i=page then
  206. %>
  207.   selected
  208. <%
  209.   end if
  210. %>
  211.   ><%=i%></option>
  212.               <%
  213.   next
  214. %>
  215.             </select>
  216.           </div></td>
  217.           <td width="69" class="yaoqiu">page</td>
  218.         </tr>
  219.       </form>
  220.     </table></td>
  221.   </tr>
  222. </table>
  223. <%
  224.         end if
  225.         rs.close
  226.         set rs=nothing
  227.         closeconn
  228.     end if
  229. %>
  230. <!--end product list-->
  231.     </td>
  232.     <td width="111" valign="top"> </td>
  233.   </tr>
  234. </table>
  235.  
  236. </body>
  237. </html>
If I leave the script as is, I get this error message:

Microsoft JET Database Engine error '80004005'

Selected collating sequence not supported by the operating system.

/productlist.asp, line 61

If I remove the first 3 lines - I get this message:

Microsoft VBScript runtime error '800a000d'

Type mismatch: 'openconn'

/productlist.asp, line 55

Can anyone give me some assistance?
Jun 23 '07 #1
1 1287
jhardman
3,406 Recognized Expert Specialist
It looks like 'openconn' is some kind of function call, but the function is in one of the include files, so you definitely need those includes.

The original error, regarding the collating sequence seems to be in regards to the 'conn' object. This might easily be messed up when the web app was transferred from one host to another, and I would suggest you look into that (it is also in one of the include files).

Jared
Jun 26 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: F. GEIGER | last post by:
When I start a py2exe-ed application I get the error 'ascii' codec can't encode character u'\xe9' in position 10: ordinal not in range(128) This is how I run py2exe: setup.py py2exe -O1...
1
by: Eric | last post by:
Hi, Normally I'm developing evertime with the english versions of Win, VS.NET, ..NET etc. But know I have a german Win XP SP1 with IIS 5.1 installed. Anyway I would like to develop with...
67
by: Robert | last post by:
Hi, I have been reading the article at http://www.crockford.com/javascript/private.html and I was wondering if there also was some way to be able to have private methods that can be called from...
2
by: ntbenson | last post by:
Hi, I am wanting to develop a database in Australia and also have copies of the database used in other offices. (Japan, China, Korea and Australia) If i develop the database in English in...
1
by: George Orwell | last post by:
Returning int pointer ? Mahendra said: No, it's impossible to say. If your target system is a pre-C99 implementation, only 6 significant characters, case insensitive, are guaranteed in...
1
by: George Orwell | last post by:
Ian Collins said: Richard Heathfield said: Ian Collins said: Phil Carmody said: Jeez, and let fire burn you to a crisp if you should discuss threads on comp.lang.c. Anyone who was...
16
by: Borked Pseudo Mailed | last post by:
Error handling in C Nick Keighley said: ... ... To the OP, please be aware that Nick Keighley is a known troll and is deliberately providing you with unsound advice. You asked for error...
2
by: Nomen Nescio | last post by:
What is this? Eric said: That looks like either someone's poor coding or someone's poor pasting for an implementation of offsetof() from stddef.h. The (char *) leads me to think that there's...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.