Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3958826
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T02:39:20+00:00 2026-05-20T02:39:20+00:00

I am trying to use POST in Flash (ActionScript 2), to POST values to

  • 0

I am trying to use POST in Flash (ActionScript 2), to POST values to PHP mail script.
I tried the PHP mail script with HTML form, and it worked perfectly fine.

But when I POST from flash and input non-English characters, I get “????” in the mail.

I tried utf8_encode($_POST["name"]), but it doesn’t help.

Edit:

I also tried utf8_decode($_POST["name"]), it didn’t work.

Update: (So you wont have to go through all the comments)

  1. I checked the variables in Flash,
    the values are stored correctly.
  2. The HTML page where the Flash is embedded is UTF-8 encoded.
  3. I watched the POST headers with FireBug, the POST itself is already messed up, showing “????” instead of the real value.
  4. The the messed up “????” value, is currently url-encoded by flash, and decoded by PHP, resulting in $_POST["name"] == "???";

I suspect its the sendAndLoad method that creates the mess.

Update:

Here is the flash code:

System.useCodepage = true;
send_btn.onRelease = function() {
   my_vars = new LoadVars();
   my_vars.email = email_box.text;
   my_vars.name = name_box.text;
   my_vars.family_box = comment.text;
   my_vars.phone = phone_box.text;

if (my_vars.email != "" and my_vars.name != "") {
    my_vars.sendAndLoad("http://aram.co.il/ido/sendMail.php", my_vars, "POST");
    gotoAndStop(2);
} else {
    error_clip.gotoAndPlay(2);
}
my_vars.onLoad = function() {
    gotoAndStop(3);
};
};

    email_box.onSetFocus = name_box.onSetFocus=message_box.onSetFocus=function () {
if (error_clip._currentframe != 1) {
    error_clip.gotoAndPlay(6);
}
};
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T02:39:21+00:00Added an answer on May 20, 2026 at 2:39 am

    Flash uses UTF8-encoding for all strings, anyway. If you use LoadVars, transfer as a urlencoded string should also work automatically.

    So your problem is most probably in the PHP part of your application. For example, in order for UTF8 to work correctly, all individual PHP files must be saved in UTF8-encoded format, as well.

    If just changing the file encoding doesn’t work, try parsing $HTTP_RAW_POST_DATA first, check if all the fields have been transferred correctly, then go on and echo your way through until you find the place where the encoding is lost.

    Update:

    Here is your problem: You use System.useCodePage = true;. This requires you to specifically encode all your data as unicode before sending it. Unless you have any other documents in other encodings, and/or allow your users to upload their own text data with their localized encodings, set System.useCodePage = false;, and your utf8-problem should go away.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to use the ASIHTTPRequest libraries to simulate a form post and
I've been trying to use SQLite with the PDO wrapper in PHP with mixed
I need to post some xml to a webservice and I'm trying to use
I'm trying to use the System.Windows.Forms.WebBrowser to make a request that both sends POST
Im trying to use the following PHP to add a favorite to my account:
I trying to use PHP's file upload abilities, but when I try to upload
Trying to use an excpetion class which could provide location reference for XML parsing,
Trying to use a guid as a resource id in a rest url but
While trying to use LINQ to SQL I encountered several problems. I have table
I' trying to use a Linq query to find and set the selected value

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.