Solved

Character encoding - Entries in Access Database

Posted on 2004-10-06
5
624 Views
Last Modified: 2008-03-10
Hi,

I've got a website where a user has to enter in some details and these are saved to a Micosoft Access Database. The problem is that when some users enter in "special" characters such as ñ,ç,ï they are not saved properly in the database.

I'm not sure if this problem arises when the user fills out the web form or when the data is transfered to the database. When I try from my computer on localhost or on the web, everything works okay...

Thanks for any help!
0
Comment
Question by:siono2
5 Comments
 
LVL 7

Accepted Solution

by:
kmorris1186 earned 125 total points
ID: 12237905
you could try using escape() to encode them using the %XX format (like %20 for a space, etc..)
then unescape() to unencode them.

just a thought.

When you try this on localhost they store in the access DB just fine? but not when doing this from another pc?
0
 
LVL 8

Assisted Solution

by:a_twixt_in_the_tale
a_twixt_in_the_tale earned 125 total points
ID: 12238271
In vbscript the equivalent would b

Server.URLEncode(Request.Form(<variable_name>)) befr inserting into DB

anyways ud have to unencode using javascript ;)
separate file
<SCRIPT language="javascript" runat=Server>
function w(s){
      var str = new String(s)
      return unescape(str.replace(/%26/g,"%26amp"));
}
</SCRIPT>

include this file in the asp page. function call w(<string>)

:)
Don
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

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…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

820 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