Overclockers Australia Forums
OCAU News - Wiki - QuickLinks - Pix - Sponsors  

Go Back   Overclockers Australia Forums > Software Topics > Programming & Software Development

Notices


Sign up for a free OCAU account and this ad will go away!
Search our forums with Google:
Closed Thread
 
Thread Tools
Old 16th September 2002, 1:04 PM   #1
Agg Thread Starter
Lord of the Pings
 
Agg's Avatar
 
Join Date: Jun 2001
Location: A Reported Post near you
Posts: 25,464
Default PHP Problem.. maybe number datatypes.

Very strange problem just started last night with article.php that handles the reviews etc on OCAU. It seems to be fine for existing, older reviews.. but when we make a new one, it gets mangled. The data looks ok in the database and, given it uses the forum database to store the data, there's no other indications of database corruption..

When I reply (add another page) to an old, and currently working, review thread.. article.php produces mangled output. If I delete that new reply then it goes back to being fine. If I make a new thread (new review) then it is immediately mangled.

This makes me think that perhaps, due to the number of posts in the forums, we've hit some kind of datatype-limit for PHP. I know it's not a strictly-typed language and I don't think we declare any types anywhere, just letting PHP handle it.

Does this sound like a problem anyone's had before..? Anything I should be looking for? Doing settype($var, double) on the postnumber variable doesn't seem to fix the prob.

Sorry for the vagueness of the problem description and the lack of code in this message.. if you have any questions or need more info, fire away.
__________________
www.overclockers.com.au - also now on twitter and facebook.
Agg is offline  

Join OCAU to remove this ad!
Old 16th September 2002, 10:58 PM   #2
nudge
Member
 
Join Date: Sep 2001
Location: Amsterdam NL
Posts: 863
Default

what do you mean by 'mangled'?
__________________
nudge.id.au | just a melbourne boy surviving in amsterdam | TomTom for iPhone
nudge is offline  
Old 16th September 2002, 11:01 PM   #3
TerminalError
Member
 
TerminalError's Avatar
 
Join Date: Dec 2001
Location: Blue Mtns
Posts: 641
Default

so article.php adds the data to the database correctly... but when it reads it, it outputs crap? what does the crap look like?

i doubt it has anything to do with the forums... unless you are using the existing forum tables to store the data...
__________________
/!\ Certified Bandwidth Abuser

Traded with: KostA, CBJ, c0rr, terrabyte, beechy, Travloujak, *iNVaDeR*, DarkStyle, crimsonglory, darknight84, 180sxdrifterj, Zangetsu.

Last edited by TerminalError; 16th September 2002 at 11:06 PM.
TerminalError is offline  
Old 16th September 2002, 11:52 PM   #4
Agg Thread Starter
Lord of the Pings
 
Agg's Avatar
 
Join Date: Jun 2001
Location: A Reported Post near you
Posts: 25,464
Default

We use the forums to enter and store the data. article.php grabs the data from the forum database and outputs it. A thread is an article. The first message in the thread has special info. The first reply is the first page of the article, the second reply is the second page, etc.
__________________
www.overclockers.com.au - also now on twitter and facebook.
Agg is offline  
Old 17th September 2002, 12:09 AM   #5
nudge
Member
 
Join Date: Sep 2001
Location: Amsterdam NL
Posts: 863
Default

There shouldnt be a problem with upper limits, as this thread has id=94511.

From thr PHP manual:
"The size of an integer is platform-dependent, although a maximum value of about two billion is the usual value (that's 32 bits signed). PHP does not support unsigned integers. "

Perhaps its something else, such as HTML tags getting in the way when rendering the article.

Any examples of mangled ouput would be helpful =)
__________________
nudge.id.au | just a melbourne boy surviving in amsterdam | TomTom for iPhone
nudge is offline  
Old 17th September 2002, 1:50 AM   #6
Agg Thread Starter
Lord of the Pings
 
Agg's Avatar
 
Join Date: Jun 2001
Location: A Reported Post near you
Posts: 25,464
Default

Fixed! It was apparently a problem with phpaccelerator not being loaded. No idea why that would cause it, but it will fix the server load issue we've had for the last few days, too.

Thanks anyway! Locking this.
__________________
www.overclockers.com.au - also now on twitter and facebook.
Agg is offline  
Closed Thread

Bookmarks

Sign up for a free OCAU account and this ad will go away!

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +10. The time now is 12:30 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd. -
OCAU is not responsible for the content of individual messages posted by others.
Other content copyright Overclockers Australia.
OCAU is hosted by Internode!