Hi All
How can I read the contents of 1 file then Write those contents to a
newfile?
This is baffling me.
I Know about fopen,fread,fwrite but cant seem to get the logical steps clear
in my head.
As always any help or pointers given are most appreciated.
Yours
Dave C
--
PHP Database Maili
Hi
1. What is the difference between working with PHP and MySQL on a local
server and working with PHP and MySQL when MySQL is on a remote server?
2. What is the protocol used to connect to MySQL on a local server and
what is the protocol used to connect to a remote MySQL server?
3. Is there a
easy peasy dave :) (pseudo-code - cause i'm lazy and hopefully you aren't
:P)
// -Original Message-
// From: Dave Carrera [mailto:[EMAIL PROTECTED]]
// Sent: Thursday, 17 January 2002 4:21 PM
// To: [EMAIL PROTECTED]
// Subject: [PHP-DB] Reading and Writing ?
//
//
// Hi All
//
// H
Very good answer Frank, Thanks!
My department is 95% MS oriented and this is why we prefer an MSSQL
Server 2000 Cluster instead of a sun based cluster. We already have
an MSSQL 7.0 Cluster which we will be upgrading soon to MSSQL Server
2000 which has been up for over 2 years. It's running on w
I don't think you realize the nature of the site. Its an auction site
and not a retail site.
Prices need to be updated on thousands of clients simultaneously. Our
goal is to
refresh the data on the client every 3-10 seconds while having 1500
online open
auctions.
This is quite a mess :)
-Ori
Fail Over is not for when the cluster is too busy, it's for when the
server dies, or when someone killed it's power, or when you loose your
network, or when you get a blue screen (assuming you are on windows :).
Then, in about 30 seconds the cluster will do a fail over to the 2nd
node and the sit
Hi again!
I have a MySQL table named ratings. It has 5 fields in
it like this:
ID, name, deposit, days, hands
The table has 10 rows in it with assorted data in each
field.
Here is what I would like to to:
1. Display all 10 rows of data on the page in a table
with the fields deposit, days and h
// 1. What is the difference between working with PHP and MySQL
// on a local
// server and working with PHP and MySQL when MySQL is on a
// remote server?
none - just specify different hostname in connection call (perhaps IP more
reliable)
// 2. What is the protocol used to connect to MySQL
Hi John - I have come up against this one a number of times, and have found
that the following works pretty nicely - although there may be better ways
out there
- get your records from the db
- loop thru them, using some sort of ID field to print each row in your
table with names something lik
Check out :
http://www.weberdev.com/index.php3?GoTo=phenominet/prices.htm
This is your one stop shop for hosting. WeberDev.com is hosted there
and I can tell you that their service is amazing. They are fast,
reliable
and more than anything, very professional (specially in PHP / MySQL).
Sincere
It's not anything to do with the special regular expression characters again
is it?
-Original Message-
From: Beau Lebens [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 01:38
To: 'Markus Lervik'; [EMAIL PROTECTED]
Subject: RE: [PHP-DB] What is REG_BADRPT, and why do I get it?
on a gue
If I perform the following query in MySQL_Front, It works but I get no
records returned (there should be 10 records).
If I use it with php on my web page, I get an error: "Supplied argument is
not a valid MySQL result resource in [script name]" which is probably
because of the zero return.
The s
If I perform the following query in MySQL_Front, It works but I get no
records returned (there should be 10 records).
If I use it with php on my web page, I get an error: "Supplied argument is
not a valid MySQL result resource in [script name]" which is probably
because of the zero return.
The s
> 1. What is the difference between working with PHP and MySQL on a local
> server and working with PHP and MySQL when MySQL is on a remote server
None in terms of functionality.
> 2. What is the protocol used to connect to MySQL on a local server and
> what is the protocol used to connect to a
Hi,
I am experiencing a problem with this function;
funcion do_connect($server, $db, $user, $pass){
$link = @mysql_pconnect($server, $user, "$pass")
or die("error: mysql_pconnect()");
mysql_select_db($db) or die("error: mysql_select_db()");
}
when supplied with variables that are c
I'm creating this form where the person needs to enter a password to move
on. When they enter the password it just loops back to enter the password
and doesn't move on. But then I remove the requirement for a password the
page moves on and loads the information from the DB. Why is this?
--
PHP
can someone tell me a decrypt and crypt fuction besides in the mcrypt pack?
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]
Hi, I'm having a problem with the stcmp() function. I have it comparing two
string variables, $pword and $conf_pword, in a script. I know they both
have values, but the result always compares to 1 when $pword is the first
variable in the function, and -1 when $pword is the 2nd variable in the
fu
post the entire line of code, (and the surrounding couple of lines??
and we'll get more of an idea.
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 14:56
To: [EMAIL PROTECTED]
Subject: [PHP-DB] string compare function
Hi, I'm having a problem with the
Hi, this is more of an earlier post regarding the strcmp function and my
problems with it on my Win98 machine.
This is the actual code I used for the strcmp function,
$errors=0;
if (empty($username)||empty($pword)||empty ($conf_pword)||empty($redirect))
{
echo "Please hit your browser's back
take it you've tried having exactly the same value for each to test if the
return is 0?
it shouldn't be comparing literals, but it looks like it could well be!
try putting "" round the variables, and various things like that?
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
by the way, what are you actually trying to do with the code? there may be a
different way of doing it which isn't so confusing?
-Original Message-
From: tomhilton [mailto:[EMAIL PROTECTED]]
Sent: 17 January 2002 15:20
To: [EMAIL PROTECTED]
Subject: [PHP-DB] string compare function
Hi,
Hello again.
On Thursday, January 17, 2002, at 01:06 AM, chip wrote:
> On Wednesday 16 January 2002 08:57 pm, Steven Cayford banged out on the
> keys:
>> On 2002.01.16 19:59:37 -0600 chip wrote:
>>> Let's tackle the first one first -
>> OK.
>>> On Tuesday 15 January 2002 10:20 pm, Steven Cayfo
George
Have you tried changing " and transactions.ExtractID=bib_extract.E_ID "
to
" and bib_extract.E_ID = transactions.ExtractID "? You have the join, but
it's reversed.
The transactions table is the primary determinant of the query,
"Transactions.Course_ID = '210' " , thus fields returned
I found the problem in the form and fixed that, but now anytime I want to
submit the form by hitting enter, it acts like it's reloading the page. What
would be the cause of that? When I click on the submit button the
verification and program function correctly, but when I hit enter, they do
not.
On Friday 18 January 2002 00:25, James Kupernik wrote:
> I found the problem in the form and fixed that, but now anytime I want to
> submit the form by hitting enter, it acts like it's reloading the page.
> What would be the cause of that? When I click on the submit button the
> verification and p
Sorry about that
Hi $person, here are the catalog requests\n";
$db = mysql_connect("localhost","login","password");
mysql_select_db("countryloft");
$result = mysql_query("SELECT * FROM catalogs");
echo "\n";
On Friday 18 January 2002 01:30, James Kupernik wrote:
> Sorry about that
>
>
> if ($submit) {
This is probably where your problem is. Which browser are you using? To fix
this you could include a hidden element in your form and check for this
rather than checking for "submit".
> > You ca
Ok i'm new to this stuff so maybe someone can give me a quick pointer on
this one.
I want to add a new column / Field with the date to a database every time
the submit button is clicked.
PHP doesn't seem to support the ALTER TABLE command from mysql or the ADD
command.
Is there a way to do this
Keith,
You're building it upside down! If your design relies on adding columns to
store data you will quickly run out of columns.
More typically when you submit data you add a row of information to a
database, not another column. Database design and normalization are topics
which are too big
Other than what sounds like a bad design decision, you can:
$query = "ALTER TABLE mytable ADD COLUMN newcol INT UNSIGNED AFTER
anothercol";
mysql_query($query) or die("Error: ".mysql_error() );
-Original Message-
From: Keith Webb [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 17, 200
I can't figure out where I have gone wrong. Maybe not enough sleep, anyway this is the
simple query:
$query = "SELECT * FROM xp_topics WHERE artist='artist'ORDER BY topicid DESC LIMIT
0,1"; $result = mysql_db_query($query) or die("Select Failed!");
echo("Latest Artists : $topictext ");
It says
I've been using the OCI8 extension and have a question about the Persistent
Connections.
While debugging the site, I will run into the following error (paraphrased):
BeginSession: too many processes running
etc...
I have my scripts setup in the following way:
I never do call OCILogOff(...
Barry,
Add >> or die( mysql_errno() ." : ". mysql_error() ) <<
It could be you don't have any data, also there's no space between /artist'
and ORDER BY.
Also trim off everything after 'artist' and see what you get. If it still
doesn't work there's something wrong with the fiel
I ended up rewriting it again and somewhere I must have done something wrong
as it now works. Thanks guys. Maybe I should think about more sleep.
- Original Message -
From: "Miles Thompson" <[EMAIL PROTECTED]>
To: "Barry Rumsey" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, Janua
I have a client that would like to store credit card
information online. I have worked with shopping cart
type systems in the past, but never stored CC info.
What is the best way to do this? I was thinking that I
can write and read using include() to a directory that
is not available to the web.
Hi olinux,
If I understand what you are saying...I would use mcrypt and encrypt the
stored info, keeping the KEY and IV in a separate location for when you need
it. Chances that anybody will break the triple des encryption without the
KEY and IV are slim to none. That way, you don't have to freak
post your code
-Original Message-
From: James Kupernik [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 17, 2002 8:23 AM
To: [EMAIL PROTECTED]
Subject: [PHP-DB] password problem
I'm creating this form where the person needs to enter a password to move
on. When they enter the password
I am a serious newbie (like less than two weeks & never programmed before),
so I hope my code doesn't suck too bad & this isn't a really bad question...
but here goes...
I would like to modify this query so that it doesn't return the username,
realname, and office results each time. The way the q
Andrea,
> I am a serious newbie (like less than two weeks & never programmed before),
> so I hope my code doesn't suck too bad & this isn't a really bad question...
> but here goes...
>
> I would like to modify this query so that it doesn't return the username,
> realname, and office results each
Hello.
I am wishing to store all mysql querys in a single file and when they needed
to be ran call them using include "mysql.php";
But I keep getting errors saying that its an invalid number of mysql
resoruces or something like that when I bring the query into the atuual file
and dont run it from
Hi Guys,
application can edit records from db in IE fine but in NS 4.77 i get
suppratic error messages:
Unknown persistent list entry type in module shutdown (14) in Unknown on
line 0
some records i can edit, most i can't without receiving the above error
message
PHP 4.06
ADODB 1.65
Netscape
Hi olinux,
This is what I ended up doing. This will work if you have a PHP that was
compiled with mcrypt as it is, just pass the info to your encrypt and
decrypt functions. The key I used is 123 but you can use something
different. The Initialization Vector is hard coded, but there is a function
Hi,
I know this must sound like a really easy question, but im trying to create
a simple web poll, where you choose your answer from a radio button and then
click submit.
On submitting I would like to update a sql table depending on what box the
user clicked.
How can I make it so it increments
Jacob,
I think you can do something like
UPDATE tablename SET fieldD=fieldD+1 WHERE pollTitle='title';
or similar?
check the manual on updates and mathematical functions probably
-b
// -Original Message-
// From: Jacob Wyke [mailto:[EMAIL PROTECTED]]
// Sent: Friday, 18 January 2002
On Thursday 17 January 2002 08:00 am, Steve Cayford banged out on the keys:
> Sorry, I think I got you off track. In this case you *do* want to set
> $pic from the GET vars. I guess how I would do this would be something
> like this:
>
> if(! isset($pic)) { $pic = 0; }
Thanks, that fixed that par
The next part I tackled and won! Hard to believe actually, but I got the
problem with last page fixed.
On Tuesday 15 January 2002 10:20 pm, Steven Cayford banged out on the keys:
> To find out if $new_pic pointed to a valid image you would probably need
> to do a "select count(*) from ab" to get
47 matches
Mail list logo