Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
Camera Error
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="WiredD" data-source="post: 423752" data-attributes="member: 77365"><p>Does anyone know how to fix this?The index.php file in the camera folder is not able to close the session, so when I take a photo, it loads the previous photo</p><p>[CODE]PHP Warning: session_destroy(): Session object destruction failed in \camera\index.php on line 38[/CODE]</p><p></p><p>index.php</p><p>[PHP]<?phpinclude_once "Init.php";use Images\Image;use Images\Extractor\ImageExtractor;/* Mod version Stage 1: Planes */session_start();$mode = "set"; // Set or getif(isset($_GET["mode"])) $mode = $_GET["mode"];$content = file_get_contents("php://input");if($mode == "set"){ $_SESSION["picdata"] = $content;}else{ if(isset($_SESSION["picdata"]) && isset($_GET["name"])) { $image = new Image(); $overimg = new Image(); $image->SetImageFromContentString($_SESSION["picdata"]); $overimg->SetImageFromFile("overmarks/logo1.gif"); //$overimg->Opacity(0.2); $image->PasteImage($overimg, $image->width - $overimg->width - 10, 10); $name = $_GET["name"]; $image->SaveAt("pictures/$name.png"); session_destroy(); header("Location: pictures/$name.png"); //header('Content-type: image/png'); //$image->ShowImage(); } }[/PHP]</p><p></p><p>Line 38:</p><p>[CODE]session_destroy();[/CODE]</p><p>[doublepost=1512791770,1512539541][/doublepost]UP</p></blockquote><p></p>
[QUOTE="WiredD, post: 423752, member: 77365"] Does anyone know how to fix this?The index.php file in the camera folder is not able to close the session, so when I take a photo, it loads the previous photo [CODE]PHP Warning: session_destroy(): Session object destruction failed in \camera\index.php on line 38[/CODE] index.php [PHP]<?phpinclude_once "Init.php";use Images\Image;use Images\Extractor\ImageExtractor;/* Mod version Stage 1: Planes */session_start();$mode = "set"; // Set or getif(isset($_GET["mode"])) $mode = $_GET["mode"];$content = file_get_contents("php://input");if($mode == "set"){ $_SESSION["picdata"] = $content;}else{ if(isset($_SESSION["picdata"]) && isset($_GET["name"])) { $image = new Image(); $overimg = new Image(); $image->SetImageFromContentString($_SESSION["picdata"]); $overimg->SetImageFromFile("overmarks/logo1.gif"); //$overimg->Opacity(0.2); $image->PasteImage($overimg, $image->width - $overimg->width - 10, 10); $name = $_GET["name"]; $image->SaveAt("pictures/$name.png"); session_destroy(); header("Location: pictures/$name.png"); //header('Content-type: image/png'); //$image->ShowImage(); } }[/PHP] Line 38: [CODE]session_destroy();[/CODE] [doublepost=1512791770,1512539541][/doublepost]UP [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
Camera Error
Top