|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
php-general-digest-help_at_lists.php.net
Date: Tue Nov 19 2002 - 13:07:22 CST
php-general Digest 19 Nov 2002 19:07:22 -0000 Issue 1714
Topics (messages 125036 through 125133):
Re: overwrite .txt.file?
125036 by: bahwi
Re: is this not possible?
125037 by: Jason Wong
125071 by: Mark
Re: PHP Script to remove attachments from emails and store them on the server
125038 by: Jason Wong
problems with PHP code (Please help!)
125039 by: `Yan Grossman
125041 by: Justin French
125043 by: Noodle Snacks
125045 by: Jason Wong
Processes under non-UNIX operating system
125040 by: Noor Dawod
Re: echoing date of first and last day of current week.
125042 by: Noodle Snacks
communicate with cyrus imap
125044 by: Petre Agenbag
OOP - transfering object-pointer
125046 by: Tularis
125047 by: Tularis
125099 by: Hatem Ben
problem with code (almost fixed)
125048 by: `Yan Grossman
125049 by: Noor Dawod
125056 by: Tularis
125060 by: Noor Dawod
Looking for compiled Windows PHP installation with multistring fts support
125050 by: Simon Dedeyne
125108 by: . Edwin
Re: Swear word substitution
125051 by: Craig Donnelly
Re: speed comparison
125052 by: Marek Kilimajer
Display character 'x' times
125053 by: Tjoumaidis Tasos
125058 by: Khalid El-Kary
125059 by: Tularis
125061 by: Neil Freeman
125062 by: Steel
What is the best site for PHP news, articles, resources etc....
125054 by: Phil Schwarzmann
125057 by: Tularis
125106 by: . Edwin
Has anyone used O'Reilly's "Safari" online book thingy for PHP/MySQL?
125055 by: Phil Schwarzmann
125081 by: Jason Sheets
Loooooooooonnnnnnnnnnggggggggg
125063 by: Hacook
125064 by: Jon Haworth
125065 by: Justin French
125067 by: Marek Kilimajer
125070 by: Hacook
125074 by: Marek Kilimajer
Re: Display character 'x' times - Solved
125066 by: Tjoumaidis Tasos
Re: post files array and registered globals off
125068 by: Marek Kilimajer
Have fun! 3 Days for free! or for one month! every day 24 hours!
125069 by: hotstuff.jonnycam.zapto.org
Misbehaved Script...
125072 by: Kondwani Spike Mkandawire
125104 by: . Edwin
Re: New commercial software needs beta testers
125073 by: Paul Nicholson
125112 by: . Edwin
Free MySQL Hosting :)
125075 by: PHP Mailing List
125080 by: Adam Voigt
125114 by: Daniel Masson
Re: Distance Based on Zip Code
125076 by: UberGoober
New Site to submit your scripts to..
125077 by: PHP Mailing List
Re: How I Got PHP4.2.2, Apache 2.0, mySQL and RedHat 8.0 to work
125078 by: Adam Williams
catching a robot or spider
125079 by: Wilbert Enserink
test
125082 by: shi ziye
125098 by: shi ziye
125109 by: Ernest E Vogelsinger
about processing time of function INCLUDE
125083 by: Bryan
125084 by: Bryan
125128 by: 1LT John W. Holmes
Capturing multiple select with Javascript - nearly there
125085 by: Phoebe Bright
125100 by: Ford, Mike [LSS]
New generation of PHP Program, reaction to ASP.NET
125086 by: shi ziye
125088 by: 1LT John W. Holmes
125091 by: shi ziye
125092 by: 1LT John W. Holmes
which PHP debugger?
125087 by: Otakar Kverka
125089 by: bbonkosk.tampabay.rr.com
125090 by: Adam Voigt
date
125093 by: Edward Peloke
125094 by: Support . Fourthrealm.com
125095 by: 1LT John W. Holmes
Expert Paid Help Needed
125096 by: Steve Buehler
125101 by: Jome
Are objects considered global or do they need registered in a session?
125097 by: Phil Schwarzmann
125102 by: Ernest E Vogelsinger
Download File
125103 by: Michelle
125105 by: Adam Voigt
125107 by: Ernest E Vogelsinger
125116 by: Van Andel, Robert
Re: Getting info from users comp?
125110 by: . Edwin
templates
125111 by: Adam
125113 by: Jonathan Sharp
125115 by: Adam
125123 by: Ernest E Vogelsinger
125127 by: Adam
ACT Based Contact Management System
125117 by: Craig
125120 by: Brian McGarvie
Threads/Processes under Windows
125118 by: Noor Dawod
making php and perl talk to each other...
125119 by: Kelly Meeks
125121 by: 1LT John W. Holmes
125122 by: BigDog
Returning an array in a function
125124 by: Van Andel, Robert
125125 by: Ernest E Vogelsinger
125129 by: UberGoober
PHP SAPI modules
125126 by: Chris Edwards
125131 by: UberGoober
isapi mod on iis
125130 by: Chris Edwards
new php version
125132 by: Richard Pijnenburg
problems compiling imap-support with kerberos
125133 by: Jochen Kächelin
Administrivia:
To subscribe to the digest, e-mail:
php-general-digest-subscribe
lists.php.net
To unsubscribe from the digest, e-mail:
php-general-digest-unsubscribe
lists.php.net
To post to the list, e-mail:
php-general
lists.php.net
----------------------------------------------------------------------
attached mail follows:
Just open the file like any other time, using w+ (I believe, check the
link above) and then use fputs
That'll overwrite it. You may want to check it to see if it exists first,
http://www.php.net/file_exists
--Joseph Guhlin
http://www.josephguhlin.com/
Web Programming / Unix Administration
PHP/Perl/MySQL/Unix
Tox wrote:
>i seeked for the command that would have let me overwrite .txt file, but i
>didn't find it. is there such an opportunity?
>
>Tox
>tox
ut.ee
>Estonia, Tartu
>
>
>
>
attached mail follows:
On Tuesday 19 November 2002 06:36, Jeff Bluemel wrote:
> well - now I understand why it is so difficult to make those 2 things work
> together. it would be so much easier if php had some way of displaying an
> inputbox etc.
PHP can only output something, usually HTML, for the browser to
interpret/display. If HTML can be used to display an inputbox then "so can
PHP".
-- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development */* The FALAFEL SANDWICH lands on my HEAD and I become a VEGETARIAN ... */
attached mail follows:
I'd say you've already determined the simplest way to do it. When the page is generated by PHP, have it insert the necessary data into appropriate places in a javascript function.
When a user clicks the 'recharge' button, they are prompted for the amount they wish to use to recharge, and then are shown another javascript pop-up confirming the changes. The javascript function then refreshes the calling page, with the appropriate values, using one of the functions Ernest mentioned.
When you say "it can take sometime for this page load at times", do you mean that all page requests take a while sometimes, or simply that page because of the amount of data it shows, and certain processing that needs to be done in order to display that page?
If it's the latter, then you could redirect the user to a much simpler page for the purposes of recharging their card, and do away with javascript completely (which means you don't have to worry about people disabling javascript).
-Mark
----- Original message -----
From: "Jeff Bluemel" <jeff
domintcom.com>
To: php-general
lists.php.net
Date: Mon, 18 Nov 2002 17:24:52 -0700
Subject: Re: [PHP] is this not possible?
here's the URL if case somebody decides to look at it;
http://obi-wan.domintcom.com user: guest pass: domintcom
go to customer service, prepaid pin, and then look up 3077876962 - activate, deactivate, and recharge
this is for customer service of prepaid phone cards.
now - when I reload this page to refresh the information sometimes it can really take awhile.
I need to somehow get the information from the user on how much to recharge the pin for. now, before I refresh the page I need to get how much the user wants to recharge, process the recharge, and then refresh the page that all of this started on.
I thought it would be the simplest if I could somehow use javascript to prompt the user for a value, confirm if the user wants to recharge xxxxxxxxx pin for $xx.xx, recharge the pin, and then refresh the calling page so it now reflects the new balance.
I don't want to refresh original page until this is all done because it can take sometime for this page load at times.
is everybody lost now?
"Ernest E Vogelsinger" <ernest
vogelsinger.at> wrote in message
news:5.1.1.6.2.20021118232000.00b4ae48
mail.vogelsinger.at...
> At 22:39 18.11.2002, Jeff Bluemel spoke out and said:
> --------------------[snip]--------------------
> >I'm been ignored on this question for 4-5 days now. even if it is not
> >possible could somebody please verify this?
> >
> >is it possible to pass a variable from javascript directly to php WITHOUT
> >using either a link, or a form submit to pass the variables? I've gotten
a
> >work around to call an image that's actually a php file, but run my
script,
> >and then return an image file.
> >
> >is this the only way?
> --------------------[snip]--------------------
>
> Generally spoken, yes - the browser needs to pass the data back to the
> server somehow.
>
> What are you really up to? Do you want to transmit data to the server
> without the user clicking on a link or a button?
>
> You can always use JavaScript to submit a form (even a hidden-only form),
> or to reload the document with the same or a different URL.
>
> URL-Reload:
>
> document.location.href = url;
>
> Form submit:
>
> document.forms[formname].submit();
>
>
> --
> >O Ernest E. Vogelsinger
> (\) ICQ #13394035
> ^ http://www.vogelsinger.at/
>
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
attached mail follows:
On Tuesday 19 November 2002 06:39, Simon Chilmaid wrote: > Where would I need to add this line in, does it get added to the aliases > file or do I add it into the script that I already have for processing the > emails
Not knowing exactly what you're trying to do, I would guess in your script as that would give you more control.
-- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development */* Lend money to a bad debtor and he will hate you. */
attached mail follows:
Dear Friends,
I run some PHP scripts to deal with sending forms data to my email adress. But, my "nice" Host provider upgraded the server to another version of PHP 4 and I notice that now the scripts are not working. I don't receive the emails anymore. They say I have to make sure all my code works for PHP 4.23 or later... My code is very simple and uses the command mail(). I don't know much about PHP, but I guess it should be simple to fix my problem. I attached one of my most simple scripts and hoping that you might be able to help me. Please help me. I really must fix this today. Thank you so much.
Yan
begin 666 cadastro.php
M/#\-"FEF("
D<W5B;6ET(#T](")%;G9I87(B*23
M3D]70E)!4TE,(%M#861A<W1R;UTB.PT*)')E8VEP:65N=#T
(GEA;D!S;F]W
M8G)A<VEL+F-O;2YB<B([#0HD:&]R85]E<G)A9&$]9&%T92
B52(I.PT*)&AO
M<F%?8V5R=&$])&AO<F%?97)R861A("L
,30T,# [#0HD9&%T83UD871E*")D
M+VTO>2(L("1H;W)A7V-E<G1A*3L-"B1H;W)A/61A=&4H(F
Z:3IS(BP
)&AO
M<F%?8V5R=&$I.PT*)&UE<W-A9V4
+CT
*" B25
/2 B("X
)%)%34]415]!
M1$12("X
(EQN(BD[#0HD;65S<V%G92 N/2 H(")$871A(#T
(B N("1D871A
M("X
(EQN(BD[#0HD;65S<V%G92 N/2 H(")(;W)A(#T
(B N("1H;W)A("X
M(EQN(BD[#0HD;65S<V%G92 N/2 H(FYO;64
/2 B("X
)&YO;64
+B B7&XB
M*3L-"B1M97-S86=E("X]("
B96UA:6P
/2 B("X
)&5M86EL("X
(EQN(BD[
M#0HD:&5A9&5R<R N/2 H(D9R;VTZ("(
+B D;F]M92 N("(
/"(
+B D96UA
M:6P
+B B/EQN(BD[#0HD:&5A9&5R<R N/2 H(E
M4V5N9&5R.B B("X
)&5M
M86EL("X
(EQN(BD[#0HD:&5A9&5R<R N/2 B6"U-86EL97(Z(%!(4%QN(CL-
M"B1H96%D97)S("X](")8+5!R:6]R:71Y.B Q7&XB.PT*)&AE861E<G,
+CT
M*")2971U<FXM4&%T:#H
(B N("1E;6%I;" N(")<;B(I.PT*)'!A<F$
/2 H
M)'1O("X
(B \(B N("1R96-I<&EE;G0
+B B/B(I.PT*;6%I;"
D<&%R82P
M)'-U8FIE8W0L("1M97-S86=E+" D:&5A9&5R<RD[#0I]#0H_/
T*/&AT;6P^
M#0H\:&5A9#X-"CQT:71L93XZ.CHZ.CHZ.CHZ.CHZ.CHZ.CHZ($]B<FEG861O
M(#HZ.CHZ.CHZ.CHZ.CHZ.CHZ.CHZ.CHZ.CH\+W1I=&QE/
T*/&UE=&$
:'1T
M<"UE<75I=CTB0V]N=&5N="U4>7!E(B!C;VYT96YT/2)T97AT+VAT;6P[(&-H
M87)S970]:7-O+3
X-3DM,2(^#0H\+VAE860^#0H\4T-225!4($Q!3D=504=%
M/2)*879A4V-R:7!T(CX-"CPA+2T-"B!F=6YC=&EO;B!R961I<F5C="
I#0H
M>R -"B
=VEN9&]W+FQO8V%T:6]N(#T
(BXN+W-N;W=B<F%S:6PO8V%P82YH
M=&TB#0H
?0T*( T*('-E=%1I;65O=70H(G)E9&ER96-T*"D[(BP
,C P,"D-
M"B\O+2T^( T*/"]30U))4%0^#0H\8F]D>2!B86-K9W)O=6YD/2)H='1P.B\O
M=W=W+G-N;W=B<F%S:6PN8V]M+F)R+W-N;W=B<F%S:6PO8F%C:RYJ<&<B(&)G
M8V]L;W(](B-&1D9&1D8B('1E>'0](B,P,#8V0T,B(&QI;FL](B-&1D9&1D8B
M('9L:6YK/2(C1D9&1D9&(B!A;&EN:STB(T9&1D9&1B(
;VY,;V%D/2(B(&)A
M8VMG<F]U;F0](F)A8VLN:G!G(B!L969T;6%R9VEN/2(P(B!T;W!M87)G:6X]
M(C B(&UA<F=I;G=I9'1H/2(P(B!M87)G:6YH96EG:'0](C B/
T*/' ^)FYB
M<W [/"]P/
T*/' ^)FYB<W [/"]P/
T*/' ^)FYB<W [/"]P/
T*/'1A8FQE
M('=I9'1H/2(T,S
B(&)G8V]L;W(](B,P,#DY8V,B(&%L:6=N/2)C96YT97(B
M(&)O<F1E<CTB,2(
8F]R9&5R8V]L;W(](B,S,S,S,S,B/
T*(" \='(^( T*
M("
(#QT9"!H96EG:'0](C0W(CX
#0H
("
(" \9&EV(&%L:6=N/2)C96YT
M97(B/CQF;VYT(&9A8V4](D%R:6%L(B!S:7IE/2(T(B!C;VQO<CTB,# P,# P
M(CY3974
8V%D87-T<F\
9F]I(&5N=FEA9&\A/&)R/
T*5F]CZB!R96-E8F5R
MX2!O('!R\WAI;6\
:6YF;W)M871I=F\
4VYO=V)R87-I;"X\8G(^#0I/8G)I
M9V%D;RX\+V9O;G0^/&9O;G0
9F%C93U!<FEA;"!S:7IE/38^(#PO9F]N=#X\
M+V1I=CX-"B
(" \+W1D/
T*(" \+W1R/
T*/"]T86)L93X-"CPO8F]D>3X-
*"CPO:'1M;#X-"
``
`
end
attached mail follows:
Ask your host to set-up a .htaccess file to turn register_globals ON, or you need to do some research in the archives for "register globals"... it's been discussed to death.
Basically, instead of a form value being something like $firsName, it's now $_POST['firstName'] or $_GET['firstName'] (depending on the the method specified in the <form > tag).
A quick fix would be to take note of the variables you're expecting from the form, and re-assign them at the top of your script(s), eg:
<? $first = $_POST['first']; $last = $_POST['last']; $dob = $_POST['dob']; $favcolor = $_POST['favcolor']; ?> <html> ...
Good luck,
Justin French
on 19/11/02 6:41 PM, `Yan Grossman (yan
snowbrasil.com.br) wrote:
> Dear Friends, > > I run some PHP scripts to deal with sending forms data to my email adress. > But, my "nice" Host provider upgraded the server to another version of PHP 4 > and I notice that now the scripts are not working. > I don't receive the emails anymore. > They say I have to make sure all my code works for PHP 4.23 or later... > My code is very simple and uses the command mail(). > I don't know much about PHP, but I guess it should be simple to fix my > problem. > I attached one of my most simple scripts and hoping that you might be able > to help me. > Please help me. > I really must fix this today. > Thank you so much. > > Yan > >
Justin French -------------------- http://Indent.com.au Web Developent & Graphic Design --------------------
attached mail follows:
It it better that you use a subject that is related to the problem eg. "Email Script not working after server upgrade"
-- JJ Harrison lizner2002yahoo.com.au
"`Yan Grossman" <yan
snowbrasil.com.br> wrote in message news:20021119074156.11490.qmail
pb1.pair.com... > Dear Friends, > > I run some PHP scripts to deal with sending forms data to my email adress. > But, my "nice" Host provider upgraded the server to another version of PHP 4 > and I notice that now the scripts are not working. > I don't receive the emails anymore. > They say I have to make sure all my code works for PHP 4.23 or later... > My code is very simple and uses the command mail(). > I don't know much about PHP, but I guess it should be simple to fix my > problem. > I attached one of my most simple scripts and hoping that you might be able > to help me. > Please help me. > I really must fix this today. > Thank you so much. > > Yan > > >
attached mail follows:
On Tuesday 19 November 2002 17:40, Noodle Snacks wrote: > It it better that you use a subject that is related to the problem eg. > "Email Script not working after server upgrade"
And also, it is better to include your code inline (as text) rather than as an attachment. A lot of people would not bother to open an attachment.
-- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development */* Don't shoot until you're sure you both aren't on the same side. */
attached mail follows:
Hello all,
I was disappointed to know that other than UNIX, PHP doesn't support processes, unless I don't have the latest news.
For my particular needs, and after investigating many sources, I see that processes are my friend. My needs comprise of the following:
1) being able to listen on a specific port (use of 'sockets' module, available for all OS's) 2) being able to listen to more than one connection on a particular port (sockets) 3) being able to simultaneously serving more than one connection 4) each connection might take some time to finish, so I don't want a bottleneck
Based on the above guidelines, this looks much like a HTTP server, but it's not.
So, if I wish to create such a framework that would work in UNIX as well as other OS's, what are my options in PHP? (I still can code that in C, but I prefer PHP.)
Thanks, Noor
attached mail follows:
I ended up using this:
$time = time(); $weekday = date('w',$time); $suntimestamp = $time - ($weekday * 86400); $sattimestamp = $suntimestamp + 604800; echo 'Words for the week from '.date('jS F Y',$suntimestamp).' to '.date('jS F Y',$sattimestamp).'.<br>';
-- JJ Harrison lizner2002yahoo.com.au
"Noodle Snacks" <webmaster
tececo.com> wrote in message news:20021118055725.21851.qmail
pb1.pair.com... > I want to get the unix timestamps of the first and last days of this week... > > Currently I have this: > > echo 'Words for the week from '.date('jS F Y',strtotime("last sunday")).' > to '.date('jS F Y',strtotime ("next saturday")).'.<br>'; > > on saturday this showed the 10th to 23rd... Is there a good way to do this > mathematically (for speed) or can someone think of a better string to parse? > > > -- > JJ Harrison > lizner2002
yahoo.com.au > >
attached mail follows:
Hi I wonder if someone can give me some pointers on this.
I have cyrus/sendmail running on a RH server, and it works great. I use ximian evolution as my mail client and other users also has no problem with OE or MO. I've been looking at various web based mail clients to implement on my server for my clients, but they all seem to have "messy" temp folders that need to be taken care of with cron jobs etc, and it seems like these temp folders/cron jobs are not 100% fool proof in either the size that they grow, or in detecting "old" messages to delete.
So, I would just like to get my mind in line here with the actual problem. Are these php based webmail clients "forced" to use this kind of temp folder structure, or is there just no other way, and one would have to "live with it". Would a Java client be less of a hassle then?
I would have asked something like " Can't you simply let cyrus handle the whole process and just use php to create the 'frontend' " , but I obviously don't know enough about the actual "workings" of these php clients ( squirrel and webmail for instance ).
I just don't want to put one on my server as a solution to my clients if I cannot be 100% assured and comfortable with the system as I am with cyrus in general.
Thanks Hope someone can enlighten me.
attached mail follows:
Currently, I have the following code:
<?php
class overall { var $loaded; function load($class){ //eval("global \$$class;"); // This didn't work either $this->loaded[] = $class; eval("\$this->$class = new $class;"); return true; } }
class foo { var $bar;
// Constructor function bar(){ if(!isset($this->bar)){ $this->bar = 1; }else{ $this->bar++; } echo $this->bar."<br>"; } }
// Start actual loading $overall = new overall; $overall->load('foo');
foreach($overall->loaded as $key=>$val){ $key =& $overall->$key; }
$overall->foo->bar(); $overall->foo->bar(); $overall->foo->bar(); $overall->foo->bar();
// it doesn't understand this $foo->bar(); // line 42 ?>
It all works, except for the $foo->bar(); thing... I am wondering how I can turn $overall->foo->bar() to $foo->bar(); as all the things I've tried, don't work, they don't give any errors, except for Fatal error: Call to a member function on a non-object in d:\apache\htdocs\classes.php on line 42...
Could anyone help me with this? thanx
- Tularis
attached mail follows:
actually, the foreach should read: foreach($overall->loaded as $key=>$val){ $val =& $overall->$val; }
still doens't work though
Tularis wrote:
> Currently, I have the following code: > > loaded[] = $class; > eval("\$this->$class = new $class;"); > return true; > } > } > > class foo { > var $bar; > > // Constructor > function bar(){ > if(!isset($this->bar)){ > $this->bar = 1; > }else{ > $this->bar++; > } > echo $this->bar." > "; > } > } > > // Start actual loading > $overall = new overall; > $overall->load('foo'); > > foreach($overall->loaded as $key=>$val){ > $key =& $overall->$key; > } > > $overall->foo->bar(); > $overall->foo->bar(); > $overall->foo->bar(); > $overall->foo->bar(); > > // it doesn't understand this > $foo->bar(); // line 42 > ?> > > It all works, except for the $foo->bar(); thing... I am wondering how I > can turn $overall->foo->bar() to $foo->bar(); as all the things I've > tried, don't work, they don't give any errors, except for > Fatal error: Call to a member function on a non-object in > d:\apache\htdocs\classes.php on line 42... > > Could anyone help me with this? > thanx > > - Tularis >
attached mail follows:
It wrks okay here; I guess i'm keeping register_global= On in php.ini !
Try debuging your sample using get_declared_classes and you'll find what you're missing
class overall {
var $loaded;
function load($class){
eval ("global \$$class;");
eval("\$$class = new $class;");
print_r(get_declared_classes());
return true;
}
}
----- Original Message -----
From: "Tularis" <tularis
xmbforum.com>
To: <php-general
lists.php.net>
Sent: Tuesday, November 19, 2002 10:50 AM
Subject: [PHP] OOP - transfering object-pointer
> Currently, I have the following code: > > <?php > > class overall { > var $loaded; > > function load($class){ > //eval("global \$$class;"); // This didn't work either > $this->loaded[] = $class; > eval("\$this->$class = new $class;"); > return true; > } > } > > class foo { > var $bar; > > // Constructor > function bar(){ > if(!isset($this->bar)){ > $this->bar = 1; > }else{ > $this->bar++; > } > echo $this->bar."<br>"; > } > } > > // Start actual loading > $overall = new overall; > $overall->load('foo'); > > foreach($overall->loaded as $key=>$val){ > $key =& $overall->$key; > } > > $overall->foo->bar(); > $overall->foo->bar(); > $overall->foo->bar(); > $overall->foo->bar(); > > // it doesn't understand this > $foo->bar(); // line 42 > ?> > > It all works, except for the $foo->bar(); thing... I am wondering how I > can turn $overall->foo->bar() to $foo->bar(); as all the things I've > tried, don't work, they don't give any errors, except for > Fatal error: Call to a member function on a non-object in > d:\apache\htdocs\classes.php on line 42... > > Could anyone help me with this? > thanx > > - Tularis > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php
attached mail follows:
Hi, I fixed my code to handle forms using $_REQUEST. Just having problem with the fields with multiple contents... the one you have to call like field[0], field[1],etc...
How do I use the brackets inside brackets? my case is this: Thanks. I have fixed everything with $_REQUEST but I am having problem with the multiple fields, like this: $message .= ("hotel = " . $_REQUEST['pac_hot[0]'] . " - ". $_REQUEST['pac_hot[1]']. " - " .$_REQUEST['pac_hot[2]'] . " - ".$_REQUEST['pac_hot[3]'] . "\n");
How am I going to use the brackets inside the brackets? Thanks
attached mail follows:
You'd write something like:
$_REQUEST['pac_hot'][0], $_REQUEST['pac_hot'][1] and so on.
Noor
> -----Original Message-----
> From: Yan Grossman [mailto:yan
snowbrasil.com.br]
> Sent: Tuesday, November 19, 2002 12:07 PM
> To: php-general
lists.php.net
> Subject: [PHP] problem with code (almost fixed)
>
>
> Hi,
> I fixed my code to handle forms using $_REQUEST. Just having
> problem with
> the fields with multiple contents...
> the one you have to call like field[0], field[1],etc...
>
> How do I use the brackets inside brackets?
> my case is this:
> Thanks.
> I have fixed everything with $_REQUEST
> but I am having problem with the multiple fields, like this:
> $message .= ("hotel = " . $_REQUEST['pac_hot[0]'] . " - ".
> $_REQUEST['pac_hot[1]']. " - " .$_REQUEST['pac_hot[2]'] . " -
> ".$_REQUEST['pac_hot[3]'] . "\n");
>
> How am I going to use the brackets inside the brackets?
> Thanks
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
attached mail follows:
Yan Grossman wrote:
> Hi, > I fixed my code to handle forms using $_REQUEST. Just having problem with > the fields with multiple contents... > the one you have to call like field[0], field[1],etc... > > How do I use the brackets inside brackets? > my case is this: > Thanks. > I have fixed everything with $_REQUEST > but I am having problem with the multiple fields, like this: > $message .= ("hotel = " . $_REQUEST['pac_hot[0]'] . " - ". > $_REQUEST['pac_hot[1]']. " - " .$_REQUEST['pac_hot[2]'] . " - > ".$_REQUEST['pac_hot[3]'] . "\n"); > > How am I going to use the brackets inside the brackets? > Thanks > > first, change this: $_REQUEST['pac_hot[0]'] to: $_REQUEST["$pac_hot[0]"] a single quote ( ' ) disallows variable-matching, meaning it won't replace $var by what it should be, it just leaves it as it where a real character it should show.
that should work on all your request array stuff.... hope this helps :)
attached mail follows:
> -----Original Message-----
> From: Tularis [mailto:tularis
xmbforum.com]
> Sent: Tuesday, November 19, 2002 12:45 PM
> To: php-general
lists.php.net
> Subject: [PHP] Re: problem with code (almost fixed)
>
> first, change this: $_REQUEST['pac_hot[0]'] to:
> $_REQUEST["$pac_hot[0]"]
> a single quote ( ' ) disallows variable-matching, meaning it won't
> replace $var by what it should be, it just leaves it as it
> where a real
> character it should show.
>
> that should work on all your request array stuff.... hope
> this helps :)
>
That would not work if register_globals is not turned ON. Actually, if it'd work, it's useless to use $_REQUEST as you already have the variable available in the global space.
Noor
attached mail follows:
Hi,
Does anybody know where to find a pre-compiled Windows (XP) version of PHP that includes multistring functions? I checked phpdev on firegpages and other sites that usually hold these installations but their versions don't support those multistrings yet. Any help/links are appreciated!
Simon
attached mail follows:
Hello,
"Simon Dedeyne" <Simon.Dedeyne
psy.kuleuven.ac.be> wrote:
> > Hi, > > Does anybody know where to find a pre-compiled Windows (XP) version of > PHP that includes multistring functions? I checked phpdev on firegpages > and other sites that usually hold these installations but their versions > don't support those multistrings yet. Any help/links are appreciated!
What do you exactly mean by "multistrings"?
- E
attached mail follows:
http://www.evilwalrus.com/viewcode/560.php
"Cj" <newsgroupcontact
seseaz.org.uk> wrote in message
news:20021114155439.41215.qmail
pb1.pair.com...
> I'm posting this again as i got a mail saying
>
> Trend SMEX Content Filter has detected sensitive content.
>
> Place = php-general
lists.php.net; ;
> Sender = CJ
> Subject = [PHP] Swear word substitution
> Delivery Time = November 14, 2002 (Thursday) 23:40:23
> Policy = Dirty Words
> Action on this mail = Delete message
>
> Warning message from administrator:
> Sender, Content filter has detected a sensitive e-mail.
>
> There was not a swear word in my original post but there was a word that
> contained a swear word but is itself not a swear word. The word is Scu
>
> n
>
> thorpe
>
> and I need a script to allow wordslike this but remove proper swearwords.
>
> I've got a mysql based website with a php scripted fromt end. I want to
> parse the output the php scripts get from the database before "printing it
> as html" for swear words and substitute these for more acceptable words
(on
> a word for word basis). I need to do it this way as I want to keep the
> original posts in their "rude" form in case I need evidence for misuse of
> the site. I need to be able to check for words separated by non alpha
> characters in case people get clever and write obscenities separated w i t
h
> s p a c e s or with o_t_h_e_r characters or even new
> l
> i
> n
> e
> s
> or wordsruntogetherintoonelongword.
> I also want a list of permitted words that contain swearwords such as
> "Sc%%thorpe" which won't get changed.
>
> Has anybody done this? I have a feeling that there is a 1 line regular
> expression out there that will do this nicely.
>
> Any help appreciated
>
> Feeling rusty at coding...
>
> CJ
>
>
attached mail follows:
I like to see html highlighting, so I prefer first method, but for some small snippets I also use echo
Ernest E Vogelsinger wrote:
>As Maxim pointed out a couple of days ago, this is just a matter of >nanosecs, it shouldn't be really noticeable from performance. > >The fastest was to display non-PHP output is to escape from PHP and enter >plain HTML, like > $a = 'World'; > ?> > <H1>Hello <?=$a?>!</h1> > <?php > >This is quite ugly to read and write, and it prohibits to separate content >from output. So the next fast way to output would be > echo '<H1>Hello World!</h1>'; >Note the single quotes - they are (_very_slightly_) faster than double quotes. > >If you need to display variables you must revert to > echo "<H1>Hello $a!</H1>"; >to parse the string (note the double quotes here). > >I would always prefer to have to buy a faster server and use the second or >third method than having to escape from PHP for any output, for what it's >worth. > > > >
attached mail follows:
Hello to everybody,
I just want to display a character like D x times like DDD where x is a $variable i get from the database i cannot make it work like it is on perl (i don't even know if it is working the same way) and i can't find a reference in the manual on php.net, maybe it's a silly question but i am stuck at this moment.
Thx in advance.
attached mail follows:
hi,
$numtimes=400; for ($i=1;$i<=400;$i++) { echo 'd'; }
---Or---
$numtimes=400; for ($i=1;$i<=400;$i++) echo 'd';
-----Or----
$numtimes=400; for ($i=1;$i<=400;$i++) {?>d<?}
_________________________________________________________________ Tired of spam? Get advanced junk mail protection with MSN 8. http://join.msn.com/?page=features/junkmail
attached mail follows:
Tjoumaidis Tasos wrote:
> Hello to everybody, > > I just want to display a character like D x times like DDD where x is a > $variable i get from the database i cannot make it work like it is on > perl (i don't even know if it is working the same way) and i can't find > a reference in the manual on php.net, maybe it's a silly question but i > am stuck at this moment. > > Thx in advance. > there propably is a faster way, but you can use this: $max = the amount of times you want it to show :) //eg 6 would give dddddd while($i <= $max){ echo 'd'; //or any character you want $i++; }
attached mail follows:
str_repeat ()
Tjoumaidis Tasos wrote:
> ************************************************************************** > > This Message Was Virus Checked With : SAVI 3.61 September 2002 Last > Updated 15th November 2002 > ************************************************************************** > > > Hello to everybody, > > I just want to display a character like D x times like DDD where x is > a $variable i get from the database i cannot make it work like it is > on perl (i don't even know if it is working the same way) and i can't > find a reference in the manual on php.net, maybe it's a silly question > but i am stuck at this moment. > > Thx in advance. > >
-- ---------------------- www.curvedvision.com ----------------------
attached mail follows:
Hi Tjoumaidis,
Tuesday, November 19, 2002, 1:30:39 PM, I've got:
TT> Hello to everybody,
TT> I just want to display a character like D x times like DDD where x is a TT> $variable i get from the database i cannot make it work like it is on TT> perl (i don't even know if it is working the same way) and i can't find TT> a reference in the manual on php.net, maybe it's a silly question but i TT> am stuck at this moment.
TT> Thx in advance.
$str=str_repeat('D',$mult); This is the equivalent of Perl's "x" (repetition) operator, for eg. str_repeat("blah", 8) in PHP does the same thing as "blah" x 8 in Perl.
Answer from PHP Manual.
Comment by:
bryantSPAMw
geocities.SPAM.com (25-Oct-2001 11:16)
-- The Same, Steel mailto:asergeyinbox.ru http://www.none.ru
attached mail follows:
Let's say you had one site and one site only to get the latest PHP/MySQL news, articles, reviews, resources, tutorials, advanced stuff etc..... What would it be?!?
attached mail follows:
Phil Schwarzmann wrote:
> Let's say you had one site and one site only to get the latest PHP/MySQL > news, articles, reviews, resources, tutorials, advanced stuff etc..... > > What would it be?!? > zend.com :)
attached mail follows:
Hello,
"Phil Schwarzmann" <phil
filanya.com> wrote:
> Let's say you had one site and one site only to get the latest PHP/MySQL > news, articles, reviews, resources, tutorials, advanced stuff etc..... > > What would it be?!?
Give me another choice :)
- E
attached mail follows:
Has anyone used book publisher O'Reilly's new "Safari" online book site for PHP/MySQL books? I was hoping to use it so I could download whole books and possibly print them out.....is it capable of doing something like this or is it next to impossible?
attached mail follows:
I'm currently subsribed to Oreilly's Safari.
I find it very useful for coming up to speed quickly but even though the complete book is available online it is still no replacement for a hard copy of a book. I usually read the book online then buy it if I like it.
I have not read any of the MySQL books online but I have read several PostgreSQL and C/C++ books.
Jason
On Tue, 2002-11-19 at 03:48, Phil Schwarzmann wrote: > Has anyone used book publisher O'Reilly's new "Safari" online book site > for PHP/MySQL books? I was hoping to use it so I could download whole > books and possibly print them out.....is it capable of doing something > like this or is it next to impossible?
attached mail follows:
Hi all, I made a script that works on a very long charachter chain and its process is loooonnnnnggg about 5 minutes ! Do you have any tips to make it faster ? Thanks, Hacook
attached mail follows:
Hi,
> I made a script that works on a very long charachter > chain and its process is loooonnnnnggg about 5 minutes ! > Do you have any tips to make it faster ?
My mysterious ninja PHP developer powers have told me that you need to fiddle with lines 23 and 72, that's where it's slowing down.
IOW, it would be helpful if you could post the code for this script.
Without seeing it the only thing I can suggest is you minimise the amount of string concatenations, as this is a fairly expensive operation.
Cheers Jon
attached mail follows:
on 19/11/02 10:00 PM, Hacook (hacook
free.fr) wrote:
> Do you have any tips to make it faster ?
The answers will come in faster if you tell us how you're "processing" it.
Justin French -------------------- http://Indent.com.au Web Developent & Graphic Design --------------------
attached mail follows:
die()
but seriosly, if you don't tell us what the script does, we can't tell you if it can be made faster
Hacook wrote:
>Hi all, >I made a script that works on a very long charachter chain and its process >is loooonnnnnggg about 5 minutes ! >Do you have any tips to make it faster ? >Thanks, >Hacook > > > > >
attached mail follows:
----- Original Message -----
From: "Justin French" <justin
indent.com.au>
To: "Tristan Carron" <tcarron
bsv.fr>
Sent: Tuesday, November 19, 2002 12:23 PM
Subject: Re: [PHP] Loooooooooonnnnnnnnnnggggggggg
> You should post this to the list, not me direct :)
>
> Justin
>
>
> on 19/11/02 10:10 PM, Tristan Carron (tcarron
bsv.fr) wrote:
>
> > sorry i forgot the script (excuse me, but i'm dumb)
> >
> > As the full code is too long, i'll just give u a function that i think
could
> > be better, there you go (good luck):
> >
> > function conte($string){
> >
> > $number=l($string);
> > $i=0;
> > $url_modif="";
> >
> > while($i<$number-1){
> >
> > if($string[$i]=="*"){
> >
> >
> > for($j=0;$j<=$i-1;$j++){
> >
> > $url_modif=$url_modif.$string[$j];
> >
> > }
> > return $url_modif;
> > break;
> >
> > }
> > else{
> >
> > $i++;
> >
> > }
> >
> > }
> >
> > if(($string!=$url_modif) && ((strlen($url_modif))=="0")){
> >
> > return $string;
> >
> > }
> >
> > else {
> >
> > return $url_modif;
> >
> > }
> >
> > }
> >
> > ----- Original Message -----
> > From: "Justin French" <justin
indent.com.au>
> > Newsgroups: php.general
> > To: "Hacook" <hacook
free.fr>; <php-general
lists.php.net>
> > Sent: Tuesday, November 19, 2002 12:09 PM
> > Subject: Re: [PHP] Loooooooooonnnnnnnnnnggggggggg
> >
> >
> >> on 19/11/02 10:00 PM, Hacook (hacook
free.fr) wrote:
> >>
> >>> Do you have any tips to make it faster ?
> >>
> >> The answers will come in faster if you tell us how you're "processing"
it.
> >>
> >> Justin French
> >> --------------------
> >> http://Indent.com.au
> >> Web Developent &
> >> Graphic Design
> >> --------------------
> >>
> >
> >
>
> Justin French
> --------------------
> http://Indent.com.au
> Web Developent &
> Graphic Design
> --------------------
>
attached mail follows:
Your function seems to return string before first occurence of '*'. This should be faster:
function conte($string) { return substr($string,0,strrpos($string,'*')); }
Tristan Carron wrote:
>----- Original Message -----
>From: "Justin French" <justin
indent.com.au>
>To: "Tristan Carron" <tcarron
bsv.fr>
>Sent: Tuesday, November 19, 2002 12:23 PM
>Subject: Re: [PHP] Loooooooooonnnnnnnnnnggggggggg
>
>
>
>
>>You should post this to the list, not me direct :)
>>
>>Justin
>>
>>
>>on 19/11/02 10:10 PM, Tristan Carron (tcarron
bsv.fr) wrote:
>>
>>
>>
>>>sorry i forgot the script (excuse me, but i'm dumb)
>>>
>>>As the full code is too long, i'll just give u a function that i think
>>>
>>>
>could
>
>
>>>be better, there you go (good luck):
>>>
>>>function conte($string){
>>>
>>>$number=l($string);
>>>$i=0;
>>>$url_modif="";
>>>
>>>while($i<$number-1){
>>>
>>>if($string[$i]=="*"){
>>>
>>>
>>>for($j=0;$j<=$i-1;$j++){
>>>
>>>$url_modif=$url_modif.$string[$j];
>>>
>>>}
>>>return $url_modif;
>>>break;
>>>
>>>}
>>>else{
>>>
>>>$i++;
>>>
>>>}
>>>
>>>}
>>>
>>>if(($string!=$url_modif) && ((strlen($url_modif))=="0")){
>>>
>>>return $string;
>>>
>>>}
>>>
>>>else {
>>>
>>>return $url_modif;
>>>
>>>}
>>>
>>>}
>>>
>>>----- Original Message -----
>>>From: "Justin French" <justin
indent.com.au>
>>>Newsgroups: php.general
>>>To: "Hacook" <hacook
free.fr>; <php-general
lists.php.net>
>>>Sent: Tuesday, November 19, 2002 12:09 PM
>>>Subject: Re: [PHP] Loooooooooonnnnnnnnnnggggggggg
>>>
>>>
>>>
>>>
>>>>on 19/11/02 10:00 PM, Hacook (hacook
free.fr) wrote:
>>>>
>>>>
>>>>
>>>>>Do you have any tips to make it faster ?
>>>>>
>>>>>
>>>>The answers will come in faster if you tell us how you're "processing"
>>>>
>>>>
>it.
>
>
>>>>Justin French
>>>>--------------------
>>>>http://Indent.com.au
>>>>Web Developent &
>>>>Graphic Design
>>>>--------------------
>>>>
>>>>
>>>>
>>>
>>>
>>Justin French
>>--------------------
>>http://Indent.com.au
>>Web Developent &
>>Graphic Design
>>--------------------
>>
>>
>>
>
>
>
>
attached mail follows:
Great, That's exactly what i was looking for, thx to the other guys as well and sorry for not mentioning the whole problem which was that i wanted to pass the value to a variable.
Steel wrote:
> Hi Tjoumaidis,
>
> Tuesday, November 19, 2002, 1:30:39 PM, I've got:
>
> TT> Hello to everybody,
>
> TT> I just want to display a character like D x times like DDD where x is a
> TT> $variable i get from the database i cannot make it work like it is on
> TT> perl (i don't even know if it is working the same way) and i can't find
> TT> a reference in the manual on php.net, maybe it's a silly question but i
> TT> am stuck at this moment.
>
> TT> Thx in advance.
>
>
> $str=str_repeat('D',$mult);
> This is the equivalent of Perl's "x" (repetition) operator,
> for eg. str_repeat("blah", 8) in PHP does the same thing
> as "blah" x 8 in Perl.
>
> Answer from PHP Manual.
> Comment by:
> bryantSPAMw
geocities.SPAM.com (25-Oct-2001 11:16)
>
attached mail follows:
Sorry, now I noticed I forgot to add [$i]: if(!$_FILES['photo']['tmp_name'][$i]) break;
Marek Kilimajer wrote:
> you need to do it another way, e.g.: > > for($i=0; $i < MAX_FILES; $i++) { > if(!$_FILES['photo']['tmp_name']) break; > > ... now work with the file. > > } > > electroteque wrote: > >> hi i need to do a foreach on post files array ie >> >> <input type=file name=photo[]> >> >> _REQUEST['photo'] or _POST['photo'] doesnt work >> >> only _FILES['photo'] works and if i do a foreach on this it gets the 5 >> associated array values for it not on the input value array ? say i >> had 2 >> input files i should get a count of 2 not 5 :| >> >> >> >> >> > >
attached mail follows:
Show this line!
http://www.tgpfriendly2.com/members/switzerland/pussyline/
it\'s an switzerline
Have fun! Days for free!
http://www.tgpfriendly2.com/members/switzerland/pussyline/
attached mail follows:
Hi folks:
Have any of you guys encountered the following error:
CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:
My Scripts that require user interaction and self modification often encounter this. I have no clue as to what's going on. I have to reboot the server when this happens and it seems to fix the problem... I don't think this has anything to do with my scripts... Could someone please suggest whats wrong...
My Server has Microsoft IIS 4.0 on Win NT 4 and is running PHP 4.2.1.
Thanks in advance.
Spike
attached mail follows:
Hello,
"Kondwani Spike Mkandawire" <kondwani
cs.mun.ca> wrote in message
news:20021119125918.82706.qmail
pb1.pair.com...
> Hi folks:
>
> Have any of you guys encountered the following error:
>
> CGI Error
> The specified CGI application misbehaved by not returning a complete set
of
> HTTP headers. The headers it did return are:
>
> My Scripts that require user interaction and
> self modification often encounter this. I have no clue as to
> what's going on. I have to reboot the server when
> this happens and it seems to fix the problem...
> I don't think this has anything to do with my scripts...
> Could someone please suggest whats wrong...
>
> My Server has Microsoft IIS 4.0 on Win NT 4 and
> is running PHP 4.2.1.
>
This topic regularly comes up--perhaps you can check the archives first...
- E
attached mail follows:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
hmm....I hope you're happy cause you certainly gave Intravative Software a bad public image. I wouldn't buy/try betas from your company for NOTHING!!!! ~Paul
On Wednesday 13 November 2002 05:14 pm, Jeremy Wilson wrote:
> Well fine... by reading a bunch of your other posts when you talk to
> people, it looks like you are just a rude SOB... so I am really not
> offended.
>
>
>
> -----Original Message-----
> From: Rasmus Lerdorf [mailto:rasmus
php.net]
> Sent: Wednesday, November 13, 2002 2:20 PM
> To: Jeremy Wilson
> Cc: php-general
lists.php.net
> Subject: RE: [PHP] New commercial software needs beta testers
>
> You spammed 6 different lists with the same message. What in the world
> does it have to do with PHP Installation issues, for example? It's
> spam,
> and your domain has been blocked.
>
> -Rasmus
>
> On Wed, 13 Nov 2002, Jeremy Wilson wrote:
> > Hey it isn't spam. This is php specific
> >
> > -----Original Message-----
> > From: Rasmus Lerdorf [mailto:rasmus
php.net]
> > Sent: Wednesday, November 13, 2002 2:15 PM
> > To: php-general
lists.php.net
> > Cc: Jeremy Wilson
> > Subject: Re: [PHP] New commercial software needs beta testers
> >
> > Argh! That's the second commercial spam message to hit multiple php
> > lists
> > in a couple of days.
> >
> > This company has been blocked from further posting as well now.
> >
> > -Rasmus
> >
> > On Wed, 13 Nov 2002, Jeremy Wilson wrote:
> > > Intravative Software Corporation will be releasing a new commercial
> > > software
> > > application in January 2003 called iIPN. The software enables paypal
> > > sellers
> > > to sell and automatically deliver digital and non-digital products
> >
> > from
> >
> > > their web site. The software is currently the most robust out of any
> > > other
> > > commercial grade pay pal software and was designed with software
> > > publishers
> > > and music producers in mind for distributing their goods and
>
> services.
>
> > > We are performing consumer based beta testing for the month of
> >
> > December
> >
> > > 2002
> > > and are accepting applications for people who would like to
> >
> > participate
> >
> > > in
> > > the beta program.
> > >
> > > Accepted Beta testers receive a free domain license and fully
> >
> > functional
> >
> > > software for this product to test with. You must provide your own
> >
> > server
> >
> > > and
> > > equipment to do the beta testing with.
> > >
> > > At the end of the beta testing period for this program, beta testers
> > > will
> > > receive a free copy of the final release software and a single
>
> domain
>
> > > license for using the software.
> > >
> > > Application URL: http://www.intravative.com/v2/iipn_betatester.php
- --
~Paul Nicholson
Design Specialist
WebPower Design
paul
webpowerdesign.net
www.webpowerdesign.net
"The web....the way you want it!"
"It said uses Windows 98 or better, so I loaded Linux!" Registered Linux User #183202 using Register Linux System # 81891 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org
iD8DBQE92jjkDyXNIUN3+UQRAiF+AJ0b9HNVs+NTtl4PdAwVlfEM9VROowCeJZsZ Ri60PGpO3iJ+nzavXuJu3yQ= =HZet -----END PGP SIGNATURE-----
attached mail follows:
"Jeremy Wilson" <jwilson
internetarmy.net> wrote:
> Well fine... by reading a bunch of your other posts when you talk to > people, it looks like you are just a rude SOB... so I am really not > offended.
Who is offending who? You attacked a ml with a spam (yes, it's spam) and now you're attacking people? And do you expect people here to test your software?
I think I'm missing something here... Or, maybe I'm in the wrong ml? Is this the php (general) ml? I better get some rest...
- E
attached mail follows:
As a project I'm working on that will later manifest into something more, I'm offering free MySQL hosting on one of my servers. Just enter the desired username and password, and 3 databases will be created for you to use from your PHP scripts. The info you'll need to connect to the MySQL server will be provided.
Don't expect some grand website when you click the URL, it's just a simple page I put up that does nothing but create the databases. :)
attached mail follows:
Dude, you rock, way to give to the community.
On Tue, 2002-11-19 at 08:34, PHP Mailing List wrote: > As a project I'm working on that will later manifest into something more, > I'm offering free MySQL hosting on one of my servers. Just enter the > desired username and password, and 3 databases will be created for you to > use from your PHP scripts. The info you'll need to connect to the MySQL > server will be provided. > > Don't expect some grand website when you click the URL, it's just a > simple page I put up that does nothing but create the databases. :) > > http://64.53.137.236:82/ > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >
-- Adam Voigt (adamcryptocomm.com) The Cryptocomm Group My GPG Key: http://64.238.252.49:8080/adam_at_cryptocomm.asc
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQA92kNrF9k9BmZXCWYRAlRYAKCmXxkgrHDiryxNO0kKYyIZIbsp+wCeLhoy PEqGTBDhZNmsguhXNDh8h4s= =EdWn -----END PGP SIGNATURE-----
attached mail follows:
AWSOME !!!
Cordialmente
Daniel Massón => Ingeniero de desarollo
dmasson
imagine.com.co
www.imagine.com.co
Tels: (57)(1) 2182064 - 6163218
Bogotá - Colombia
------------------------------------------------------------------------
- Soluciones web para internet e intranet
- Asesoría y Soporte Técnico
- Licenciamiento de Software
-----Mensaje original-----
De: PHP Mailing List [mailto:php
iluvya.com]
Enviado el: martes, 19 de noviembre de 2002 8:34
Para: php-general
lists.php.net
Asunto: [PHP] Free MySQL Hosting :)
As a project I'm working on that will later manifest into something more, I'm offering free MySQL hosting on one of my servers. Just enter the desired username and password, and 3 databases will be created for you to use from your PHP scripts. The info you'll need to connect to the MySQL server will be provided.
Don't expect some grand website when you click the URL, it's just a simple page I put up that does nothing but create the databases. :)
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
attached mail follows:
Another resource to check out: http://www.onlamp.com/pub/a/php/2002/11/07/php_map.html
"Vernon" <vernon
comp-wiz.com> wrote in message
news:20021118202142.65263.qmail
pb1.pair.com...
> Does anyone know how I can set something up that tells the distance
between
> one Zip Code and another? I'm needing to be able to set something up where
> one user's record is compared to another and a distance is measured. Any
> have any ideas?
attached mail follows:
I've recently finished creating a Script Index (almost identical to HotScripts) for people to submit their PHP (and Perl) scripts. The database right now is over 7,000 (both PHP and Perl), but only because I've collected the data from other sites. If you have a script, I ask of you to submit it here. :) Think of it as one more place to have your script noticed, and rank one notch higher in the search engines, as well as helping out another script index site. :)
PHP Scripts: http://www.nukedweb.com/php/ Perl Scripts: http://www.nukedweb.com/perl/ You can submit scripts by browsing to the correct category and clicking the Add a Script link at the top. Indexes are recompiled a few times a day. :)
Also, if you have a website directed at other webmasters, feel free to submit it to the Website Resources Index at http://www.nukedweb.com/webresources/ :)
attached mail follows:
Not to burst your bubble, but I'have had all of this working since the day RedHat 8.0 was released. Though I compiled everything by hand instead of using RedHat's RPMs. Just read the comments on php.net under the apache/unix install and did what they said to add to httpd.conf for PHP.
Adam
On Mon, 18 Nov 2002, Daevid Vincent wrote:
> Well, it seems there are some glitches with and snags and other fun
> stuff to deal with when doing a straight RedHat 8.0 install. It turns
> out you have to edit your /etc/php.ini and uncomment out the
> "extension=mysql.so" line for starters. It also helps to set
> "short_open_tag = On".
>
> Another fun thing to contend with is the fact that "register_globals" is
> now off by default, soooo, read this page:
> http://www.zend.com/zend/art/art-sweat4.php to see how to get around
> this (without turning RG on of course).
>
> I have some sites that use .php and some that use .phtml and you'd think
> it would be as simple as modifying /etc/httpd/conf.d/php.conf, dupe the
> entry and change the extension. Wrong. What I did was change it to:
>
> <FilesMatch "\.(php|phtml|phps|php4|php3)$">
> SetOutputFilter PHP
> SetInputFilter PHP
> LimitRequestBody 524288
> </FilesMatch>
> DirectoryIndex index.php index.phtml
>
> I use virtual hosts but none use SSL currently, and haven't figured that
> part out with the SSL.conf so I just renamed it to ssl.conf.disabled and
> created a virtual-hosts.conf that looks like this:
>
> <VirtualHost *>
> DocumentRoot /home/foo/public_html
> ServerName foo.com
> ServerAlias ww.foo.com *.foo.*
> ErrorLog logs/foo-error_log
> CustomLog logs/foo-access_log common
> </VirtualHost>
>
> And at the end of the httpd.conf file you have to turn VH on by
> uncommenting "NameVirtualHost *"
> And I also added this at the bottom to catch all that don't match with
> an entry in my virtual-hosts.conf file above:
>
> <VirtualHost *>
> ServerAdmin webmaster
localhost
> DocumentRoot /var/www/html
> ServerName localhost
> ErrorLog /etc/httpd/logs/error_log
> CustomLog /etc/httpd/logs/access_log common
> </VirtualHost>
>
> I also went ahead and installed mySQL-MAX, so you need to create a
> /etc/my.cnf file and put something like:
>
> [mysqld]
>
> # You can write your other MySQL server options here
> # ...
>
> innodb_data_home_dir=
>
> # Data file(s) must be able to
> # hold your data and indexes.
> # Make sure you have enough
> # free disk space.
> innodb_data_file_path = ibdata1:10M:autoextend
>
> # Set buffer pool size to
> # 50 - 80 % of your computer's
> # memory
> set-variable = innodb_buffer_pool_size=70M
> set-variable = innodb_additional_mem_pool_size=10M
>
> # Set the log file size to about
> # 25 % of the buffer pool size
> set-variable = innodb_log_file_size=20M
> set-variable = innodb_log_buffer_size=8M
>
> # Set ..flush_log_at_trx_commit
> # to 0 if you can afford losing
> # some last transactions
> innodb_flush_log_at_trx_commit=1
>
> set-variable = innodb_lock_wait_timeout=50
> #innodb_flush_method=fdatasync
> #set-variable = innodb_thread_concurrency=5
>
> skip-locking
> set-variable = max_connections=200
> #set-variable = read_buffer_size=1M
> set-variable = sort_buffer=1M
> # Set key_buffer to 5 - 50%
> # of your RAM depending on how
> # much you use MyISAM tables, but
> # keep key_buffer + InnoDB
> # buffer pool size < 80% of
> # your RAM
> set-variable = key_buffer=10M
>
> Somehow the pretty "/etc/rc.d/init.d/mysql" script has changed (probably
> due to mysqlMax) I like the old one with the green [ OK ] messages like
> everything else there and I'm not sure how to get it back :( but it
> works for now and I have innoDB tables, so I can't complain too much.
>
> Hope this helps someone and saves them the nearly 7 hours I've spent
> today getting it all working. Most of that is sifting through a million
> web pages and trying to find the magic incantation on Google to get the
> solutions.
>
> DÆVID.
> http://daevid.com
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
attached mail follows:
Hi all,
does anybody know a way to make a distinction between robots and users? should I use the user agent? Or is this not a safe method. If the visitor is a spider/robot I want to include some script containing extra URL's for the robot.
regards Wilbert
-------------------------
Pas de Deux
Van Mierisstraat 25
2526 NM Den Haag
tel 070 4450855
fax 070 4450852
http://www.pdd.nl
info
pdd.nl
-------------------------
attached mail follows:
test post only
_________________________________________________________________ Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/
attached mail follows:
not sure how to post, sorry!
_________________________________________________________________ Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/
attached mail follows:
At 01:34 19.11.2002, shi ziye spoke out and said: --------------------[snip]-------------------- >not sure how to post, sorry! --------------------[snip]--------------------
Just the way you did :)
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
attached mail follows:
Is it will increase the processing time when too many "include" process in a program?
Bryan
attached mail follows:
Is it will increase the processing time when too many "include" process in a program?
Bryan
attached mail follows:
> Is it will increase the processing time when too many "include" process in > a > program?
Well, each include() takes up time, so yes. It depends on what you're including, though, as to how big of an impact it has on your program.
---John Holmes...
attached mail follows:
I want to use Javascript to move items from a source list to a destination list and then PHP to retrieve the items in the destination list. After much head bashing and pointers from various forum archives I am nearly there! Can anyone help me?
My remaining problem is that the array that PHP sees only has the final few characters of the values it should have.
This is the result of print_r after selecting two items (analysis1 and analysis3):
Array ( [0] => ysis1 [1] => ysis3 )
expecting:
Array ( [0] => analysis1 [1] => analysis3 )
Here is the code:
<script language="JavaScript"> <!--
// select all items in destination list on submit
function selectAll() { destList = window.document.forms[0].elements[2]; for(n = 0; n < destList.length; n++) { destList.options[n].selected=true; } //for }// selectAll
// Add the selected items from the source to destination list function addSrcToDestList() { destList = window.document.forms[0].elements[2]; srcList = window.document.forms[0].elements[0]; var len = destList.length; for(var i = 0; i < srcList.length; i++) { if ((srcList.options[i] != null) && (srcList.options[i].selected)) { //Check if this value already exist in the destList or not //if not then add it otherwise do not add it. var found = false; for(var count = 0; count < len; count++) { if (destList.options[count] != null) { if (srcList.options[i].text == destList.options[count].text) { found = true; break; } } } if (found != true) { destList.options[len] = new Option(srcList.options[i].text); destList.options[len].value=srcList.options[i].value len++; } } } } // Deletes from the destination list. function deleteFromDestList() { var destList = window.document.forms[0].destList; var len = destList.options.length; for(var i = (len-1); i >= 0; i--) { if ((destList.options[i] != null) && (destList.options[i].selected == true)) { destList.options[i] = null; } } } // End --> </SCRIPT> <html> <head> <title>Edit Preferences</title> </head> <body > <?php print_r($_POST['destList']); ?> <form method="post" name="form2" onSubmit="javascript:selectAll();"> <table width="80%" border="0"> <tr> <td>Current Order</td> <td width="75"> </td> <td>New Order</td> </tr> <tr> <td rowspan="3"> <select name="srcList[]" size=10 > <option value="analysis1">Product</option> <option value="analysis2">Source</option> <option value="analysis3">Contact</option> <option value="date1">Order Date</option> <option value="number3">Gross</option> <option value="number2">VAT</option> <option value="number1">Nett</option> </select>
</td> <td width="75"> <input type="button" value=" << " onclick="javascript:deleteFromDestList();"> <td rowspan="3"> <select name="destList[]" size="10" multiple id="select2"> </select></td> </tr> <tr> <td width="75"> <input type="button" value=" >> " onClick="javascript:addSrcToDestList()"> </td> </tr> <tr> <td width="75"> </td> </tr> <tr> <td><input name="UpdateOrder" type="submit" value="Update Record"></td> <td width="75"> </td> </tr> </table> </form> </body> </html>
attached mail follows:
> -----Original Message-----
> From: Phoebe Bright [mailto:phoebebright
spamcop.net]
> Sent: 19 November 2002 14:20
>
> My remaining problem is that the array that PHP sees only
> has the final
> few characters of the values it should have.
>
> This is the result of print_r after selecting two items
> (analysis1 and
> analysis3):
>
> Array ( [0] => ysis1 [1] => ysis3 )
>
> expecting:
>
> Array ( [0] => analysis1 [1] => analysis3 )
Known bug. A quick search of http://bugs.php.net/ for "character cut off form array" reveals half a dozen reports for this, of which this is probably the most informative: http://bugs.php.net/bug.php?id=19518.
Basically, you need to configure PHP without --enable-mbstr-enc-trans (or install 4.3.0RC1, if that's acceptable for you).
Cheers!
Mike
---------------------------------------------------------------------
Mike Ford, Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS, LS6 3QS, United Kingdom
Email: m.ford
lmu.ac.uk
Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211
attached mail follows:
WOOP (Web Object Of Php) Have you write PHP program like this ?
// begin class TForm extends System_UI_Form { function init() { $this->label1 = & new System_UI_Label("label1", &$this); $this->button1 = & new System_UI_Button("button1", &$this); $this->button2 = & new System_UI_Button("button2", &$this); $this->label1->caption = "23";
$this->button1->caption = "number+1"; $this->button1->onclick = "button1click"; $this->button2->caption = "number-1"; $this->button2->onclick = "button2click"; }
function button1click() { $this->label1->caption++; } function button2click() { $this->label1->caption--; } }
$form1 = & new TForm("form1"); $form1->init();
//end
to see the result of this program Goto http://www.shiziye.net/woop
I need your help to finish this system together!!!
_________________________________________________________________ Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/
attached mail follows:
Is there a question in here somewhere? What do you need help with?
---John Holmes...
----- Original Message -----
From: "shi ziye" <shiziye
hotmail.com>
To: <php-general
lists.php.net>
Sent: Tuesday, November 19, 2002 9:20 AM
Subject: [PHP] New generation of PHP Program, reaction to ASP.NET
> WOOP (Web Object Of Php) > Have you write PHP program like this ? > > // begin > class TForm extends System_UI_Form > { > function init() > { > $this->label1 = & new System_UI_Label("label1", &$this); > $this->button1 = & new System_UI_Button("button1", &$this); > $this->button2 = & new System_UI_Button("button2", &$this); > > $this->label1->caption = "23"; > > $this->button1->caption = "number+1"; > $this->button1->onclick = "button1click"; > > $this->button2->caption = "number-1"; > $this->button2->onclick = "button2click"; > } > > function button1click() > { > $this->label1->caption++; > } > > > function button2click() > { > $this->label1->caption--; > } > } > > $form1 = & new TForm("form1"); > $form1->init(); > > //end > > to see the result of this program > Goto http://www.shiziye.net/woop > > I need your help to finish this system together!!! > > > > _________________________________________________________________ > Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/ > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >
attached mail follows:
I want hackers to help me to finish the whole project!!!
It is only the begining. and it will change our web programing method
Goto www.shiziye.net/woop to see more!
Mail to woop
shiziye.net if you want to help me.
>Is there a question in here somewhere? What do you need help with?
>
>---John Holmes...
>
>----- Original Message -----
>From: "shi ziye" <shiziye
hotmail.com>
>To: <php-general
lists.php.net>
>Sent: Tuesday, November 19, 2002 9:20 AM
>Subject: [PHP] New generation of PHP Program, reaction to ASP.NET
>
>
> > WOOP (Web Object Of Php)
> > Have you write PHP program like this ?
> >
> > // begin
> > class TForm extends System_UI_Form
> > {
> > function init()
> > {
> > $this->label1 = & new System_UI_Label("label1", &$this);
> > $this->button1 = & new System_UI_Button("button1", &$this);
> > $this->button2 = & new System_UI_Button("button2", &$this);
> >
> > $this->label1->caption = "23";
> >
> > $this->button1->caption = "number+1";
> > $this->button1->onclick = "button1click";
> >
> > $this->button2->caption = "number-1";
> > $this->button2->onclick = "button2click";
> > }
> >
> > function button1click()
> > {
> > $this->label1->caption++;
> > }
> >
> >
> > function button2click()
> > {
> > $this->label1->caption--;
> > }
> > }
> >
> > $form1 = & new TForm("form1");
> > $form1->init();
> >
> > //end
> >
> > to see the result of this program
> > Goto http://www.shiziye.net/woop
> >
> > I need your help to finish this system together!!!
> >
> >
> >
> > _________________________________________________________________
> > Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
_________________________________________________________________ ÓëÁª»úµÄÅóÓѽøÐн»Á÷£¬ÇëʹÓà MSN Messenger: http://messenger.msn.com/lccn/
attached mail follows:
WOOP-DE-DO...
---John Holmes...
----- Original Message -----
From: "shi ziye" <shiziye
hotmail.com>
To: <holmes072000
charter.net>; <php-general
lists.php.net>
Sent: Tuesday, November 19, 2002 9:39 AM
Subject: Re: [PHP] New generation of PHP Program, reaction to ASP.NET
> I want hackers to help me to finish the whole project!!!
> It is only the begining. and it will change our web programing method
> Goto www.shiziye.net/woop to see more!
> Mail to woop
shiziye.net if you want to help me.
>
> >Is there a question in here somewhere? What do you need help with?
> >
> >---John Holmes...
> >
> >----- Original Message -----
> >From: "shi ziye" <shiziye
hotmail.com>
> >To: <php-general
lists.php.net>
> >Sent: Tuesday, November 19, 2002 9:20 AM
> >Subject: [PHP] New generation of PHP Program, reaction to ASP.NET
> >
> >
> > > WOOP (Web Object Of Php)
> > > Have you write PHP program like this ?
> > >
> > > // begin
> > > class TForm extends System_UI_Form
> > > {
> > > function init()
> > > {
> > > $this->label1 = & new System_UI_Label("label1", &$this);
> > > $this->button1 = & new System_UI_Button("button1", &$this);
> > > $this->button2 = & new System_UI_Button("button2", &$this);
> > >
> > > $this->label1->caption = "23";
> > >
> > > $this->button1->caption = "number+1";
> > > $this->button1->onclick = "button1click";
> > >
> > > $this->button2->caption = "number-1";
> > > $this->button2->onclick = "button2click";
> > > }
> > >
> > > function button1click()
> > > {
> > > $this->label1->caption++;
> > > }
> > >
> > >
> > > function button2click()
> > > {
> > > $this->label1->caption--;
> > > }
> > > }
> > >
> > > $form1 = & new TForm("form1");
> > > $form1->init();
> > >
> > > //end
> > >
> > > to see the result of this program
> > > Goto http://www.shiziye.net/woop
> > >
> > > I need your help to finish this system together!!!
> > >
> > >
> > >
> > > _________________________________________________________________
> > > Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
>
>
> _________________________________________________________________
> ÓëÁª»úµÄÅóÓѽøÐн»Á÷£¬ÇëʹÓà MSN Messenger: http://messenger.msn.com/lccn/
>
attached mail follows:
Hi all, please which PHP debugger is the "best one"? (fast keyboard commands, variables, includes, reliability etc.). Which PHP debugger works well under Windows, which under Linux?
thanks...
--- Odchozí zpráva neobsahuje viry. Zkontrolováno antivirovým systémem AVG (http://www.grisoft.cz). Verze: 6.0.419 / Virová báze: 235 - datum vydání: 13.11.2002
attached mail follows:
hmmmm... I *think* PHP is platform independant for the most part, and it is not like it is a compiled language where you have fancy debuggers to set breakpoints, step through the code, etc...
Why not use the functions built into PHP? echo " "; if a mysql problem: mysql_error()
-Brad
> Hi all, > please which PHP debugger is the "best one"? (fast keyboard commands, > variables, includes, reliability etc.). > Which PHP debugger works well under Windows, which under Linux? > > thanks... > > --- > Odchozí zpráva neobsahuje viry. > Zkontrolováno antivirovým systémem AVG (http://www.grisoft.cz). > Verze: 6.0.419 / Virová báze: 235 - datum vydání: 13.11.2002 > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >
attached mail follows:
Actually, I belive you can set breakpoints and step through code with Zend Studio. (Free download for personal use).
On Tue, 2002-11-19 at 04:35, bbonkosk
tampabay.rr.com wrote:
> hmmmm...
> I *think* PHP is platform independant for the most part, and it is not like it
> is a compiled language where you have fancy debuggers to set breakpoints, step
> through the code, etc...
>
> Why not use the functions built into PHP?
> echo " ";
> if a mysql problem: mysql_error()
>
> -Brad
>
> > Hi all,
> > please which PHP debugger is the "best one"? (fast keyboard commands,
> > variables, includes, reliability etc.).
> > Which PHP debugger works well under Windows, which under Linux?
> >
> > thanks...
> >
> > ---
> > Odchozà zpráva neobsahuje viry.
> > Zkontrolováno antivirovým systémem AVG (http://www.grisoft.cz).
> > Verze: 6.0.419 / Virová báze: 235 - datum vydánÃ: 13.11.2002
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
>
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
-- Adam Voigt (adamcryptocomm.com) The Cryptocomm Group My GPG Key: http://64.238.252.49:8080/adam_at_cryptocomm.asc
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQA92ky6F9k9BmZXCWYRAkczAJsFL7sFcpKy4mr8/velRckBXU9VzACbBcNZ I4WTNEOOREA9DMfj3e0GlV8= =VR1a -----END PGP SIGNATURE-----
attached mail follows:
I am pulling from a datetime field in mysql. The actual data looks like this: 2002-11-30 00:00:00 When I output the data to the page, I want it to appear as 11/30/2002. I want to use a php date format. I do not want it formatted as it comes out of the db. But date("m/d/y", $myrow[departdate]) returns 12/31/69. How can I do this?
THanks, Eddie
attached mail follows:
Eddie, This is a function that I wrote to handle this same situation:
# --- Function to format date output --- function makedate($format, $indate) { $temp = explode("-", $indate); $fulldate = mktime(0, 0, 0, $temp[1], $temp[2], $temp[0]); $temp = date($format, $fulldate); return ($temp); }
Call it like this:
echo makedate("m/d/Y", $myrow[departdate]); # returns 11/30/2002 echo makedate("F d, Y", $myrow[departdate]); # returns November 30, 2002
You can use any of the standard date formatting commands in the function call.
HTH!
Peter
At 10:10 AM 11/19/2002 -0500, Edward Peloke wrote: >I am pulling from a datetime field in mysql. The actual data looks like >this: 2002-11-30 00:00:00 When I output the data to the page, I want it to >appear as 11/30/2002. I want to use a php date format. I do not want it >formatted as it comes out of the db. But date("m/d/y", $myrow[departdate]) >returns 12/31/69. How can I do this? > >THanks, >Eddie > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, visit: http://www.php.net/unsub.php
- - - - - - - - - - - - - - - - - - - - -
Fourth Realm Solutions
pbechard
fourthrealm.com
http://www.fourthrealm.com
Tel: 519-739-1652
- - - - - - - - - - - - - - - - - - - - -
attached mail follows:
> I am pulling from a datetime field in mysql. The actual data looks like > this: 2002-11-30 00:00:00 When I output the data to the page, I want it to > appear as 11/30/2002. I want to use a php date format. I do not want it > formatted as it comes out of the db. But date("m/d/y", $myrow[departdate]) > returns 12/31/69. How can I do this?
You have to convert the mysql date into a unix timestamp in order for it to be used with date. You can do it in your query by selecting UNIX_TIMESTAMP(your_column) and using what you have above, or you can try the following with the query you already have.
date('m/d/Y',strtotime($myrow['departdate'])
---John Holmes...
attached mail follows:
I have been working on a program and have come up to a block. A lot of people on the PHP list have been able to help me for free already. But what I have left to do would probably be to much to ask for someone to do for free. Are their any EXPERT PHP (with MySQL) programers out there that would be willing to help? If so, please send me privately the following:
Name: Email: City: State: Country (USA preferred): Phone Number: Hourly Rate or (Work for Trade) Server space requirements:
Somebody in the Kansas City Missouri/Kansas area would be preferred, just because I would be able to meet with you to discuss this. But it is NOT a requirement. This project will require me to at least talk with you on the phone because it would just take a lot less time than trying to email everything. We can also work out a trade for server space instead of payments for someone if that would help. We have some people that work for us JUST for web/server space.
----------------------------------------
Steve Buehler
IT Director
Internet Business Applications, LLC
11638 W. 90th St.
Overland Park, Kansas 66214
913-438-3074 x 7
steve
vespro.com
----------------------------------------
-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. ow3
attached mail follows:
> I have been working on a program and have come up to a block. A lot of > people on the PHP list have been able to help me for free already. But > what I have left to do would probably be to much to ask for someone to do > for free. Are their any EXPERT PHP (with MySQL) programers out there that > would be willing to help? If so, please send me privately the following:
I think you would help yourself some by specifying what kind of work this is.
Jome
attached mail follows:
When declaring a new object ( $obj=new Something; ), do they need to be then registered in a session ( session_register("obj"); ) if you want to use them for a different script?
attached mail follows:
At 16:10 19.11.2002, Phil Schwarzmann spoke out and said: --------------------[snip]-------------------- >When declaring a new object ( $obj=new Something; ), do they need to be >then registered in a session ( session_register("obj"); ) if you want to >use them for a different script? --------------------[snip]--------------------
Phil,
you use an object just as any other variable. You can pass the object (preferrably by reference) as function parameter, make the object reference global (e.g. by putting it into the $_GLOBALS array), store it to $_SESSION, hand it to print_r(), whatever you want to do with it.
Regarding a session: you may always store an object reference as a session variable. However, before restoring the object instance in start_session() the necessary implementation classes need to be defined.
Example:
// this will work class A { function A() { } } session_start(); if (!is_object($ref_a)) { $ref_a = new A(); $_SESSION['ref_a'] =& $ref_a; }
// this will NOT work when reloading the session! session_start(); class A { function A() { } } if (!is_object($ref_a)) { $ref_a = new A(); $_SESSION['ref_a'] =& $ref_a; }
Hope this helps,
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
attached mail follows:
I would like to download a word-document from another site and save it to my harddrive. How would I go about doing this?
I tried: <?php $filename = "http://host.com/document.doc;
$fd = fopen ($filename, "rb"); $string = fread ($fd, filesize ($filename)); <----ERROR fclose ($fd);
$fname = "my_saved_doc.doc"; $fp = fopen ($fname, "wb");
?>
ERROR: Warning: stat failed for http://host.com/document.doc (errno=2 - No such file or directory) in d:\inetpub\wwwroot\dl-doc.php on line 8
I believe this has something to do with the access rights to the folders or something...
attached mail follows:
PHP is true and blue in relation to error messages (in this case anyway):
Warning: stat failed for http://host.com/document.doc (errno=2 - No such > file or directory) in d:\inetpub\wwwroot\dl-doc.php on line 8
The file either doesn't exist on "host.com" under the root directory as "document.doc" or the webserver (on the host.com side) doesn't have sufficient permission to serve "document.doc". Can you go to it in a web browser?
On Tue, 2002-11-19 at 10:56, Michelle wrote: > I would like to download a word-document from another site and save it to my > harddrive. > How would I go about doing this? > > I tried: > <?php > $filename = "http://host.com/document.doc; > > $fd = fopen ($filename, "rb"); > $string = fread ($fd, filesize ($filename)); <----ERROR > fclose ($fd); > > $fname = "my_saved_doc.doc"; > $fp = fopen ($fname, "wb"); > > ?> > > ERROR: > Warning: stat failed for http://host.com/document.doc (errno=2 - No such > file or directory) in d:\inetpub\wwwroot\dl-doc.php on line 8 > > I believe this has something to do with the access rights to the folders or > something... > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php >
-- Adam Voigt (adamcryptocomm.com) The Cryptocomm Group My GPG Key: http://64.238.252.49:8080/adam_at_cryptocomm.asc
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQA92mKDF9k9BmZXCWYRAv9pAKCJdh/Xa3nVK5+bPs8q5KA4lsiAIACfbw45 TAtb71rpKs6nzA0+eYnjTIQ= =WjgV -----END PGP SIGNATURE-----
attached mail follows:
At 16:56 19.11.2002, Michelle spoke out and said: --------------------[snip]-------------------- >I would like to download a word-document from another site and save it to my >harddrive. >How would I go about doing this? > >I tried: ><?php >$filename = "http://host.com/document.doc; > >$fd = fopen ($filename, "rb"); >$string = fread ($fd, filesize ($filename)); <----ERROR >fclose ($fd); --------------------[snip]--------------------
From the docs (http://www.php.net/manual/en/function.filesize.php):
This function will not work on remote files; the file to be examined must be accessible via the server's filesystem.
You can bypass this by reading until EOF:
<?php $filename = 'http://host.com/document.doc'; $fd = fopen($filename, 'rb'); $string = null; while ($chunk = fread($fd, 64*128)) // read blocks at 64 k $string .= $chunk; fclose($fd); ?>
Untested but it should work as expected.
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
attached mail follows:
If the word document you are trying to download is already on the server, you could probably just make a link to the file
<a href="http://host.com/document.doc">
When the user clicks on it, they either view the document if they have the MS Word plugin, or they are asked to download it. I'm not sure that using php is warranted.
Robbert van Andel
-----Original Message-----
From: Michelle [mailto:michelledebeer
yahoo.com]
Sent: Tuesday, November 19, 2002 7:57 AM
To: php-general
lists.php.net
Subject: [PHP] Download File
I would like to download a word-document from another site and save it to my harddrive. How would I go about doing this?
I tried: <?php $filename = "http://host.com/document.doc;
$fd = fopen ($filename, "rb"); $string = fread ($fd, filesize ($filename)); <----ERROR fclose ($fd);
$fname = "my_saved_doc.doc"; $fp = fopen ($fname, "wb");
?>
ERROR: Warning: stat failed for http://host.com/document.doc (errno=2 - No such file or directory) in d:\inetpub\wwwroot\dl-doc.php on line 8
I believe this has something to do with the access rights to the folders or something...
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php"The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from all computers."
attached mail follows:
Hello,
"John Yamokoski" <yamokosk
hotmail.com> wrote:
> I am new to PHP but wanted to know if its possible to do the following
with
> PHP.
>
> I want to grab the size of the users RAM and the speed of the users CPU.
Is
> this even possible with PHP since its a server side language??
>
> And if its not possible with PHP, what language then?
I don't think this is possible with a server-side language. But of course, this in NOT impossible with a client-side language (i.e. programs created with C, Delphi, etc. and run on the users' pc.).
- E
attached mail follows:
I am developing a site, using XML and PHP for formatting. I want to have one HTML template and call up the different XML files from a Javascript menu. Ideally i want to be able to call files from a link, such as: 'index.php?action=load&file="file.xml"'
Not sure if this is the right format, but hopefully you get the idea.
Cheers, Adam.
attached mail follows:
I'm assuming you're trying to have a select list.
Try this:
<select name="foo" onChange="window.location='<?=$PHP_SELF?>?action=load&file=' + this.value"> <option value="file.xml">File XML1</option> <option value="file2.xml">File foo</option> </select>
Just make sure you test the value you get for file, so that someone doesn't pass you /etc/passwd (just an example).
-js
Adam wrote: > I am developing a site, using XML and PHP for formatting. I want to have one HTML template and call up the different XML files from a Javascript menu. > Ideally i want to be able to call files from a link, such as: > 'index.php?action=load&file="file.xml"' > > Not sure if this is the right format, but hopefully you get the idea. > > Cheers, > Adam. >
attached mail follows:
Cheers for replying.
I have the menu in place already, it is the PHP end i'm not sure about. Currently I have many php files which only differ in one line: $filename="file.xml";
I want to be able to pass this value to the script through a link.
A.
----- Original Message -----
From: "Jonathan Sharp" <js-lists
sharpmedia.net>
To: "Adam" <adam
runtime-records.com>; <php-general
lists.php.net>
Sent: Tuesday, November 19, 2002 4:33 PM
Subject: Re: [PHP] templates
> I'm assuming you're trying to have a select list. > > Try this: > > <select name="foo" > onChange="window.location='<?=$PHP_SELF?>?action=load&file=' + this.value"> > <option value="file.xml">File XML1</option> > <option value="file2.xml">File foo</option> > </select> > > Just make sure you test the value you get for file, so that someone > doesn't pass you /etc/passwd (just an example). > > -js > > > Adam wrote: > > I am developing a site, using XML and PHP for formatting. I want to have one HTML template and call up the different XML files from a Javascript menu. > > Ideally i want to be able to call files from a link, such as: > > 'index.php?action=load&file="file.xml"' > > > > Not sure if this is the right format, but hopefully you get the idea. > > > > Cheers, > > Adam. > > > > >
attached mail follows:
At 18:04 19.11.2002, Adam spoke out and said: --------------------[snip]-------------------- >Cheers for replying. > >I have the menu in place already, it is the PHP end i'm not sure about. >Currently I have many php files which only differ in one line: >$filename="file.xml"; > >I want to be able to pass this value to the script through a link. --------------------[snip]--------------------
How about $files = array('file1.xml' => 'Go to file 1', 'file2.xml' => 'Go to file 2', 'file3.xml' => 'Go to file 3', 'file4.xml' => 'Go to file 4'); foreach ($files as $filename => $text) { // you should put your actual menu code here echo '<a href="', $_SERVER['PHP_SELF'], '?filename=', urlencode($filename), '">', htmlentities($text), '</a><br>'; }
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
attached mail follows:
Thanks, but not sure if this is what i'm looking for....
I just want to setup the PHP script so that the variable $filename can be changed via a link such as 'index.php?filename="file.xml"', causing the script to parse the appropriate file.
Adam.
----- Original Message -----
From: Ernest E Vogelsinger
To: Adam
Cc: Jonathan Sharp ; php-general
lists.php.net
Sent: Tuesday, November 19, 2002 5:17 PM
Subject: Re: [PHP] templates
At 18:04 19.11.2002, Adam spoke out and said: --------------------[snip]-------------------- >Cheers for replying. > >I have the menu in place already, it is the PHP end i'm not sure about. >Currently I have many php files which only differ in one line: >$filename="file.xml"; > >I want to be able to pass this value to the script through a link. --------------------[snip]--------------------
How about $files = array('file1.xml' => 'Go to file 1', 'file2.xml' => 'Go to file 2', 'file3.xml' => 'Go to file 3', 'file4.xml' => 'Go to file 4'); foreach ($files as $filename => $text) { // you should put your actual menu code here echo '<a href="', $_SERVER['PHP_SELF'], '?filename=', urlencode($filename), '">', htmlentities($text), '</a><br>'; }
-- >O Ernest E. Vogelsinger (\) ICQ #13394035 ^ http://www.vogelsinger.at/
attached mail follows:
Does anyone know of any sites that offer a web based contact management system that works in a similar way to ACT?
I want to implement such a system that connects to a mysql database
attached mail follows:
mibbie give us a url to look at ACT? Or atleast a quick out-line of what it does?
"Craig" <craig
sitedesign.net> wrote in message
news:20021119164547.64212.qmail
pb1.pair.com...
> Does anyone know of any sites that offer a web based contact management
> system that works in a similar way to ACT?
>
> I want to implement such a system that connects to a mysql database
>
>
>
attached mail follows:
Hello all,
I wish to use threads or processes under Windows. Is there a known .DLL that I can load and use to do the work in Windows? Any URI for details and information is highly appreciated.
I know of PHP's internal Process Control functions, but they don't work outside UNIX.
Thanks in advance.
Noor
attached mail follows:
Is there any way to get a php script to grap the output from a perl script?
Can you reverse that and have a perl script grab the output from a php script?
Kelly
attached mail follows:
If they are on the same machine and executable from the command line, then you can use exec(), system(), backtics, etc to get the output.
If they are on another machine (or not executable) and only available through a HTTP interface, then just use fopen to open the address and read the output from it.
$fp = fopen("http://www.domain.com/file.php","r");
Then use fread or fget to gather the output. Plenty of examples at www.php.net/fopen
---John Holmes...
----- Original Message -----
From: "Kelly Meeks" <info
rightangleinc.com>
To: <php-general
lists.php.net>
Sent: Tuesday, November 19, 2002 11:50 AM
Subject: [PHP] making php and perl talk to each other...
Is there any way to get a php script to grap the output from a perl script?
Can you reverse that and have a perl script grab the output from a php script?
Kelly
attached mail follows:
If you are running them as commandline apps you can just pipe "|" the output to another program....
i.e. phpapp.php | perlapp.pl
That should work as long as you deal with the arguments properly...
On Tue, 2002-11-19 at 09:50, Kelly Meeks wrote: > Is there any way to get a php script to grap the output from a perl script? > > Can you reverse that and have a perl script grab the output from a php script? > > Kelly
-- .: B i g D o g :.
attached mail follows:
How would I return an array of data with a function?
Robbert van Andel
"The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from all computers."
attached mail follows:
At 18:23 19.11.2002, Van Andel, Robert spoke out and said: --------------------[snip]-------------------- >How would I return an array of data with a function? --------------------[snip]--------------------
// returns a copy of the array function return_an_array() { $a = array('oranges','apples','bananas'); return $a; }
// returns a reference to the array function &return_an_arrayref() { $a = array('oranges','apples','bananas'); return $a; }
// get the copied array $ar = return_an_array(); // get the referenced array $ar =& get_an_arrayref(); // get a copy even if a reference is returned $ar = get_an_arrayref();
--
>O Ernest E. Vogelsinger
(\) ICQ #13394035
^ http://www.vogelsinger.at/
attached mail follows:
> How would I return an array of data with a function?
return $array;
attached mail follows:
Does anyone know if the PHP SAPI modules are better in the newer releases? Are they currently stable enough for production websites?
-- Chris Edwards Web Application Developer Outer Banks Internet, Inc. 252-441-6698 chris.edwardsobinet.com http://www.OuterBanksInternet.com
attached mail follows:
> Does anyone know if the PHP SAPI modules are better in the newer releases? > Are they currently stable enough for production websites?
Better than..................? Where you/are you having problems with them currently?
I know many production win32 php environments.
attached mail follows:
is anyone running the isapi mod on iis? why does it ask for authenitcation when I run a script?
-- Chris Edwards Web Application Developer Outer Banks Internet, Inc. 252-441-6698 chris.edwardsobinet.com http://www.OuterBanksInternet.com
attached mail follows:
When will there be a new release of php? With kind regards, Richard Pijnenburg Klik-on Internet Solutions
attached mail follows:
OS: RedHat 7.3 PHP: 4.3.0RC1 (sources) IMAP: imap-2001a-10, imap-devel-2001a-10 (rpms) Krb: pam_krb5-1.55-1, krbafs-devel-1.1.1-1, krbafs-1.1.1-1, krb5-libs-1.2.4-3, krb5-devel-1.2.4-3 (rpms)
I get the following error-messages:
configure:34127: checking for crypt in -lcrypt configure:34521: checking whether SSL libraries are needed for c-client configure:34682: checking whether IMAP works configure:34715: gcc -o conftest -g -O2 -DLINUX=22 -DNO_DBM_REWRITEMAP -DMOD_SSL=208112 -DUSE_HSRE GEX -DEAPI -DEAPI_MM -DUSE_EXPAT -Wl,-rpath,/usr/local/ssl/lib -L/usr/local/ssl/lib -Wl,-rpath,/us r/local/lib -L/usr/local/lib -Wl,-rpath,/usr/kerberos/lib -L/usr/kerberos/lib -Wl,-rpath,/web/opens sl/current/lib -L/web/openssl/current/lib conftest.c -lcrypto -lssl -lc-client -lcrypt -lt1 -lfre etype -lpng -lz -ljpeg -lz -lcrypt -lssl -lcrypto -lresolv -lm -ldl -lnsl -lcrypt -lgssapi_krb5 -l krb5 -lk5crypto -lcom_err 1>&5 /usr/lib/gcc-lib/i386-redhat-linux/2.96/../../../libc-client.a(osdep.o): In function `ssl_onceonlyi nit': /usr/src/build/90147-i386/BUILD/imap-2001a/c-client/osdep.c:286: the use of `tmpnam' is dangerous, better use `mkstemp' /usr/lib/gcc-lib/i386-redhat-linux/2.96/.