473,651 Members | 2,635 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Blank Screen still happening...

18 New Member
I know there have been various questions about blank screens from php but I've looked around and they aren't helping me at all.

I wrote a .php page and put it up on the hosting server but the page keeps on returning blank. I've checked that I have all my brackets and semicolons placed correctly.
I've added
Expand|Select|Wrap|Line Numbers
  1. <?php
  2. //turn on error reporting
  3. ini_set('display_errors',1);
  4. ERROR_REPORTING(E_ALL);
  5. ?>
to the top of page but it is still returning blank without any error reports.
I found my php.ini file and checked that also. The display_errors is set to ON. Also, there isn't anything logged in a .txt file.
I wrote in phpinfo(); previously and it worked; the server has php up and running correctly. The version is 4.3.11
However, I did notice that even though I changed display_errors to ON it still says OFF in the info that shows up, however that shouldn't matter since I specified having error reporting on in the specific page.
_______________
I deleted everything and just put this in the body
Expand|Select|Wrap|Line Numbers
  1. <?php
  2. //turn on error reporting
  3. ini_set('display_errors',5);
  4. ERROR_REPORTING(E_ALL);
  5. ?>
  6. <?php
  7. echo "Hello World
  8. ?>
I still get a blank screen when there should be an error showing.
Sep 2 '09 #1
4 2091
koager
18 New Member
I ended up inputting it line by line to see where the error is.
Found that and fixed it. However I have another problem now...
It seems that it is now not connecting to the database.
I believe I have the host, username, and password correct.

$con = @mysql_connect( "FAAMDLDatamysq l.db.2233605.ho stedresource.co m","________"," ******");

I've checked, double checked, and triple checked my username and password and they are spelled correctly and with capitals and everything.
For the host I've also tried their IP 10.6.186.63 but still no connection.

The server version is 5.0.67.d7-ourdelta-log
and I tried
running this sql

SET PASSWORD FOR user@localhost = OLD_PASSWORD('* *****');

but it didn't work
Sep 2 '09 #2
dlite922
1,584 Recognized Expert Top Contributor
can you ping the host? can you telnet form a command line to that host on the MySQL default port 3306?

The problem is most likely your connection rather than PHP.

Remove the @ sign in front of mysql_connect and append this:

Expand|Select|Wrap|Line Numbers
  1. ....****") or die("Could Not Connect, here's the error<br>" . mysql_errno()); 
  2.  

Let us know,



Dan
Sep 2 '09 #3
koager
18 New Member
I deleted the @localhost part and it worked.
Right now I'm trying to solve the problem of the string that I return with my form needs to be stored with " " around it for my SELECT * WHERE to be able to locate the data.
I have $_GET['stock'] stored into $stock but I need it to be stored along with " " to be usable as it is a string and it needs to be defined as one with the quotes for it to be found in the database. /" isn't working...
_______________
Maybe not...
I got quotes around it with
$stock = '"' . $_GET['stock'] . '"';
but my SELECT * WHERE Stock_code="$st ock" still doesn't seem to be locating the data

Unless it's my display code that is not functioning correctly
Expand|Select|Wrap|Line Numbers
  1. //Display result
  2.     //create header cells
  3. echo "<table border='1'>
  4.         <tr>
  5.             <td><b>Stock Code / Component</b></td>
  6.             <td><b>Description</b></td>
  7.             <td><b>System Model #</b></td>
  8.             <td><b>Rotocraft Make</b></td>
  9.             <td><b>Rotocraft Applicable Models</b></td>
  10.             <td><b>STC</b></td>
  11.         </tr>";
  12. //input data into cells of table
  13. while ($row=mysql_fetch_array($result)){
  14.     echo "<tr>";
  15.     echo "<td>".$row['Stock_code']."</td>"; 
  16.     echo "<td>".$row['Description']."</td>";
  17.     echo "<td>".$row['System_Model']."</td>";
  18.     echo "<td>".$row['Rotocraft_Make']."</td>"; 
  19.     echo "<td>".$row['Rotocraft_Applicable_Models']."</td>"; 
  20.     echo "<td>".$row['STC']."</td>";
  21.     echo "</tr>";
  22.     }
  23. echo "</table>";
