Dear sirs, Please help with the follows:
When I'm trying to execute this code:
$fcontents = file ('http://localhost/');
while (list ($line_num, $line) = each ($fcontents)) {
echo bLine $line_num:/b; . htmlspecialchars ($line) . br\n;
}
Do not use persistent connections to the database. Use non-persistent
connections and make sure to close them. Persistent connections will linger
around for a while then close. Also, check the documentation on oracle
concerning persistent connections http://otn.oracle.com .
Ray Hunter
If you are behind a firewall or proxy, you will not be able to connect to
www.php.net. If you are not behind a firewall or proxy and you are getting
php_hostconnect errors then you need to make sure that you can get to the
php.net other than with your browser.
You can also try using fopen() as
Hi all,
I've just moved my MySQL db and php scripts over from W2K to Linux and for
some reason my dates are coming across as '-00-00' even though, viewing
the db in MySQLFront, they look fine (actual dates).
When I hosted this on Win2K it worked fine.
I use a function to convert the date
Mate,
what code/function are you using to convert the dates?
what do your data look like in the table (structure, examples)?
-Original Message-
From: George Pitcher [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 19, 2002 8:01 AM
To: [EMAIL PROTECTED]
Subject: [PHP-DB] Problem
Dear Martin,
Why don't you try this :
?
$link = mysql_connect(localhost,phpcoder_dk,pdw );
if (!$link) {
print(Connection fail);
exit();
}else{
if (!mysql_select_db(phpcoder_dk,$link)) {
print(Error);
Hello everybody, i'm new to the list, and i want to know where i get started
with and odbc connection to sql server 2k
any tutorial or manual, would be appreciated
Thanks in advance.
--
Eduardo Cancino
[EMAIL PROTECTED]
---
Coordinador de Desarrollo Web
CENTRO DE
If anyone knows of one, would someone please point me towards a good
tutorial on storing images in a database then fetching them out again.
I would really appreciate it and thanks in advance!
Jen Downey
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit:
Eduardo,
Under Windows, you can simple configure a System DSN in the ODBC
Administrator, and then use the ODBC functions in PHP:
www.php.net/odbc, as ODBC support should be enabled by default.
You can also connect to SQL Server on Windows from a *nix platform, using
the PHP-ODBC-HOWTO at
It depends on the database that you are using. One of the best databases I
have used for storing images has been with oracle. You need to look up the
documentation on there web site. http://otn.oracle.com. As for the other
databases, I have not used images with them. On oracle I have used
Hi Everyone,
I am relatively new to php. I am currently developing a php 4.x
application running on an apache 1.3.x web server which connects to a
remote sybase SQL ASE 12 server.
My main concern is with the command sybase_connect (server,
username,password) on the web server. Obviously, the
Anyone have a tool that takes a SQL Server generated script
and converts it to a mySQL script?
--
__
Your favorite stores, helpful shopping tools and great gift ideas. Experience the
convenience of buying online with
Need some code examples on creating tables for mysql in php
can any one help me on this . I searched the php.net site and only found info on
creating a database I just want to create a php script that will make 2 tables with
lets say 5 fields each in them.
Huh
$query = CREATE TABLE mytable (.
field1 int,.
field2 varchar(50),.
field3 decimal(6,2),.
field4 int,.
field5 int );
mysql_query($query) or die(Error: .mysql_error());
-Original Message-
From: CrossWalkCentral [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 19, 2002 12:26 PM
Need some code examples on creating tables for mysql in php
can any one help me on this . I searched the php.net site and
only found info on creating a database I just want to create a
php script that will make 2 tables with lets say 5 fields each in them.
Hi
Maybe you wanna head on over
Hate to cheat, but have you tried phpmyadmin? It will do a lot of that work
for you and show you the SQL statement. I wouldn't rely on it for complex
actions, since it doesn't seem to be 100% perfect, but, it'll give you the
idea on what you should be looking towards and a starting place to
Hi Jen, here's some code I posted up in the general ng for storing in db and
retrieving images from db for display on your page.
It's recommended that you stay away from storing actual images in the db. If
you are storing a path the code below might help you out. It select a
firstname, and
an
Ammendment:
Make sure you test for the proper file extension before you actually upload
it. The last thing you want is someone uploading a text file instead of the
type of file you are looking for! I forgot to add that in the code. Grab the
last 4 characters off of the end of the filename and
I am just going to interject a second here... sorry :P
About storing images on a server... I did that for awhile, but once i hit
1000+ images, my scripts started timing out.(from reading the directory)
Storing them in the DB seems to actually improve performance for php...
Another issue is that
Is it possible to do a comparison of values from a count...
for example...
SELECT table1.name, count(table1.name) as num1, count(table2.name) as num2 FROM
table1, table2 WHERE table1.name = table2.name AND num1 = num2
This sort of thing dosent work for me. How do I reffrence a count later in
How could you possibly have such a condition exist? That is, what relation
do the counts have to the contents of the name field?
What ARE you trying to really accomplish?
-Original Message-
From: Jonathan Underfoot [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 19, 2002 2:57 PM
To:
ok... authorizations and charges... two tables..
Card Number 1 gets authorized 20 times for use (20 rows in the
authorizations table) and when the transaction is completed they get charged
20 times (20 rows in the charges table) .. however we've been finding that
authorizations are not always
I have a strange problem with LIMIT. When I use it like SELECT * FROM table
LIMIT 0, 10 it works fine. When I add a sort and write the query like
SELECT * FROM table ORDER BY col ASC LIMIT 0, 10 I get no results.
What am I missing?
/Fredrik
--
PHP Database Mailing List (http://www.php.net/)
perfect solution yet :)
is there such a thing? :)
Jd Daniels [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I am just going to interject a second here... sorry :P
About storing images on a server... I did that for awhile, but once i hit
1000+ images, my
I feel kinda dumb for posting this but here it is... I am trying to query a
table then format the results so it looks like the rest of the site and the
darn delete button to remove db entries keeps showing up at the top. Here
is the code... Thanks in advance.
Jas
?php
require
Hi again JD...I got to thinkin':)
Just out of curiosity...how many images were you bringing back from the db
when your script timed out?
I store the path of my image in the db and echo it out when I need to.
Cheers Joe:)
Jd Daniels [EMAIL PROTECTED] wrote in message
[EMAIL
It has never timed out bringing back from the db... only when reading from
disk.
I think the big difference is I need to create both fancy web pages and neat
printable pages. So I need to open up an image stream to manipulate the
photo.
I had a top level dir called photos, then a sub folder
Thanks for the info JD , will keep this in mind for projects that retrieve
higher number of images . Currently I'm only bringing back 1-3 images from
the dir (sorry...meant dir instead of db in previous post:)at time and it
doesn't seem too bad.
Cheers, Joe:)
Jd Daniels [EMAIL PROTECTED] wrote
I've been struggling with creating a rate report based on data extracted
from a
Mysql table. I had written a piece of PHP code for creating the type of
report I needed but it has turned out buggy and prone to errors. I then
tried grouping the rates data in an sql statement but this omits lines
htat's because the delete button is in the wrong place in your code.
if you put an HTML element between the table and /table tags, but don't
enclose it in at least tr and td tags (pretty loose about closing them,
but of course you should always close your tags!) then the browser will
display
Jonathan,
You didn't mention which DBMS you're using (Oracle, MySQL, MS SQL, ...) and
the are each a little different but I'll try to solve with fairly generic
SQL:
My personal preference is keep it simple, break up the SQL if it helps (and
I think it would help here).
I'd use a third table,
Rod,
I hope I've got what you're trying to do.
You have a table with a record for each day and columns rate1 and rate2 -
You are trying to collapse the single days into a range where the rates are
the same?
So if I added column titles to your sample report:
Start Endrate1
32 matches
Mail list logo