Application of swfupload in php program

Source: Internet
Author: User
In the php program, swfupload is used to upload SESSION-related questions. SWFUpload re-opens a new Session process during the upload, which cannot be consistent with the Session of the original program. you need to pass the SessionID of the original program during the upload, based on this, "retrieve" the SESSION-related issues in the Sess php program where swfupload is used to upload files
SWFUpload re-opened a new Session process during the upload process. it cannot be consistent with the Session of the original program. you need to pass the SessionID of the original program during the upload process and "retrieve" the expected Session based on it.
But I cannot find it. If anyone knows this, please help. Thank you. I am using the DEDECMS program.

This is the SEEEION opened in Swfupload.
JScript code
  Upload_url: "upload. php", post_params: {"PHPSESSID ":"
  "}, File_size_limit:" 2048 ", file_types :"*. jpeg ;*. jpg ;*. bmp ;*. png ;*. gif ;*. flv ;*. mp4 ;*. wma ", file_types_description:" format of Upload allowed ", file_upload_limit:" 100 ", file_queue_limit:" 0 ",


This is the information on the upload. php processing page.

PHP code
  if (isset($_POST["PHPSESSID"])) {        session_id($_POST["PHPSESSID"]);    } else if (isset($_GET["PHPSESSID"])) {        session_id($_GET["PHPSESSID"]);    }    $img_path = '/uploads/';    session_start();


How can I obtain the SESSION and determine whether the user has the logon permission to upload files? tell me, please.

------ Solution --------------------
Session_start ();
------ Solution --------------------
Please refer to my example below.
Http://download.csdn.net/detail/sibang/4538151
This example seems to have integrated the sessionid authentication component.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.