Jump to content

Recommended Posts

Neither can we because you have not posted any specific information about your code or data.

 

I'm going to guess that your form (or whatever the source is of your data) is invalid HTML and the data is submitted in one browser but not another. It would take seeing the relevant information and code showing where the data comes from and what the data actually is that is not turning up in a session variable.

Link to comment
https://forums.phpfreaks.com/topic/186118-session-variable/#findComment-982950
Share on other sites

Hi the code is follows

 

<?php

require_once('./utils.php');

 

if(!isset($_SESSION['timestamp_logo_path']))

{

$time = BASENAME_TIME;

$_SESSION['timestamp_logo_path'] = $time;

}

$tempFile = $_FILES['Filedata']['tmp_name'];

$fileName = $_FILES['Filedata']['name'];

$fileSize = $_FILES['Filedata']['size'];

$path="ProfileImages/";

$uploadfilePath =$path.$_SESSION['timestamp_logo_path']."_".$fileName;

move_uploaded_file($tempFile,$uploadfilePath); 

?>

the session variable $_SESSION['timestamp_logo_path'] using in another page

 

in function

 

function fn_image_upload($imageUploadObject)

{

$uploaddir = "ProfileImages/";

$uploadname = basename($imageUploadObject[photoPath]);

//if($uploadname==''){

// $uploadname="default.jpg";

//}

//$logopath=$_SESSION[timestamp_logo_path];

$logopath=$_SESSION['timestamp_logo_path'];

$uploadfile = $uploaddir.$logopath."_".$uploadname;

$searchResults = array();

$temp = new Employee();

$temp->photoPath = $uploadfile;

array_push($searchResults, $temp);

unset($_SESSION['timestamp_logo_path']);

return $searchResults;

}

 

here i am unable to get the variable value in FF...but it is working fine in IE

Link to comment
https://forums.phpfreaks.com/topic/186118-session-variable/#findComment-982962
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.