Sep 2 '09 #4
koager
18 New Member
Nevermind about the echoing out the data retrieved.
I replaced $stock in the SELECT * WHERE statement with a stock code that I know and it would display it fine.

Logically, it makes sense for it to work
I retrieve the string that is inputted, add quotes around it, insert that into the SELECT * WHERE statement, which then takes that to the database and locates anything that matches the string, stores it as $result, and, from my while statement, displays it in a table.
Sep 2 '09 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

14
2618
by: charlie_M | last post by:
Is there a way to blank the screen in a FORM's onsubmit=... to blank the screen for the user?? I asked this before and got a way to blank a table by id with "document.getElementById('tabid').style.display='none';" in the onclick event and setting the encapsulating table's ID to 'tabid'. I was wondering if this or some other similar approach that could possibly be planted globally in my pages in the onsubmit validation
2
2227
by: Amir | last post by:
I really hope someone can explain this behavior. I have spend quite a bit of time and tried a bunch of things, so far nothing has worked. I have a page on which I have a datagrid with template columns. I perform regular expression validations in the EditItemTemplate for the fields that require such validation. The datagrid is inside a div tag to make it scrollable. I have implemented the solution to freeze header for this grid - the...
3
3147
by: shishuda91 | last post by:
I'd like to display scrolling, word-wrapped, centered text on a blank white screen with no window borders, nothing. Just a pure white screen with big letters in the middle (in an invisible box). Then I want to use the mouse buttons to page up or page down (left and right buttons), or exit (double click). Can someone point me in the right direction? I'm new to VB. Thanks!
5
3300
by: carqs123 | last post by:
I have an application that does alot of work and calculations. It updates it's internal status on a windows form. When I debug single step the numbers appear just right on the form. When I run the program in normal mode the text boxes to which the info is displayed just blank out. Sometimes the entire form just turns all white. I get the impression that the updates are happening too fast or something like that. What's going on? ...
2
4921
by: Eric | last post by:
We have a page that displays a datagrid with quite a bit of data in it. We have a few comb-boxes that we filter data on when we click the search button. I can change the combo-boxes and click the search button, but if during that time I go and look at an email or get a cup of water, I come back and click the search button I get a white screen or blank screen. I checked my session and it is still valid. If I close the page and re-open it...
1
2425
by: Raul Elms | last post by:
Hi, I'm running Apache2 together with the php and mysql modules on an opensuse 10.1 machine. Most scripts run well, I can connect and query databases without any problems. But some well known scripts like phpMyAdmin or Nucleus fail. When accessing a database or table (I don't really know when PHP crashes) PHP just returns a blank screen (HTML source code is blank as well). For instance phpMyAdmin: With only one server configured I can...
2
3459
tdw
by: tdw | last post by:
I have tried to search everywhere for solutions to this. My problem is that on some programs, certain windows are blank white. An example: I installed Adobe Acrobat 8, also Adobe Reader 8. On both, the screen where it asks me to accept or decline the user agreement is blank, so I have no way of accepting. All I can do is click the X (close) button, which then tells me that I have declined the agreement and the program will close. Another...
0
1802
by: crankeboy | last post by:
Hi Folks, My setup: Visual Studio Express 2008, VC++, .NET, BitBlt Here is a summary of the problem: - I am trying to copy a bitmap of my main form into a picture box. - To do this, I bitblt using the device contexts of the form and a bitmap object. - After blitting, the bitmap image is always blank. I don't understand what I'm doing wrong here. Here is my relevant code:
2
3216
by: Lawrence Krubner | last post by:
Imagine a template system that works by getting a file, as a string, and then putting it through eval(), something like this: $formAsString = $controller->command("readFileAndReturnString", $formName); // 06-22-07 - the next commands try to import all the functions that the
0
8349
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8795
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8460
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8576
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6157
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4143
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4281
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1906
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1585
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.