Hi, I'm a newbie in php so sorry for that question!
I have a table in a html dcc and I want toinclude a file in a cell, but
that file must be random so people load a different page each time they
refresh... The basic syntax I use for the include is below now, I want to
know how to generate the
you only have one condition, then get rid of the AND in the where
> statement;
>
> Select only the fields that you need, instead of *
>
> Like this:
>
> SELECT id FROM $TBL_NEWS WHERE music LIKE '%pop%' ORDER BY name
>
>
> Peter
>
> At 03:16 PM 11/27
Hi, I need information about a simple command...
I have a DB (of course...) and I need to show only "ID" that variable
"music"contain "pop"
I found this example that is suppose to do a similar thing in a msql
query...
SELECT * FROM $TBL_NEWS WHERE music LIKE '%pop%' AND ORDER BY name
So it'
Hello, I'm trying again to ask you that question because I was not
understand.
I have a unix server hosting service, my hosting service allow me to create
web_server. Those are create for my client who have to upload differents
things. So when people are connecting to my ftp (example on IE...) th
Local to the client or local to the server?
-Original Message-
From: Jason [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 17 October 2002 3:26 PM
To: php_gen
Subject: [PHP] MySQL GMT --> Local time
My logging application is feeding a MySQL database with data records
that are time stamped w
Because the first example is not correct syntax?
I wasn't aware that the first element in a comparison could ever be left out, is it
that way in other languages?
-Original Message-
From: Peter Houchin [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 17 October 2002 2:15 PM
To: php_gen
Subject
select * from forum order by postdate desc LIMIT 10, -1
Assuming you are using MySQL of course.
See the official documentation for further assistance:
http://www.mysql.com/doc/en/SELECT.html
-Original Message-
From: Manisha [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 16 October 2002 4:
No, there isn't, and no, there probably shouldn't be, since the height in pixels that
the page will render in is dependent on client-side attributes like font size,
resolution, browser type, etc.
This might be an appropriate function in javascript, but not php.
>Any way in php to determine a
There are a couple of ways you could do it, the proper way with a regular expression,
or you could just kludge it using explode() and chucking out the stuff you did not
need.
-Original Message-
From: Shawn McKenzie [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 10 October 2002 7:43 AM
To: [
The register globals function must be turned ON in your php.ini for the first method
to work.
-Original Message-
From: Max Buvry [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 2 October 2002 2:38 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Cookie
Hi,
I use : apache 1.3.26, php 4.2.3, post
It's not impossible if the site is not opened up to full public access, and he is
using different proxy settings on each browser.
Check those.
-Original Message-
From: Chris Shiflett [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 2 October 2002 4:23 PM
To: Chris Nielsen
Cc: [EMAIL PROTECT
Not really, no. It goes well beyond the capabilities of a server-side scripting
language.
There is a java implementation in VNC that allows this capability, though.
-Original Message-
From: Rahul [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 1 October 2002 4:53 PM
To: [EMAIL PROTECTED]
Subj
Try gnuplot:
-Original Message-
From: Mike Mannakee [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 1 October 2002 2:31 PM
To: [EMAIL PROTECTED]
Subject: [PHP] image wrapper - graphs
Hi,
Does anyone know of image creation libraries that will generate graphs?
Mike
--
PHP General Mailing
What if you enclose it in single quotes?
-Original Message-
From: John Kelly [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 1 October 2002 12:36 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Can I pass the ftp transfer mode in a string?
Can I pass the ftp transfer mode in a string like ...
$filet
Check out this tutorial on the MySQL website:
http://www.mysql.com/articles/mysql_intro.html
It contains links to the basics of SQL and its syntax, as well as giving you a good
grounding in MySQL specifically.
As others have stated, most of the functionality you really need should be built int
http://www.php.net/manual/en/function.strlen.php
-Original Message-
From: Jeff Bluemel [mailto:[EMAIL PROTECTED]]
Sent: Friday, 27 September 2002 1:35 PM
To: [EMAIL PROTECTED]
Subject: [PHP] length function
I am looking for a function that will give me the number of characters of a
stri
There's no real foolproof free way of doing this, it's a fact of life that there will
always be people who do this. I wouldn't lose sleep over it.
Console yourself with the fact that for every person who does not acknowledge your
effort, there are probably 10 people who do.
-Original Messa
Does anybody know of a way to break out of a frameset while using the
following code to redirect the browser:
header("Location: http://www.anywhere.com/";);
exit();
Thanks.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-m
This is a PHP newbie trying to figure something out.
I am creating a web-app which begins with a login page and goes through the
typical user/pass validation and upon success moves to a frameset where the
application will run. The action of the login form is act_login.php. In
that script I vali
I need to generate a random number (range is not crucial) and I have been
trying to use mt_rand(). However, I am finding that is generates the same
value EVERY time. This is true whether I supple a range or not. For
example, the follow line of code generated 13 EVERY time...
$result = mt_rand(
I'm fairly new to PHP, having worked with ColdFusion in the past. Can
somebody shed some light on to the key differences between the CGI
installation and the ISAPI installation. I working with IIS on Win2k and
using MySQL for a db server. Thanks.
- Ben
--
PHP General Mailing List (http://w
I am trying to pass variables from a CGI/Perl script
to a php page. I know how to pass it through the url
(i.e. page.php?tmp=[var1]&tmp2=[var2]) but need to
know how to pass it so that the information does not
show up in the url.
Benjamin
_
ook at the following section from the fine
manual: http://www.mysql.com/doc/A/c/Access_denied.html
If that doesn't help, don't forget to mention, what you already have
tried. And please write only to one list at a time, the one which
seems most appropriate. Thanks.
Bye,
Benjamin.
PS:
I wouldn't trust a 10-above or 10-below rule, personally, unless you
weren't too concerned about the accuracy of your information.
Why don't you give Australia Post a call?
-Original Message-
From: Jason Murray [mailto:[EMAIL PROTECTED]]
Sent: Monday, 10 December 2001 10:22 AM
To: '[EMA
This would have to be the most bizarre spam I have ever read.
-Original Message-
From: Adewale.Johnson [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 6 March 2001 6:18 PM
To: [EMAIL PROTECTED]
Subject: [PHP] very urgent assistance
Dr.Adewale.Johnson.
16 Kingsway Road
Ikoyi, Lagos
Nigeria
You can simply order by that field in your SQL string...ie:
SELECT * FROM TABLENAME ORDER BY FIELDNAME;
And to switch the order:
SELECT * FROM TABLENAME ORDER BY FIELDNAME DESC;
-Original Message-
From: Rambo Amadeus [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 4 December 2001 1:15 PM
To
do you know about cerberus-ftp? how is it?
--
PHP General 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]
hey group!
i have apache installed on an win2000 machine and now i need an good and
stable ftp server! which one does i take!
thank you, ben
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To cont
Jack,
You can either check your text field with JavaScript before submitting your
form or
after on server-side with PHP. I prefer to use JavaScript because it saves a
back
and forth.
here an example of that :
http://1ppl.free.fr/scripts/javascript16.htm
For the printing function, check that :
Ahh! Excellent. Thanks for the tip!
Ben
>Date: Tue, 24 Jul 2001 16:39:56 -0700 (PDT)
>From: Philip Hallstrom <[EMAIL PROTECTED]>
>To: Ben Bleything <[EMAIL PROTECTED]>
>cc: <[EMAIL PROTECTED]>
>Subject: Re: telnetty/phpy/unixy thing
>MIME-Version: 1.0
>
>I don't remember the exact terms, but t
Hey, let me know if you figure out what the extra numbers are for... I might
have a use for this at some point.
Ben
>From: "Matthew Loff" <[EMAIL PROTECTED]>
>To: "'Ben Bleything'" <[EMAIL PROTECTED]>, "'Vincent P. Cocciolone'"
<[EMAIL PROTECTED]>
>Cc: <[EMAIL PROTECTED]>
>Subject: RE: [PHP] Z
There are a number of ways to do this. Mine is something like this:
if (has_read_perm($user_id, $file_id)) {
send_file_to_browser($file_id);
} else {
// print error message();
}
...
function has_read_perm($user_id, $file_id) {
// check db table
// return true/f
There is a PHP class someone wrote called mime_mail that makes this easy.
The resulting code using this class is something like:
// create new mime_mail object instance
$mail = new mime_mail;
// set all data slots
$mail->from= "[EMAIL PROTECTED]";
$mail->to = "[EMAIL PROTECTED]";
$m
This is not working?
echo("$server->server_num_players."/".$server->server_max_players
");
If you are trying to print out
4/4
but can't because it is evaluating it mathematically, try using the HTML
character entity for /, /
echo("$server->server_num_players/$server->server_max_players");
Hop
Yahoo uses a lot of Python. Yahoo Mail pages have extensions of .py,
indicating Python. Yahoo acquired eGroups and Google this past year, both
of which openly use Python to generate pages. They most likely use Python
in conjunction with other scripting and compiled languages.
-Ben
-Origi
Can you send some code?
-Original Message-
From: Subhrajyoti Moitra [mailto:[EMAIL PROTECTED]]
Sent: Sunday, April 08, 2001 8:41 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: [PHP] double byte problem
hi,
i am having a little problem in using php with double byte character.
In your php.ini, change the following line:
>session.use_trans_sid = 1 ; use transient sid support if enabled
to
>session.use_trans_sid = 0 ; use transient sid support if enabled
And see if that solves your problem. Also, check the change with phpinfo(),
and if nothing change
Three good articles by the author of PHP Developer's Cookbook.
Top 21 PHP progamming mistakes
By Sterling Hughes
http://zend.com/zend/art/mistake.php
http://zend.com/zend/art/mistake1.php
http://zend.com/zend/art/mistake2.php
-Ben Munoz
-Original Message-
From: Jeff Oien [mailto:[E
Yes, I subscribe to this PHP-XML mailing list, but it is very low volume.
I'd encourage anyone considering using XML/XSL/SOAP/RSS to join this list,
so that XML and SOAP can be easily used with a PHP web app environment.
I've used ASP/COM when I really wanted to use PHP, but the Microsoft S
written by someone else to be part of php-3.0.6 (!)
and adds a few functions for accessing a specialized database to
PHP.
It was intended to live in the dl/ directory.
What is it going to take to get this to work in ext/ or where-
ever it should be for php4?
Benjamin
--
PHP General Mailing List (http
On replying to SPAM:
Most of you already know this, but replying to SPAM (even if they tell you
that you can remove yourself) usually leads to more SPAM, b/c you've just
given the SPAMMERS your email address confirmed.
http://www.chugach.net/~techtips/spam3.htm
Just a warning.
-Ben
-O
Great thread. When I was changing jobs in April of 2000, a recruiter told me
that PHP is "cool and all", but there is zero demand for developers of PHP
web apps (in Los Angeles). Although I've been very productive developing in
PHP, he advised me to learn something else, b/c the demand just isn't
April,
There was a discussion like in 1999 (i remember cuz I was learning PHP
then), and Richard Lynch (i think) had a good point that splitting the list
would reduce the quality of the answers on the beginners list--PHP newbies
answering each others questions, you see.
Newbies should continue
You can check the mime type of the uploaded file.
First upload the file, as usual. Then check the mime type before copying
from the temp directory to the files directory.
If this is your form:
>
File:
Then on submission, $userfile will be your file, $userfile_name will
automatically
You can find some info here...
http://php.net/manual/en/install-windows95-nt.php
And more here...
http://php.weblogs.com/easywindows
First requirement is to have a web server (Xitami, Apache, Personal
Webserver) on your Win98 box.
Then you can run one of the installers found on one of the above
http://www.phpbuilder.com/columns/perugini20001026.php3
http://www.phpbuilder.com/columns/uwe20001116.php3
http://php.net/manual/en/ref.pdf.php
-Ben
-Original Message-
From: Conover, Ryan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 30, 2001 6:31 AM
To: [EMAIL PROTECTED]
Subject:
Stephen,
If this date format is coming from a MySQL database (frequently the case),
you might want to look at the date formatting functions of MySQL.
http://www.mysql.com/doc/D/a/Date_and_time_functions.html.
ex. select DATE_FORMAT('1997-10-04 22:23:00', '%W %M %Y');
One drawback is that thi
Make sure you are not forgetting to include $action as a hidden input, so
your script can know how to process.
, for example
-Ben
-Original Message-
From: Jeremy Bowen [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 23, 2001 12:17 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Multiple Page
I want to run a query on a database and export the recordset to a
spreadsheet, preferably Excel native.
The box is on a Win32 OS, so I can instantiate a Excel COM object (similar
to the PHPBuilder COM article), and use the COM methods to create an Excel
file.
Or, I can fopen and fput a CSV fo
// get a web page into an array and remove html
// file() returns an array, which you can then loop through
$fcontents = file ('http://www.php.net');
while (list ($line_num, $line) = each ($fcontents)) {
// if preg_match the weather text you are looking for
// preg_replace a
Did you mean this?
-Ben
-Original Message-
From: Rasmus Lerdorf [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 17, 2001 11:52 AM
To: Phil Labonte
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Two things
> When I get a list of items from a database I would like to display them
with
>
You probably want to suppress the error message with an @ symbol. Try
putting an "@" before the function calls that give you errors.
This suppresses the error function. Many functions return FALSE if
unsuccessful, so you can test and supply your own error message.
If you find yourself d
wing mean or should I ask how
does it work?
$row->user_id;
Is it somehow relate to the following?
$row["user_id"];
I tried to look for this in the manual but without any luck... perhaps I'm
going blind ;)
SED
-----Original Message-
From: Benjamin Munoz [mai
http://www.php.net/manual/en/function.mysql-fetch-object.php
Modified example from the manual above...
user_id;
$name = $row->name;
// print them out if you want, or store them in an array to return
if this is a function
print ("$name\n");
}
mysql_free_result ($result);
Correction:
Inside X.php, you have some authentication code. Maybe something simple as:
-Ben
-Original Message-
From: Benjamin Munoz [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 16, 2001 4:20 PM
To: 'Miles Thompson'; [EMAIL PROTECTED]
Subject: RE: [PHP] How to keep un
Miles,
If you can save 2.htm as 2.php, use some authentication code.
Story.php becomes
Inside X.php, you have some authentication code. Maybe something simple as:
Inside story.php, set $valid to true
Now accessing 2.php directly means that $valid is valid and you'll be
redirected to story
Ade,
What kind of string? What do you want to do with them?
-Ben
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 16, 2001 2:18 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Strings??
Quick Question.
I have a form which has 10 fields, is there
101 - 157 of 157 matches
Mail list logo