it needs to be scheduled.
- on *nix, a cron job will do it
- on mac, a program like iDo Script Scheduler (combined with a simple
applwscript) will do it
- on windows, i believe there are tools to do this, but not sure what they
are
alternatively, i set up a HTML page as my 'start' page on IE, wh
I want to have a php script processed on a daily (eg 9am) interval. is
there some way to automate this from within the script or do i need to
schedule this with an external app?
has anyone had any experience with this previously?
thanks
Daniel
--
PHP General Mailing List (http://www.php.net
I forgot to write I run on a win98, so no shell :)
So what?
Makis
> -Original Message-
> From: Evan Nemerson [mailto:[EMAIL PROTECTED]]
> Sent: Monday, June 03, 2002 1:52 AM
> To: savaidis; [EMAIL PROTECTED]
> Subject: Re: [PHP] still running the old version after recompiling??
>
>
> Do
Hi All,
I have being working on PHP perl compaitable regular expressions for the last
month and cannot work out how to program a preg_match_all that will get the
"file.html" from the following examples:
The preg_match_all I have below only works for but not for
the other variations..
On Thursday 01 January 1970 08:00, Ricardo Fitzgerald wrote:
Your clock is broken!
> I'm having troubles trying to insert form data into a mysql db, the
> thing is my client wants table data to be splitted, I mean some data
> comes from the first form, and the rest from another form.
> Then this
Hi,
I'm having troubles trying to insert form data into a mysql db, the
thing is my client wants table data to be splitted, I mean some data
comes from the first form, and the rest from another form.
Then this is a portion of the php script.
// Add together proper fields to enter birth date
$fe
PHP has a built-in mechanism for logging high-watermark memory usage by
scripts. Make sure you compile PHP using --enable-memory-limit then you
can modify your Apache LogFormat and stick %{mod_php_memory_usage}n in
there somewhere which will be replaced with the peak memory usage for that
script
JH:
On Sat, Jun 01, 2002 at 10:29:38PM -0400, John Holmes wrote:
> Is there a way to determine the overhead or memory usage of a PHP script
> as it runs?
You could do some sort of exec() or system() type call. For example, on
a NetBSD (and similar unix type machines) you can do "ps -o rss,com
On Monday 03 June 2002 04:42, Alexander Skwar wrote:
> Justin French wrote:
> >my aim will be to strip out anything that doesn't at least LOOK like like
> > an email address.
>
> Well, instead of coming up with some "clever" regexp, I'd suggest to
> completely dump syntax checks. Instead, I only
Hey John:
On Sun, Jun 02, 2002 at 12:10:27AM -0400, John Holmes wrote:
>
> What I'm looking at is if each include .html file is 50K, am I loading
> 100K into memory and then running the script, or running the script and
> only loading the appropriate 50K into memory when it's needed?
As of 4.0.
I was getting a typical 2.5% more for pure PHP with the original order -
switching them increases the difference to about 6.5% more for pure PHP.
Make sure you run it several times before drawing any conclusions, BTW.
Strange...
Bogdan
Marcelo Leitner wrote:
>On Mon, Jun 03, 2002 at 05:18:50
Why can a user force php to create a session he's giving the name in the
URL?
Do you want me to list an half a dozen ways to get rich now with this
holes?
Does anyone understand the malice of this?
Anyone can offer you a click on a session he's going to visit later and
hijack from you?
Anyone can
Hello,
On 06/02/2002 01:13 AM, Justin French wrote:
> Hi,
>
> I know that there are more complex functions and classes out there for
> validating email address', but some of them do return "invalid" on
> *technically* valid, although uncommon email address', so all I want is a
> simple test for:
That REALLY is a tricky one because it's documented the way you wrote it
in most places, except where you (and I) should've looked:
http://www.php.net/manual/en/configuration.php
The trick is that you must remove the equal sign.
Bogdan
Tim Thorburn wrote:
> Hi,
>
> I'm trying to set a PHP in
This whole discussion made me really curious - so you might want to
check the attachments (access mixtest.php) for a very surprising result
(please note mixed.php and pure.php are exactly the same size so this
doesn't affect the test).
Bogdan
Marcelo Leitner wrote:
>On Mon, Jun 03, 2002 at 0
> Point well-made. I suppose doing it the mixed way might have repercussions
> later on if/when the site grows. Perhaps while the code is still fresh in
my
> mid, it might be worth the effort to separate it.
>
> However, for a good part of the site, I've used CSS for appearance
details,
> and cont
I fell for this some time ago - but the trick is that
1. You don't do for ($i=0; $i<999; $i++) { echo "Line $i\n";
} in real life - you do stuff, call object methods, run queries,
whatever, and in between those you have both html and php - and the
remote machine waits for you to do all
Here's a newbie question. I installed the Windows CGI InstallShield
version of PHP to use with the MS Personal Web Server I already have
working perfectly on my system.
On restarting my PC and trying a very simple php script, I get the error
at the bottom of this email. Unfortunately there isn'
No, it doesn't - just go with whatever's simpler for you... and with
what matches your application better - I don't think this does matter at
all.
Bogdan
Andre Dubuc wrote:
>That's what I meant. I was referring to verification/validation scripts for
>user inputs. I've made a separate page th
JavaScript does something in this direction - you can use a little
JavaScript trick to get it - check some JS docs and mail me if
interested and unable to make it. What you basically need to do is use a
link such as Continue or, more transparent,
create an intermediary page which only contains
I was wondering if theres a server side variable that i can find the web brower
resolution.
YES
It's been the basis of everything I've done so far with sessions.
Justin
on 03/06/02 9:05 AM, Glenn Sieb ([EMAIL PROTECTED]) wrote:
> At 08:32 AM 6/3/2002 +1000, Justin French posted the following...
>> sitepoint.com has a nice one on restricting pages with login/sessions, etc
>> by Kevin
> I've noticed that many people on the list code in 'pure' php, i.e.
>
> print "";
>
> // etc
> ?>
Personally, it depends on what I'm doing. I find that excessive use of
in my code gets distracting so if I need a lot of php code I
will usually put the straight html into echo/print str
Thanks Michael,
Point well-made. I suppose doing it the mixed way might have repercussions
later on if/when the site grows. Perhaps while the code is still fresh in my
mid, it might be worth the effort to separate it.
However, for a good part of the site, I've used CSS for appearance details,
I would ask the question "How much HTML before you break out of PHP and into
HTML". My answer is "any". Surely you're making the engine work just to echo
stuff out? But are you asking for more by making it jump in and out between
all those tags?!
Short tags ...
... easier to read in Mixed? I t
That's what I meant. I was referring to verification/validation scripts for
user inputs. I've made a separate page that runs these routines. I have a
feeling I should have incorporated them on the user input page . . . but
does it really amtter if they're on another page?
Andre
On Sunday 02
However...
>From the point of view of someone who has worked in a company where diesign
is separated from development, it is much better to have separate files with
HTML templates with special markers (in the library I use, it is HTML
comments ) so that the two processes are adequately
separated.
I need to do some encryption/decryption of data in PHP. I don't
need anything heavy duty. Just some scheme that obscures strings
in a non-trivial manner.
I am on a shared hosting site which doesn't have the mcrypt suite
installed with PHP (& they won't install it).
Does anyone know of any func
I'm not sure what you mean... Is it checking that you fill in the
correct values via PHP or that the submission works - or something else?
Bogdan
Andre Dubuc wrote:
>Thanks Bogdan,
>
>That's what I thought, but I was beginning to feel 'guilty' the more I
>understood php. It seems to me, from
On Sunday 02 June 2002 08:13 pm, you wrote:
> On Sun, Jun 02, 2002 at 07:55:09PM -0400, Andre Dubuc wrote:
> > I've noticed that many people on the list code in 'pure' php, i.e.
> >
> > > print "";
> >
> > // etc
> > ?>
> >
> > Since most of my code is a mixture (the early stuff is 'mixed' html +
Thanks Bogdan,
That's what I thought, but I was beginning to feel 'guilty' the more I
understood php. It seems to me, from my limited experience, that there's much
mor chance for error using 'pure' php (as in forgetting ' or " or closing
with ; -- but . . .
Actually I've found that the 'mixe
Hi,
I'm trying to set a PHP include directory for one of my sites. I'm on a
shared hosting system, so I don't have access to the php.ini file.
My plan was to do it using a .htaccess file in Apache - however I must be
doing something very much wrong, as it isn't working.
Here is what I've tri
No *real* reason - just two not-so-important ones:
1. Clarity
Please compare these two:
-- "MIXED"
-- "PURE"
\n");
$fldcontent=$myrow[0]?$myrow[0]:"no data";
echo("\n");
?>
The second is much easier to read and understand, you must agree.
2. Speed
There's an urban legend saying
$Tags['issue-name']. So I could print it out. Something like, print
"$Tags['issue-name']\n";
I was able to get a numerical representation of the array like, $Tags[5] and
the value of that tag was "RED HAT", but then I would have to know what the
position of the data I am looking for in the array.
I've noticed that many people on the list code in 'pure' php, i.e.
";
// etc
?>
Since most of my code is a mixture (the early stuff is 'mixed' html + php),
I've been wondering why code in 'pure' php? Is there some compelling reason
(that I'm unaware of) for doing so? Should I rewrite all my e
At 08:32 AM 6/3/2002 +1000, Justin French posted the following...
>sitepoint.com has a nice one on restricting pages with login/sessions, etc
>by Kevin Yank.
http://www.WebmasterBase.com/article/319
Is that the one you're referring to, Justin? It seems pretty good.. :)
Glenn
---
The original
The next time I stare at something so long I can't think straight remind
me to take a walk and pull out Rasmus' book! Page 121 array_chunk is my
friend!
Code is ugly, but I am smiling now! Thank you everyone!
$policy = array_slice ($fields, 18, $lineCount);
// I am taking the array from pos
Do "echo $PATH" from a shell. This will output a list of several folders,
seperated by a semi-colon. Check each of these folders for a file named
"Php". Rename to "php". That should do the trick.
On Sunday 02 June 2002 11:01 am, savaidis wrote:
> I have one similar problem.
>
> I had a direct
> Won't that treat all radio buttons on the page as one group, instead of
> being separate groups for each form?
No - the tags "enclose" the data that is being submitted -
nothing outside of the tags will reach the script that handles the request.
Mikey
--
PHP General Mailing List (http://w
> Has anybody here used an online turoral that they feel is
> good for a newbie or has done wonders in helping you on when
> you were learning php? if so please send me the website name / URL.
http://www.devshed.com/Server_Side/PHP/UserAuth/page1.html
I found this one quite good - not so m
sitepoint.com has a nice one on restricting pages with login/sessions, etc
by Kevin Yank.
Justin French
on 03/06/02 8:38 PM, r ([EMAIL PROTECTED]) wrote:
> Hey Everyone,
>
> Been going through the manual and the book "PHP BlackBook" and am totally
> confused about sessions.
>
> Searched goog
Hey Everyone,
Been going through the manual and the book "PHP BlackBook" and am totally
confused about sessions.
Searched google and found a couple of places that seem to be offering
lessons but dont know which is good as there are so many results.
Has anybody here used an online turoral th
Do some error checking. You're turning off all the errors produced by the mysql
statements, so how
are you supposed to know what's wrong?
You could also try:
$db = mysql_select_db($db_name) or exit(mysql_error());
I'm not sure if mysql_error works for selecting the db, but it couldn't hurt to
Ok, this did not work, but I have a new idea. From the top
1)Read in the csv file, take the first 18 records and insert them into a
temp db.Ie: $output = array_slice ($fields, 0, 17);
2)Then do a count on the line to see how many records are after 17 and
somehow loop through them 34 at
Justin French wrote:
>my aim will be to strip out anything that doesn't at least LOOK like like an
>email address.
>
Well, instead of coming up with some "clever" regexp, I'd suggest to
completely dump syntax checks. Instead, I only check if the host has a
MX entry associated. If not, then t
Hi Justin:
On Sun, Jun 02, 2002 at 02:13:40PM +1000, Justin French wrote:
>
> (anything)@(anything) followed by 1 or more (.anything)
So, what ereg expressions have you tried thus far? It's far cooler to
come to the list saying, "I tried x, and it's generating error y, does
anyone have an id
I have one similar problem.
I had a directory "Php" under my "root" directory that was the root for
Apache.
Then I rename "Php" to "php" but after restart, reset ecc - some months now-
still recognize only "Php" and NOT "php".
What's wrong?
Makis
> -Original Message-
> From: Andy [mai
After playing around with this further, here is more functional pseudo-code
... Primary change in the placement and method of the waidpid routine.
I'm still open to comments on this ... Otherwise, I hope this snippet is
useful to someone! : )
// run forever if necessary
set_time_limit(0);
// de
Look into cross-tab queries (I think that's what they are called). There
is a good article on Devshed.com about it. You can do a query like this
SELECT SUM(IF(Gender='M'),1,0)) AS Male, SUM(IF(Gender='F',1,0)) AS
Female FROM table
That'll give you two columns, one named Male, one named Female, i
Hi,
I'm a newbie, so please have mercy on my silliness...
I've checked my formats, and can't seem to understand why I can connect to the db, but
not select the db that I want to use. The following code always returns the "Couldn't
select database" error.
If I use the mysql monitor, I can s
"Michael Davey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> You could give the button the same name in each form - only the fields in
> between the tags is actually submitted, then put a hidden
field
> in the form that uniquely identifies the data being s
Hi list,
Sorry if this is a off-topic, but I really don't know where to begin. I
have a mysql database with about 20.000 records, now I need to build a
statistics panel to show for example how many of this record are male,
female, lives in determinated city, school graduation etc, everything
For tips on doing these things, read this faqt:
http://www.faqts.com/knowledge_base/view.phtml/aid/124
Regards,
Philip Olson
On Sun, 2 Jun 2002, Andrew Brampton wrote:
> Hey try it, it works when are running the PHP Module in apache.
> I have a server with proxy.php yet I access it via
> my
Michal Dvoracek wrote:
>when creating new session:
>
>define('S_USER', 0);
>define('S_USER_ID', 0);
>define('S_USER_NAME', 1);
>
>session_start();
>$_SESSION[S_USER][S_USER_ID] = 1;
>$_SESSION[S_USER][S_USER_NAME] = 'Michal';
>
Hm, you're defining a session variable called 0? Because PHP will
Hey try it, it works when are running the PHP Module in apache.
I have a server with proxy.php yet I access it via
myserver.com/proxy/whatever and it works with no special changes to the
config files.
Andrew
- Original Message -
From: "Adrian Murphy" <[EMAIL PROTECTED]>
To: "Andrew Brampt
Hi,
I am compiling PHP 4.2.0 on a RedHat 7.1 system with mnogosearch 3.2.3. I am
running into a problem that I have not seen on my other RedHat systems with
the same configuration (except Redhat 7.2 instead of 7.1), and that is that
the link does not work because there are some symbols that are m
You have to define the constants on each page. The second page doesn't
know what S_USER, S_USER_ID, or S_USER_NAME are...unless you define them
again.
---John Holmes...
> -Original Message-
> From: Michal Dvoracek [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, June 02, 2002 3:59 AM
> To: [EM
Hi there,
I am having trouble to get a php installations working on suse72 with
following configure command:
./configure' '--with-gd=/home/andy/sw/gd-2.0.1' '--with-freetype=/usr/lib'
'--enable-gd-native-ttf' '--enable-gd-imgstrttf' '--with-jpeg-dir=/usr'
'--with-png-dir=/usr/lib' '--with-zlib'
On Sunday, June 2, 2002 at 2:53:30 PM, you wrote:
> I certainly read your reply and tried it with the session_start as the first
> line of the php secion. I have since remove the HTML etc. The script
> appears to work with out error .
session_start must be called before any output in the script
Page1:
Variables set
Page2:
User:
Password:
Does that work for you?
Normally all PHP scripts just use the same username and password for the
database. You create a "web user" that's used in the scripts. I don't
know if you don't want to / can't do this.
Just a simple script like
> whenever a URL like
> mysite.com/thumbnails/funny/4
> i called the thumbnails.php is excuted, in which you
I think if you call it thumbnails.php it won't work.
however if the script is simply called thumbnails then it'll
work.of course you then must make sure that 'thumbnails'
is parsed as php.
I certainly read your reply and tried it with the session_start as the first
line of the php secion. I have since remove the HTML etc. The script
appears to work with out error .
I was able to set session vars etc and the script completed with out error
and the session vars could be printed out
Hello Jason,
you have been right, I did a new one on a fresh php untared dir. And the new
php install is recognized.
But I am still fighting with the installation. I need freetype2 and I did
configure it ok, compiled freetype, gd2 but still I am getting a:
function: imagettfbbox() not found
Ph
just installed the win32 cgi 4.2.1 last night and discovered this strange thing with
the $to string
in the mail function.
it crashes and gives me a Server Error Warning.
where usually i could go:
$to = "Mary<[EMAIL PROTECTED]>" ;
now it wants:
$to = "[EMAIL PROTECTED]" ;
$from formatting is o
php-general Digest 2 Jun 2002 13:13:58 - Issue 1381
Topics (messages 100265 through 100309):
PHP Coding Problem
100265 by: Christopher J. Crane
Re: New to PHP- Form Validation Logic/Design Question
100266 by: John Holmes
Re: help meS.O.S...my php doesn't ascend
You're right, that wouldn't prove my point. However, you might try a
little piece of code like the following:
I hope this proves that includes are included at runtime because PHP
wouldn't know what $b and $c are beforehand. Apart from that, I'm
positive I read about it in a man page, but can
You can do this with just PHP, but I think php must be installed as a
module.
Basically place a file called thumbnails.php in your site route, then
whenever a URL like
mysite.com/thumbnails/funny/4
i called the thumbnails.php is excuted, in which you chop up the URL, and
find all your varibles...
Does anyone know exactly what the status is on the Verisign Payflow Pro
support for Windows? I've read the manual and all the user submitted
comments. I keep seeing some reference made to a "php_pfpro.dll" that
doesn't seem to exist. Is it still in development?
It seems most people just exe
Also, if you are really worried about placing too much load on the server,
you could use JavaScript to check the form submission on the client side
using the same technique...
Mikey
"Bogdan Stancescu" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> First, you
Hey all,
I was recently trying my luck at dabbling in some mod_rewrite
stuff, and I have run into numerious errors. Basically my aim is to
re-write my sites URLs so instead of being say,
mysite.com/thumbnails?type=funny&gallery=4 the URL is neat, similar to
many sites who would have somet
Hola:
Tienes la misma version de PHP en el servidor Win98?
Sabes que hay diferencias importantes en versiones de PHP mas de 4.1.0
(creo ... seguramente, mas de 4.2.0)? Estas diferencias tienen que ver con
'arrays' superglobales y 'register globals' etc.
Puede ser que una programa PHP que se e
On Sunday 02 June 2002 17:32, Andy wrote:
> Hi there,
>
> I did recompile php with different flags. Phpinfo() tells me that I am
> still running the old insatllation! I did restart apache after compiling.
> So whats wrong. Did I forget something?
>
> I did
> configure with some flags
> make
> make
Hi there,
I did recompile php with different flags. Phpinfo() tells me that I am still
running the old insatllation! I did restart apache after compiling. So whats
wrong. Did I forget something?
I did
configure with some flags
make
make install
restart apache
Thanx for any help,
Andy
--
Hi there,
I did configure php with ldap and everything worked fine!
Then I stoped apache and started it. This cause folloving error:
Syntax error on line 205 of /usr/local/apache/conf/httpd.conf:
Cannot load /usr/local/apache/libexec/libphp4.so into server:
/usr/local/apache/libexec/libphp4.so:
Hello,
i'm using sessions in my application but i found something strange.
when creating new session:
define('S_USER', 0);
define('S_USER_ID', 0);
define('S_USER_NAME', 1);
session_start();
$_SESSION[S_USER][S_USER_ID] = 1;
$_SESSION[S_USER][S_USER_NAME] = 'Michal';
when redirect on next page
75 matches
Mail list logo