I'm having a prowith determing a time interval. I need to find out how many
seconds, minutes, days have passed since a cpecific date (1.1.1980.), but when I
pass that dade to a time stamp , I get 1983.315529200. How am I suposed to
handle the year (1983.) o there is smething else ? I think the
You could insert a ternary operation...
($order?$order:defaultfield)
Is the same as:
if($order)
echo $order;
else
echo defaultfield;
...
$result = mysql_query(SELECT
articles.title,vote.votes,vote.total,articles.date,staff.firstname,artic
les.content,articles.id FROM
Hello,
We are using ezmlm mailing list on our server.
We want to make the mailing list archive available on our website. How can
we do this ?
any help will be highly appreciable.
thanks
cp
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
You have been specially selected to qualify for the following:
Premium Vacation Package and Pentium PC Giveaway
To review the details of the please click on the link
with the confirmation number below:
http://wintrip.chn.net
or
http://wintrip.my163.com
Confirmation Number#Lh340
Please confirm
Ok if you have a query string from like file.php?bob=managerphil=employ
how do i split the bob=manager and phil=employ dynamically?
because i may have 2 or 3 elements and i just want to sepearte them all and
access them via an array such as if ($var[bob] = manager)
etc so a loop that would
Hi
I have a little Problem with include.I want to include a txt file in every php file on
the server but some php files are in other directories and dont include this txt file.
Example :
Url for the txt file : www.domain.com/include/incl.txt
So www.domain.com/index2.php includes the txt file
Is most performant for out a sting use
echo or print ?
and if I have more print command ex:
print aaa,
print ;
Is best use a single command with a very long string ?
Thank's michele Schiavo
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For
I have a site where ppl can upload their text-based ideas in real
time, so that I have new records in db every day. When I did
uploading by hands and had over 200 files on that site I distributed
all site content in downloadable for of zipped win-help formate.
Well, I don't think that I can
hi all,
has anyone else had problems with specifying session_name causing data not
being input into session variables?
For example:
session_name(test);
session_start();
session_register(count);
count++;
causes count not to increment whereas
session_start();
session_register(count);
count++;
In article [EMAIL PROTECTED],
[EMAIL PROTECTED] (Aaron Moore) wrote:
Ok if you have a query string from like file.php?bob=managerphil=employ
how do i split the bob=manager and phil=employ dynamically?
because i may have 2 or 3 elements and i just want to sepearte them all and
access
You can use MySQL. Take a look at the ezmlm homepage, and check the ezmlm
mailinglist archive..
Pulling data out of a MySQL table is easy.. if you don't know how, just
look at some tutorials (www.devshed.com) more links can be found at www.php.net
Bye,
B.
At 20:28 8-9-01 +, crorepati
G'day folks,
I have a site just about ready to go on-line. All my local testing has
worked like a dream - but the cURL support on the hosting provider is
partially broken.
Actually using curl_init()...curl_exec() etc. on my box to contact remote
URIs (both over HTTP and HTTPS) has worked from
I want to include a string into a PNG by ImageTTFText(),
where some of the chars are encoded in BIG5.
I have found the revalent TTF for BIG5.
The output really gives some Traditional Chinese chars,
but the chars are not those I want.
(I think this problem also exist in Shift-JIS encoding.)
hello
How do I retrieve the messages from the list archive and how do i store the
data in text files/database .
Pl. help me out.
thanks
cp
B. van Ouwerkerk writes:
You can use MySQL. Take a look at the ezmlm homepage, and check the ezmlm
mailinglist archive..
Pulling data out
Hey all,
If anyone else out there is using Smarty as templating engine, how do you put
JavaScript into the template? It seems to barf on the opening and closing
braces of every JS function, rendering JS totally useless. I must be missing
something.
ad.
--
PHP General Mailing List
Well hers teh perl version of the the parser... how do i convert this to php
$tmp = $ENV{'QUERY_STRING'};
@pairs = split(//, $tmp);
foreach $item (@pairs) {
($key, $content) = split(/=/,$item,2);
$content =~ tr/+/ /;
$content =~ s/%(..)/pack(c,hex($1))/ge;
$fields{$key} = $content;
}
--
http://php.net/parse_str
On Sat, 8 Sep 2001, Aaron Moore wrote:
Well hers teh perl version of the the parser... how do i convert this to php
$tmp = $ENV{'QUERY_STRING'};
@pairs = split(//, $tmp);
foreach $item (@pairs) {
($key, $content) = split(/=/,$item,2);
$content =~ tr/+/ /;
I'm trying to get a count of the number of records in a database that have
the keyword cat, for example. Below is the original code; I added the
query with count at the bottom of this code but it doesn't seem to be
working. I just get a return of 4 which doesn't correspond correctly with
the
I am looking for general a function to that would render user input
harmless.
I would write my own but don't know what to strip from the input that could
make it potentially damaging on linux boxes. I need to accept email and
phone numbers.
Thanks in advance,
Kevin
--
PHP General Mailing
Wow... ok now i get it.. thanks guys
Aaron Moore
Michael Kimsal [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Aaron, CC Zona wrote before that:
If track_vars is on (always true if version = 4.0.3), then the global
vars
$HTTP_GET_VARS['bob'] and
It is an operator in PHP: %
ie. echo 3 % 2;
-Rasmus
On Sat, 8 Sep 2001, Ville Mattila wrote:
Hi folks,
I found this kind of formulae which should calculate the distance between two points
on earth:
tc1=mod(atan2(sin(lon1-lon2)*cos(lat2),
hi,
The long explanation is below the summary.
SUMMARY
page1.php
Header(location:page2.php)
page2.php
HTML link to page3.php
page3.php
REFERER=page1.php
But in page3 i WANT to see page2.php as REFERER.
So i suppose i must change something in page1. But what?
I have a problem I am trying to set up a credit card form for worldpay
And in the address field that I have to send to them it has to go in
a textarea textarea cols=30 rows=4 name=address/textarea
So when you fill this in it would look like this
address
city
state
Now this works fine for
Hi,
What is a callback in preg_replace_callback(...) ?
how can I use it ? can anybody give me an example ?
Thanks,
Arash
--
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
when i submit a form and try to have it post a cookie in the php thing i get
this error message:
Warning: Cannot add header information - headers already sent by (output
started at /usr/local/www/data/vi2dev/root/layout/functions.php:167) in
/usr/local/www/data/vi2dev/root/admin/manager.php on
Saturday, September 08, 2001, 5:40:46 PM, you wrote:
AM when i submit a form and try to have it post a cookie in the php thing i get
AM this error message:
AM Warning: Cannot add header information - headers already sent by (output
AM started at
You probably have differing versions of MySQL compiled into PHP and what you
are actually *running* on your computer.
Re-compile PHP and be sure to use --with-mysql=/path/to/your/mysql/source
That source *MUST* match your running MySQL server.
Watch the configure output messages, and be sure you
You may need to escape it with file\\ name for the shell...
Only I woulda thought PHP would take care of that...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little
You'll have to get a new version of php_dbg.dll from PHPEd, I think...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
-
take out the header, and see if you have any error messages.
I'm also willing to bet that cdpf_open() returns some special values for
error -- Your code should check that.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy
You'll have to use the function to find out if the function is defined.
http://php.net/function_exists
You may want to mess with method_exists and try to define it as a method
rather than a global function, which is what I think you are doing at this
point.
--
WARNING [EMAIL PROTECTED] address
You can probably do a CGI install and only put the directives in your
.htaccess or inside your httpd.conf VirtualHost block.
For the Module, there's no way to Load/Unload for different Hosts.
You could do the LoadModule and only have the AddType in *your* Host, but
the Module itself would be
There's a Un*x utility for automagically doing this, but it leaves the new
file blank, almost for sure...
man logrotate
Can we safely assume no *other* PHP script is going to be trying to write to
this chat file while you're messing with it? If not, you really need to
move to a database
Use the MySQL function to_seconds or whatever it is.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Original Message
You probably won't be able to measure the difference unless you are doing
10,000 print statements...
Optimize the things that are slow, not the things that are already fast.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music?
Options:
Increase the settings in MySQL that limit how many databases can be open at
once.
Decrease the number of Apache children running.
Basically, as long as you have more Apache children than MySQL connections
available, you can get this message.
Actually, have a few spare MySQL
http://php.net/zlib
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm
- Original Message -
From: Brack [EMAIL
Add *ANOTHER* variable in the header(Location:) code that says
redirect=1
In your page3, do:
if($redirect){
$menuID = $foo;
}
else{
$menuID = $bar;
}
Where foo comes from the location, but bar comes from page2.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL
That '4' you see is that this is the FOURTH thing you've asked MySQL to do
in this script.
You need to use http://php.net/mysql_result or other similar function to get
your actual answer.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out?
You'll have to define what you mean by "currently online".
Do you mean actually waiting this moment for HTML to finish streaming to
their browser?
Or do you just mean, in my session files and not timed out yet?
Probably the easiest way to do that would be to use
Compare PHP versions from your computer ?php phpinfo();? and
http://php.net/socket
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time:
http://php.net/getenv
http://php.net/setenv
Why you want to set them in the Environment instead of just regular
variables is beyond me.
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
There are various sounds like modules such as soundex and metaphone and
suchlike.
These can ameliorate bad spelling.
Another option, if you have a limited number of types available, is to give
the user a popup menu rather than free-form box to type in.
In general, the fewer ways you can provide
Compare your ?php phpinfo();? with theirs and see what cURL differences
there are...
--
WARNING [EMAIL PROTECTED] address is an endangered species -- Use
[EMAIL PROTECTED]
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time:
Use something like this to find out what character is *REALLY* in the stuff
coming from worldpay:
for($i = 0; $i strlen($worldpay_address); $i++){
$char = $worldpay_address[$i];
if (($ord = ord($char)) 32){
echo $char[$ord];
}
else{
echo $char;
}
}
Another
Unfortunately, I can't access these settings. It's not our computer that
hosts
our website.
Regards,
Pieter Philippaerts
Richard Lynch [EMAIL PROTECTED] wrote in message
01e501c138ce$f3008300$6401a8c0@Lynchux100">news:01e501c138ce$f3008300$6401a8c0@Lynchux100...
Options:
Increase the settings
I think my question could be restated to: What characters are potentially
lethal in user input. I can do the regex. But don't know what to parse out
of the strings.
would removing \ / . do the trick?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL
Hi,
Does the new version of homesite still have the same result with php. When
I used to change anything in Design View and then went back to Edit View
the ? became ?gt. Does this still happen???
Thanks
Andonny
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail:
It really depends on what you use the user input for.
If you are just storing into a database and splashing it out to a html page
later, htmlspecialchars( ) is adequete protection.
If this is a filename, then checks for the prefix http://; and '..' and
quotes in the file name, and a base
I have a query that uses a LEFT JOIN, but the two tables have some columns
with the same name. How can I tell the columns from each table apart? It
seems that the joined table overwrites the values from the other table.
Anyone know?
Thanks.
--
Dana Holt / [EMAIL PROTECTED]
--
PHP General
Hi,
I have a simple question...
How can a space inserted to a string after the 3rd char ??
washington - was hington
Thanks :)
Andras
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To
Maybe something like:
$word=washington;
$length=strlen($word);
$a=substr($word,0,3);
$b=substr($word,3,$length-3);
$string=$a. .$b;
print $string;
you might want to test for the length of $word first
to make sure $word has more than 3 characters
--- Andras Kende [EMAIL PROTECTED] wrote:
You wrote:
I have a simple question...
How can a space inserted to a string after the 3rd char ??
washington - was hington
$str = 'washington';
$str = ereg_replace('^(.{3})(.*)$', '\\1 \\2', $str);
--
-Ryan :: ICQ - 595003 :: GigaBoard - http://www.gigaboard.net/
--
PHP General
Hello Gaylen,
I am not sure what worldpay uses as an operating system but this work
just perfect. Thanks
Saturday, September 08, 2001, 6:09:08 PM, you wrote:
Gaylen Fraley Is this under Windows? If so, it's probably passing \r\n : carriage
Gaylen Fraley return/line feed. Check for both.
A callback is when you execute a function, and you provide to it a name of
*another* function, which it will call on some data in the middle of its
task.
It's a very handy way to provide extreme flexibility in functional
languages.
For example:
function my_array_walk($array, $function){
Enrique
On Fri, 7 Sep 2001, Enrique Vadillo wrote:
I am thinking now that i'd like to make it possible that for
ANY http request received by my Apache i'd like to have a php
script executed first
I do this all the time - it offers all kinds of advantages.
This link explains why and how
56 matches
Mail list logo