Do you get the "white screen of death" when accessing Admin or Package Installs?

Started by Kindred, April 22, 2013, 10:23:45 PM

Previous topic - Next topic

Chen Zhen


Arantor,
  How about using a condition on php version where >= PHP 5.3 use the callback but change it to a proper anonymous function else (less than PHP 5.3) use the preg_replace with the /e modifier...  or just loop through $smileysfrom and use str_ireplace ?
Just throwing some ideas out there.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Arantor

Why not try it? Why not try it, submit a patch and so on? 2.1 needs patching too for the same reason. *shrug*

I seem to recall you were never that interested in anything I had to say before, why start now? After all, that quote in your signature about people blowing a bunch of phooey out of their butt hole was in reference to me.

Chen Zhen

Arantor,
  The overreaction to the problem at hand may wind up standing out more than the issue itself.  Honestly, I am attempting to help fix this problem and imo our past differences should be settled another time outside of this thread.  I am going to pose a question that is related to the topic and if you do not feel like responding with a related answer at this time I will understand.

Quote from: Sir Cumber-Patcher
* A better fix could be deployed if we were certain that the majority of users were on 5.3+

  As I previously stated, why not have some conditional logic for the PHP version? Using the older (SMF v.2.0.6) preg_replace method with the /e modifier for PHP version prior to 5.3  else  apply the "better" fix. 

 


My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Arantor

Because the better fix requires something that will *break* pre 5.3 and cannot be worked around, namely using proper closures and making use of 5.3+'s late binding to preserve variable scope. Using that in pre 5.3 is instant parse error territory.

*shrug* It isn't my problem now, or at least it won't be once my resignation is accepted. With all the goings on, I've long thought my presence is more a liability than an asset, including people trying to blackmail this project over my contributions (it's unfounded in every way but that doesn't stop the people concerned), and frankly, I'm tired of trying to keep all the plates spinning. (People seem to forget that I end up contributing here 7 days a week, I was working on SMF within a couple of hours of midnight into the new year to get the copyright updated, for example)... I stopped enjoying it a while back and now I'm just left with the knowledge of how many hundreds of things have to be done, including this, and I haven't got the energy any more, especially to deal with people who don't really like me unless it's convenient for them to do so because they'll get something out of it. There's a lot of that going around.

You think you have a solution, go implement it.

GamePersia

i am having blank page problem whenever opening "action=admin;area=packages"
i am having 128MB host memory !!.....
1-2 day's it works easily,..but stops working at any time,..without any reason !!
Help needed..... :-\

Chen Zhen


  I will temporarily need SMF admin and ftp access to someone's forum where the issue is occurring in order to fix the problem.
If someone with this issue is willing to grant me that access so that I may use some trial & error to find a solution please send me a PM.
Unless of course I can duplicate the issue on a local installation but at this point I can not.

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

zerofossilfuel

{sigh} All this infighting leaves me with a really bad taste in my mouth over SMF. You need to attract more coders to ease the workload, not drive them away.

Thanks to all who have offered assistance in the past but I will now be looking at other options.

Arantor

This is half the problem. The dev team is (currently) 3 part time people and that's just not enough to deal with all the issues and I can't take the workload any more the way I have been.

But you're right, the in-fighting has to stop, which is also one of the reasons I've tendered my resignation (despite people trying to talk me out of it)

Chen Zhen

  Twelve SMF files containing preg_replace_callback, nine of which are using create_function for the callback which was an improper implementation. The documentation on php.net for preg_replace_callback (not the user submissions/comments) clearly states to use either a permanent or anonymous (PHP 5.3+) function for the callback. Imo php.net needs to have a warning on the preg_replace_callback page regarding this although you can see that they do have this warning regarding memory usage for create_function.

  The three files with a permanent function for the callback are fine but the other nine files need to be emended.  Imo the devs will figure something out soon enough.  As I already mentioned, using some conditional logic on the PHP version is one possible solution.

if (version_compare(PHP_VERSION, '5.3.0') >= 0)
    //use preg_replace_callback with anonymous function
else
  //use preg_replace with the /e modifier (as in SMF 2.0.6)




  It can be taken even further if necessary. Create 2 files containing like function names for all the instances where preg_replace_callback is currently being used in those 9 files. Include only one of those files (obviously) conditioned on the PHP version.

Perhaps you devs will think of something else. God-speed

Regards.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Arantor

I will say it again: you CANNOT do it that way. Trying to use an anonymous function in PHP 5.2 will simply throw a parse error. Now, if you do take it far enough and use the extra-files-everywhere method, then yes, that would work.

Chen Zhen

Arantor,

  Yes the file implementation would be necessary else syntax error.  It should work if it is done that way.

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Arantor

I read it just fine. The problem is that the entire statement will still fail because PHP parses the entire file before executing it. Meaning that it will fail before it gets to the if statement - UNLESS the entire preg_replace_callback declaration including anonymous function is in a separate file that will NEVER be loaded prior to 5.3.

I invite you to try it on PHP 5.2 if you're convinced it will work.

Chen Zhen


My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

Burt

Quote from: Arantor on February 07, 2014, 12:25:41 AM
I read it just fine. The problem is that the entire statement will still fail because PHP parses the entire file before executing it. Meaning that it will fail before it gets to the if statement - UNLESS the entire preg_replace_callback declaration including anonymous function is in a separate file that will NEVER be loaded prior to 5.3.

I invite you to try it on PHP 5.2 if you're convinced it will work.

Hello there... I have been enjoy reading this thread from the beginning and while I'm not sure of the reason, I would like to understand this. If I got this right the 2.0.7 version has these problems because the team is trying to keep SMF compatible with older version of PHP. Is it really worth it? I mean, how many SMF out there are running on old version of PHP? If the answer fall between 5 to 10% (and I'm just guessing here), surely there must be a logical priority solution for the other 90%...
I apologise if I got this wrong, but is there a fix or will it be one available for this situation?
I'm not try to push anything here...Pure curiosity....that's all

Burt
If you Sig. line is longer or higher than two line, you are just an attention seeker. Grow up!

FuCorp.G3N

i have the same problem "white screen on all pages", i get this after installing simple portal,
my SMF is : 2.0.7
info.php said the memory 128M

& i edit Admin,classpakge in Soures with ini_set"128M", this bug after instaling simple portal.

Any way: i have more the 2 day trying to fix this bug, so if i install dream portal thats not mean "white screen" .

i need your suggestion

By the way:  Email verification, wanna not work, ofcourse i did active it in "registration"

Best Regard's

Chen Zhen

FuCorp.G3N,

  This does not sound like the same issue that is being discussed here. If you are only having issues with one specific modification then you most likely ignored flagged parsing errors during its installation. A white screen means there is a php error and does not necessarily mean it is related to a memory issue specifically.  For issues with specific mods you should be posting in that mods support thread or at their main support forum.

Regards.

 

My SMF Mods & Plug-Ins

WebDev

"Either you repeat the same conventional doctrines everybody is saying, or else you say something true, and it will sound like it's from Neptune." - Noam Chomsky

polepole

I had the same problem with Packages Manager and it got fixed with the suggest mods to

@ini_set('memory_limit', '32M');

However, I am also seeing 2 other white screen issues.

The first is on a specific topic.  When trying to go to page 2 or any post on page 2, I get a white screen.  Going to page 1 or page 3 is ok.

The second is a user gets it when trying to go to PM.

I rolled back to 2.0.6 and the above problems went away.  Back to 2.0.7 and they re-appeared.  So needless to say, I'm back to 2.0.6 now.

-Allen

savicmi

I have exactly the same problem as polepole. In fact, if I go to a page that contains posts with lots of BBC tags (tables, color, size etc), the white screen appears. 2.0.6 doesn't have this problem. It seems to be a problem for users with version 2.0.7, whose hosting has PHP version less than 5.5. There is excessive use of memory, and for example, memory_limit 64M is not enough. Since most SMF users certainly use older versions of PHP, this is a big problem. Are there any indications that this will be resolved soon?

Kindred

the exact reasons were explained...   

and BTW, if you ARE on 5.3 or less, you should ask your host to upgrade to at least 5.4
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

firefox60

I get this with ipage just moved to them and all ready wished I had not. I called them and they told me that they had increased the memory for the php but still getting the error.

HELP ME
Firefox

Advertisement: