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 3786132
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T11:38:07+00:00 2026-05-19T11:38:07+00:00

My previous question and this question both are related a bit. please have a

  • 0

My previous question and this question both are related a bit. please have a look at my previous question I did not found any other way to unserialize the data so coming with the string operation

I am able to get the whole content from file but not able to get the specific string from this content.

I want to search a specific string from these content but function stop working when the reach at first special character in the string. If I am searching something found before the special character the works properly.

String operation function of PHP not working properly when the encounter first special character in the string and stop processing immediately, Hence they does not give me the correct output.

Originally they looks like (^@)

:"Mage_Core_Model_Message_Collection":2:{s:12:"^@*^@_messages";a:0:{}s:20:"^@*^@_lastAddedMessage";N;}

but when I did echo they are display as ?

Here is the code what I tried

$file='/var/www/html/products/var/session/sess_ciktos8icvk11grtpkj3u610o3';
$contents=file_get_contents($file);
$contents=htmlspecialchars($contents);
//$contents=htmlentities($contents);
echo $contents;

$restData=strstr($contents,'"id";s:4:"');
echo $restData;
$id=substr($restData,0,strpos($restData,'"'));
echo $id;

I changed the default_charset to iso-8859-1 and also utf-8 but not working with both

Please let me know How I can resolve this.
Thanks.

  • 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-19T11:38:08+00:00Added an answer on May 19, 2026 at 11:38 am

    These characters that you see as ^@ are actually null bytes. They don’t have any proper display, neither they are meant to be displayed – it’s an internal representation of protected properties in the engine. You’re not supposed to mess with them.

    As for resolving, it’d be nice to know what kind of resolution you seek – what result are you trying to achieve?

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

Sidebar

Related Questions

This is kind of related to my previous question, but not really. I have
This question is related to my previous question . The storyline: I have an
This question is similar to my previous question but not the same ... please
Related to my previous question on this matter, where the file was not being
This question is directly related to my previous question ASP.NET AJAX Is it possible
This question is related to a previous question of mine That's my current code
This question is related to my previous question How to generate Cartesian Coordinate (x,y)
This question is related to my previous question - MySQL query to show records
This is semi-related to my previous question . As that previous question states, I
I have deleted my previous question and post this updated: I have a an

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.