PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Iron Speed
 
Go Back   Dev Articles Community ForumsProgrammingPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Ajax Application Generator Generate database and reporting .NET Web apps in minutes. Quickly create visually stunning, feature-rich apps that are easy to customize and ready to deploy. Download Now!
  #1  
Old May 16th, 2002, 01:41 AM
infamous-online infamous-online is offline
Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 404 infamous-online User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 21 m 10 sec
Reputation Power: 7
Thumbs down Php 4.2.1 & Mysql

ok i upgraded to php 4.2.1 but heres the problem, if i try to install something like a message board or anything else requiring mysql i get this error
PHP Code:
 CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers
The headers it did return are
and i dont know how to fix it. HELP!!!!
__________________
Apache Expert

Reply With Quote
  #2  
Old May 16th, 2002, 01:45 AM
Ben Rowe
Guest
Dev Articles Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
try reinstalling php and mysql, also make sure ur config file is correct, and make sure its the right install for your system

other then that, from the info your offered. theirs nothing much else it could be, does the error only come up when trying to access mysql???

Reply With Quote
  #3  
Old May 16th, 2002, 05:50 AM
infamous-online infamous-online is offline
Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 404 infamous-online User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 21 m 10 sec
Reputation Power: 7
Thumbs down

heres the thing, my site is done in php right but let's say i want to add phpbb2 to my site, thats when i'll get the cgi error. i don't what it could be but i'm going crazy over here because i can't figure out what's causing this error and everything is setup right too. also i did try reinstalling and uninstalling both countless times no luck wtf gives....

Reply With Quote
  #4  
Old May 16th, 2002, 06:25 PM
mytch mytch is offline
Dev Articles Novice (500 - 999 posts)
 
Join Date: Apr 2002
Location: Sydney, Australia
Posts: 589 mytch User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
PHP 4.2 is a bitch! They've changed alot of things.. i.e. HTTP_SERVER_VARS, etc aren't global anymore and have been deprecated for $_SERVER, etc...

It'll be a couple of options in your INI file that's making it behave badly, coz i think phpbb2 is for PHP 4.1... not many apps support 4.2 yet, so you just need to mod ini file.

change register_globals to On as a start. Next, checkout the 4.2 guide at php.net. Just search for upgrade or php 4.2 or new version in the search box. search the whole site.

Reply With Quote
  #5  
Old May 16th, 2002, 11:43 PM
infamous-online infamous-online is offline
Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 404 infamous-online User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 21 m 10 sec
Reputation Power: 7
Unhappy

does anybody have the php 4.1.1 installer file not the source code, because i dont know how to set that up

Reply With Quote
  #6  
Old May 17th, 2002, 04:14 AM
infamous-online infamous-online is offline
Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 404 infamous-online User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 21 m 10 sec
Reputation Power: 7
heres the code for my store.php4 file please tell me what i need to change, also here is my getdata.php4 file tell me what i need to fix. also i turned on magic quotes but when i upload the file to the database it's a zero instead of 1,2 3 and so forth. sorry for the hassle guys....

PHP Code:
<HTML>
<
HEAD><TITLE>Store binary data into SQL Database</TITLE></HEAD>
<
BODY>
<?
php
// code that will be executed if the form has been submitted:

if ($submit) {

    
// connect to the database
    // (you may have to adjust the hostname,username or password)

    
MYSQL_CONNECT("localhost","blah");
    
mysql_select_db("mysql");

    
$data addslashes(fread(fopen($form_data"r"), filesize($form_data)));

    
$result=MYSQL_QUERY("INSERT INTO binary_data (description,bin_data,filename,filesize,filetype) ".
        
"VALUES ('$form_description','$data','$form_data_name','$f  orm_data_size','$form_data_type')");

    
$idmysql_insert_id();
    print 
"<p>This file has the following Database ID: <b>$id</b>";



    
MYSQL_CLOSE();

} else {

    
// else show the form to submit new data:
?>

    <form method="post" action="<?php echo $PHP_SELF?>" enctype="multipart/form-data">
    File Description:<br>
    <input type="text" name="form_description"  size="40">
    <INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="1000000">
    <br>File to upload/store in database:<br>
    <input type="file" name="form_data"  size="40">
    <p><input type="submit" name="submit" value="submit">
    </form>

<?php

}

?>
</BODY>
</HTML> 


getdata.php4

PHP Code:
<?php
if($id) {

server:
    @
MYSQL_CONNECT("localhost","blah");

    @
mysql_select_db("mysql");

    
$query "select bin_data,filetype from binary_data where id=$id";
    
$result = @MYSQL_QUERY($query);

    
$data = @MYSQL_RESULT($result,0,"bin_data");
    
$type = @MYSQL_RESULT($result,0,"filetype");

    
Header"Content-type: $type");
    echo 
$data;

};
?>

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingPHP Development > Php 4.2.1 & Mysql


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five &quot;checkpoints&quot; for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 

Iron Speed




© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway