Hi,
I am using the function explode or preg_split. I am getting error as "Allowed memory size of 268435456 bytes exhausted (tried to allocate 131223 bytes)" in the following line.
$explode_text = explode("|", $text);
$explode_text = preg_split("/\|+/", $content);
How to solve this issue. with out increasing the size of the memory?
Kindly help me.
thanks,
arivu
Re: Memory alloaction issue
Moderator: General Moderators
Re: Re: Memory alloaction issue
Don't hijack threads.
$text/content is too large to hold another copy of it in memory. Find another solution to your problem that doesn't involve explode() or preg_split().
If you need help with that, an explanation of what you're dealing with would be appreciated.
$text/content is too large to hold another copy of it in memory. Find another solution to your problem that doesn't involve explode() or preg_split().
If you need help with that, an explanation of what you're dealing with would be appreciated.
Re: Memory alloaction issue
Hi,
I am getting error while adding the bulk content.
"Allowed memory size of 268435456 bytes exhausted (tried to allocate 131223 bytes)" in the following line.
$explode_text = explode("|", $content);
$explode_text = preg_split("/\|+/", $content);
Increase the memory is the solution for this issue.
But this plugin needs to work in Shared hosting environments, i can't increase a VPS to that much memory.
So kindly give solution for this issue,
Thanks,
arivu
I am getting error while adding the bulk content.
"Allowed memory size of 268435456 bytes exhausted (tried to allocate 131223 bytes)" in the following line.
$explode_text = explode("|", $content);
$explode_text = preg_split("/\|+/", $content);
Increase the memory is the solution for this issue.
But this plugin needs to work in Shared hosting environments, i can't increase a VPS to that much memory.
So kindly give solution for this issue,
Thanks,
arivu
Re: Memory alloaction issue
No, throwing hardware at a problem is not really a solution. You haven't shown us what you're trying to do or why you're trying to do it that way, so we can't help you. We've got nothing to work with.Increase the memory is the solution for this issue.
Re: Memory alloaction issue
Hi,
I have created custom plugin for posting the content in wordpress. Based on content keywords I have allocated the pages for that custom post.
If i added the small content. i did not get any error. while adding the bulk content i am getting memory allocation issue.
The added content contains special characters, html code and text, so i will explode the content using the below code.
$explode_text = explode("|", $content);
$explode_text = preg_split("/\|+/", $content);
I am getting memory allocation error as below.
"Allowed memory size of 268435456 bytes exhausted (tried to allocate 131223 bytes)" in the following line.
any other function(without kill the memory) like the explode.
any solution for this issue?
thanks,
arivu
I have created custom plugin for posting the content in wordpress. Based on content keywords I have allocated the pages for that custom post.
If i added the small content. i did not get any error. while adding the bulk content i am getting memory allocation issue.
The added content contains special characters, html code and text, so i will explode the content using the below code.
$explode_text = explode("|", $content);
$explode_text = preg_split("/\|+/", $content);
I am getting memory allocation error as below.
"Allowed memory size of 268435456 bytes exhausted (tried to allocate 131223 bytes)" in the following line.
any other function(without kill the memory) like the explode.
any solution for this issue?
thanks,
arivu
Re: Re: Memory alloaction issue
Are you reading our replies? I'm not going to spend any more time trying to help you if you aren't reading our replies.
Re: Re: Memory alloaction issue
I am reading all reply. Kindly help me