|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
From: php-general-digest-help
lists.php.netDate: Mon Sep 03 2001 - 22:43:16 CDT
php-general Digest 4 Sep 2001 03:43:16 -0000 Issue 855
Topics (messages 65738 through 65807):
Re: How to call a member from the base class?
65738 by: Neil Kimber
Search capability to my intranet?
65739 by: Phil Labonte
65740 by: Miles Thompson
how to get all the records of a particular month....
65741 by: sagar
65747 by: Hugh Bothwell
Posting data through PHP scripts
65742 by: Jean Madson
65759 by: Krzysztof Kocjan
I dont see whats wrong!
65743 by: Kyle Smith
65744 by: Kunal Jhunjhunwala
65745 by: Kyle Smith
65756 by: John Monfort
65760 by: Andy Woolley
65802 by: Alexander Skwar
65803 by: Alexander Skwar
Problem with PHP_SELF
65746 by: David Otton
65749 by: David Otton
65753 by: * R&zE:
65764 by: Joe Sheble \(Wizaerd\)
65765 by: David Otton
65768 by: Mark Charette
65791 by: CC Zona
MDB
65748 by: Rogerio Coelho - Equipeweb - CompuLand ISP
65750 by: ignacio.estrada.cfe.gob.mx
65762 by: Alfredo Yong
65763 by: Mark Roedel
65785 by: ignacio.estrada.cfe.gob.mx
hot Image on Image action
65751 by: Mike Heald
Re: EDI with PHP?
65752 by: Hugh Bothwell
65755 by: Jon Farmer
65757 by: Sean C. McCarthy
Re: probs with exec, pls help (still again)
65754 by: taz
Re: If PHP4 existed in 1995 we would of taken over the world by now
65758 by: Maxim Derkachev
65798 by: Bob
65799 by: Rasmus Lerdorf
65800 by: Christopher William Wesley
65801 by: Martín Marqués
Re: probs with exec, pls pls help
65761 by: Chris Hobbs
Pulling a random image
65766 by: Brad R. C.
65780 by: Hugh Bothwell
65789 by: Brad R. C.
65794 by: Mark Charette
Help on e-mail attachments retrieval adn ZIP uncompression.
65767 by: Carlos Fernando Scheidecker Antunes
65769 by: Richard Heyes
Re: Error trapping
65770 by: Moody
separate files?
65771 by: Michael Kimsal
Re: [PHP-INST] PHP4 and Apache 1.3.20 DSO mode not working?
65772 by: Bill Carter
detection of relevance
65773 by: BRACK
FULLTEXT search sorting results
65774 by: BRACK
65778 by: Mark Maggelet
database searching
65775 by: Melih Onvural
65777 by: Hugh Bothwell
session_encode doesn't work....
65776 by: Dhaval Desai
65779 by: Christopher William Wesley
Re: newbie : how to access functions in seperate files???
65781 by: web-dev
65782 by: Lukas Smith
Re: Current status of things
65783 by: Harald Radi
ob_start()
65784 by: Jeroen Olthof
Recursivly Updating Files
65786 by: skater
65787 by: Rasmus Lerdorf
65788 by: skater
65793 by: Franklin van Velthuizen
65795 by: skater
replacing a carriage return with an html break
65790 by: nate.1feehosting.com
65792 by: Christopher William Wesley
65796 by: Chris Hobbs
PHP Authentication on Apache
65797 by: Lynn Holt
php4 and apache 1.3.20
65804 by: Christian Darsow
Re: Disbale function in certain virtual host
65805 by: Nicolas Ross
PHP and OLE objects
65806 by: Joshua Ecklund
Am I right or wrong?
65807 by: Seb Frost
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:
No! This won't work. There are two ways in which you can get an overridden
method to call the method in its super-class, these are by using the
following constructs:
1) parent::
2) <classname>::
So, you could do the following:
1)
class B extends A {
function something() {
// some other actions
parent::something(); // calls A::something
}
}
or
2)
class B extends A {
function something() {
// some other actions
A::something(); // calls A::something
}
}
I've experienced PHP getting confused when using the parent:: construct. If
you have an object that is 3 levels deep in sub-classing and each sub-class
overrides the same method then the parent:: construct in the level 2 object
sometimes calls the level objects method - ad infinitum. This seems to be a
bug with the parent:: construct.
i.e.
class A{
function foo(){
print "A";
}
class B extends A{
function foo(){
parent::foo();
print "B";
}
class C extends B{
function foo(){
parent::foo();
print "C";
}
$bar=new C();
$bar->foo();
// Output would be:
CBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB..............
because parent::foo() in class B incorrectly resolves to B::foo().
So, I normally use the explicit class name construct, giving:
class A{
function foo(){
print "A";
}
class B extends A{
function foo(){
A::foo();
print "B";
}
class C extends B{
function foo(){
B::foo();
print "C";
}
$bar=new C();
$bar->foo();
// Output would be:
CBA
Hope this helps.
Neil
-----Original Message-----
From: Alexander Deruwe [mailto:aderuwe
deruwe.be]On Behalf Of Alexander
Deruwe
Sent: 03 September 2001 14:51
To: A. op de Weegh; php-general
lists.php.net
Subject: Re: [PHP] How to call a member from the base class?
On Monday 03 September 2001 09:47, A. op de Weegh wrote:
> How do I make sure in the something() member of class B, that the parent
> class member something() is also called? Can I do this:
Hello there, person with the same name as self, :)
class B extends A {
function something() {
// some other actions
$this->something(); // calls A::something
}
}
I've used this code for calling base class constructors. These ofcourse have
different names, while your functions are both called the same. I don't
think
that should make any difference, though.
ad.
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribelists.php.net For additional commands, e-mail: php-general-help
lists.php.net To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
What does everyone suggest I use as a search engine for my Intranet.
Out Intranet has grown to a size where a search engine is needed. I use PHP on Linux and I also use MySQL as my database.
Any suggestions?
Phil
attached mail follows:
Check this, but didn't the latest stable release of MySQL add search capabilities to text fields, as in indexing key words? How is your database structured? What do you use for keys? A simple form may be all you need.
For general indexing and searching of straight html there are htdig and mnogo.
Miles
At 08:50 AM 9/3/01 -0400, Phil Labonte wrote:
>What does everyone suggest I use as a search engine for my Intranet.
>
>Out Intranet has grown to a size where a search engine is needed. I use PHP
>on Linux and I also use MySQL as my database.
>
>Any suggestions?
>
>Phil
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
>For additional commands, e-mail: php-general-help
lists.php.net
>To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
Hi geeks,
I hope some one will solve my problem. I have a table in which a field is of date type. i want a mysql query to get all the records of the table into an array of a particular month.
thanks in advance.
/sagar
_________________________________________________________
Do You Yahoo!?
Get your free
yahoo.com address at http://mail.yahoo.com
attached mail follows:
"Sagar" <sagarphp
yahoo.com> wrote in message
news:001b01c1347e$b58e2580$6dfb7ccb
ravella...
> I hope some one will solve my problem.
> I have a table in which a field is of date type.
> i want a mysql query to get all the records of the table
> into an array of a particular month.
Some clarification is needed: do you want all entries for a given month of ANY year, or of a specific year?
If the first, I would use SELECT * FROM table WHERE MONTH(datefield) = mm (See the MySQL documentation, section 7.4.11)
Or, for the second SELECT * FROM table WHERE datefield BETWEEN 'yyyy-mm-01' AND 'yyyy-mm-31'
... how's that?
attached mail follows:
I have been thinking about a thing. If I have a PHP script (a) which receives some data by a POST method only -- GET method is track to not be accepted --, and if I have another PHP script (b) that takes initial input from the user's browser... Well, the question is: how can I, in the script "b", take the input data and post it to script "a" and receive its response, following by processing it and giving back the response to the browser? The user wouldn't see the action of script "a" in any way. To the user, only script "b" would exist. I think I can do this by using Delphi, but in PHP this task seens to be a nightmare.
browser ==input==> b ==post==> a... ...a ==response==> b ==response==> browser
Is this possible with PHP 3 or later?
attached mail follows:
I've never used method virtual but it seems to fit Your problem. Explanation below.
Krzysztof Kocjan
virtual
(PHP 3, PHP 4 >= 4.0b1)
virtual -- Perform an Apache sub-request
Description
int virtual (string filename)
virtual() is an Apache-specific function which is equivalent to <!--#include virtual...--> in mod_include. It performs an Apache sub-request. It is useful for including CGI scripts or .shtml files, or anything else that you would parse through Apache. Note that for a CGI script, the script must generate valid CGI headers. At the minimum that means it must generate a Content-type header. For PHP files, you need to use include() or require(); virtual() cannot be used to include a document which is itself a PHP file.
Jean Madson wrote:
> I have been thinking about a thing. If I have a PHP script (a) > which receives some data by a POST method only -- GET method > is track to not be accepted --, and if I have another PHP script (b) > that takes initial input from the user's browser... Well, the > question is: how can I, in the script "b", take the input data and > post it to script "a" and receive its response, > following by processing it and giving back the response > to the browser? The user wouldn't see the action of script "a" > in any way. To the user, only script "b" would exist. I think > I can do this by using Delphi, but in PHP this task seens to be > a nightmare. > > browser ==input==> b ==post==> a... > ...a ==response==> b ==response==> browser > > Is this possible with PHP 3 or later?
attached mail follows:
i get this error message Parse error: parse error in /web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53
for
$message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n". $cam. "\r\n". $quote.;
i honestly dont see whats wrong!
-lk6- http://www.StupeedStudios.f2s.com Home of the burning lego man!
ICQ: 115852509
MSN: dbzno1fan
hotmail.com
AIM: legokiller666
attached mail follows:
There is a dot at the end which is wrong : $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n". $cam. "\r\n". $quote.;
^
see this??
it should be like this :
$message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n".
$cam. "\r\n". $quote;
Regards,
Kunal Jhunjhunwala
----- Original Message -----
From: "Kyle Smith" <dbzno1fan
hotmail.com>
To: <php-general
lists.php.net>
Sent: Tuesday, September 04, 2001 3:20 AM
Subject: [PHP] I dont see whats wrong!
i get this error message Parse error: parse error in /web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53
for
$message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n". $cam. "\r\n". $quote.;
i honestly dont see whats wrong!
-lk6- http://www.StupeedStudios.f2s.com Home of the burning lego man!
ICQ: 115852509
MSN: dbzno1fan
hotmail.com
AIM: legokiller666
attached mail follows:
haha, it works, thanks
1 single dot can screw up a script.... phew!
-lk6- http://www.StupeedStudios.f2s.com Home of the burning lego man!
ICQ: 115852509
MSN: dbzno1fan
hotmail.com
AIM: legokiller666
----- Original Message -----
From: "Kunal Jhunjhunwala" <kunal
getmonked.net>
To: <php-general
lists.php.net>
Sent: Monday, September 03, 2001 7:00 AM
Subject: Re: [PHP] I dont see whats wrong!
> There is a dot at the end which is wrong :
> $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n".
> $cam. "\r\n". $quote.;
>
> ^
>
> see this??
> it should be like this :
> $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n".
> $cam. "\r\n". $quote;
> Regards,
> Kunal Jhunjhunwala
> ----- Original Message -----
> From: "Kyle Smith" <dbzno1fan
hotmail.com>
> To: <php-general
lists.php.net>
> Sent: Tuesday, September 04, 2001 3:20 AM
> Subject: [PHP] I dont see whats wrong!
>
>
> i get this error message
> Parse error: parse error in
> /web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53
>
> for
>
> $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n".
> $cam. "\r\n". $quote.;
>
> i honestly dont see whats wrong!
>
> -lk6-
> http://www.StupeedStudios.f2s.com
> Home of the burning lego man!
>
> ICQ: 115852509
> MSN: dbzno1fan
hotmail.com
> AIM: legokiller666
>
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
>
>
attached mail follows:
Try removing the last period(.) after $quote.
Also, try this method:
$nl = "\r\n";
$message = $alias$nl$name$email$...so on and so forth.
Come to think of it, I think PHP has a constant for "\r\". I think its NL or something like that, I can't remember. Look in the manual pages for some clues...hopefully, someone on here remember it.
I hope that helped.
-John
On Mon, 3 Sep 2001, Kyle Smith wrote:
> i get this error message
> Parse error: parse error in /web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53
>
> for
>
> $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n". $cam. "\r\n". $quote.;
>
> i honestly dont see whats wrong!
>
> -lk6-
> http://www.StupeedStudios.f2s.com
> Home of the burning lego man!
>
> ICQ: 115852509
> MSN: dbzno1fan
hotmail.com
> AIM: legokiller666
>
>
>
attached mail follows:
You could also perhaps try this.
$message = " $alias $name $email $site $cam $quote ";
Might not work in all cases though but it's certainly easier to read.
It all very much depends on personal preference.
Andy.
----- Original Message -----
From: "John Monfort" <monfort
kahuna.sdsu.edu>
To: "Kyle Smith" <dbzno1fan
hotmail.com>
Cc: <php-general
lists.php.net>
Sent: Monday, September 03, 2001 4:13 PM
Subject: Re: [PHP] I dont see whats wrong!
>
>
> Try removing the last period(.) after $quote.
>
> Also, try this method:
>
> $nl = "\r\n";
>
> $message = $alias$nl$name$email$...so on and so forth.
>
> Come to think of it, I think PHP has a constant for "\r\".
> I think its NL or something like that, I can't remember. Look in the
> manual pages for some clues...hopefully, someone on here remember it.
>
>
> I hope that helped.
>
>
> -John
>
>
> On Mon, 3 Sep 2001, Kyle Smith wrote:
>
> > i get this error message
> > Parse error: parse error in
/web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53
> >
> > for
> >
> > $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n".
$cam. "\r\n". $quote.;
> >
> > i honestly dont see whats wrong!
> >
> > -lk6-
> > http://www.StupeedStudios.f2s.com
> > Home of the burning lego man!
> >
> > ICQ: 115852509
> > MSN: dbzno1fan
hotmail.com
> > AIM: legokiller666
> >
> >
> >
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
>
attached mail follows:
So sprach »Kyle Smith« am 2001-09-03 um 14:50:49 -0700 : > i get this error message > Parse error: parse error in /web/sites/197/lk6/www.stupeedstudios.f2s.com/sendcam.php on line 53 > > for > > $message = $alias. "\r\n".$name. "\r\n". $email. "\r\n". $site. "\r\n". $cam. "\r\n". $quote.;
After the $quote, you've got a . - remove this, and it might work.
Alexander Skwar
-- How to quote: http://learn.to/quote (german) http://quote.6x.to (english) Homepage: http://www.digitalprojects.com | http://www.iso-top.de iso-top.de - Die günstige Art an Linux Distributionen zu kommen Uptime: 14 hours 38 minutes
attached mail follows:
So sprach »Andy Woolley« am 2001-09-03 um 16:37:08 +0100 : > Might not work in all cases though but it's certainly easier to read.
Also easy to read:
$msg = array( $foo, $bar, $blah, $blub );
echo implode("\r\n", $msg);
Alexander Skwar
-- How to quote: http://learn.to/quote (german) http://quote.6x.to (english) Homepage: http://www.digitalprojects.com | http://www.iso-top.de iso-top.de - Die günstige Art an Linux Distributionen zu kommen Uptime: 14 hours 39 minutes
attached mail follows:
Hi, small problem :
phpinfo() shows all kinds of useful variables like PHP_SELF, PATH_INFO, etc etc.... but I can't see them from my script.
I get a error - "Warning: Undefined variable: PATH_INFO in [scriptname] on line 13"
Is there any situation where such variables would be available to phpinfo(), but not the rest of the script?
Setup is Win2K, Apache, PHP 4.06
Any thoughts?
attached mail follows:
On Mon, 03 Sep 2001 15:11:04 -0700, you wrote:
Following up my own post (in case someone finds this in the archives):
>Is there any situation where such variables would be available to >phpinfo(), but not the rest of the script?
You can't see $PHP_SELF within a function until you declare it global.
This language really frustrates me sometimes...
attached mail follows:
<Original message>
From: David Otton <david.otton
overnetdata.com>
Date: Mon, Sep 03, 2001 at 03:21:00PM -0700
Message-ID: <1f08pt8kv2408sajn4ssrhlqpp48shurfi
4ax.com>
Subject: Re: [PHP] Problem with PHP_SELF
> On Mon, 03 Sep 2001 15:11:04 -0700, you wrote: > > Following up my own post (in case someone finds this in the archives): > > >Is there any situation where such variables would be available to > >phpinfo(), but not the rest of the script? > > You can't see $PHP_SELF within a function until you declare it global. > > This language really frustrates me sometimes...
</Original message>
<Reply>
It's not so frustrating if you configure it correct. If you set register_globals, you can just use 'm everywhere. It's not something you should do, though. You can better use $HTTP_SERVER_VARS[]. It's (some) safer. For those you don't need to turn on the register_globals. Just turning on track_vars will do then. And from PHP 4.0.3 you don't even need to do that.
<Quote from PHP manual> PHP variables
These variables are created by PHP itself. The $HTTP_*_VARS variables are available only if the track_vars configuration is turned on. When enabled, the variables are always set, even if they are empty arrays. This prevents a malicious user from spoofing these variables.
Note: As of PHP 4.0.3, track_vars is always turned on, regardless of the configuration file setting.
If the register_globals directive is set, then these variables will also be made available in the global scope of the script; i.e., separate from the $HTTP_*_VARS arrays. This feature should be used with care, and turned off if possible; while the $HTTP_*_VARS variables are safe, the bare global equivalents can be overwritten by user input, with possibly malicious intent. If you cannot turn off register_globals, you must take whatever steps are necessary to ensure that the data you are using is safe. </Quote from PHP manual>
See: http://www.php.net/manual/en/language.variables.predefined.php
</Reply>
--* R&zE:
-- »»»»»»»»»»»»»»»»»»»»»»»» -- Renze Munnik -- DataLink BV -- -- E: renze
datalink.nl -- W: +31 23 5326162 -- F: +31 23 5322144 -- M: +31 6 21811143 -- -- Stationsplein 82 -- 2011 LM HAARLEM -- Netherlands -- -- http://www.datalink.nl -- ««««««««««««««««««««««««
attached mail follows:
I couldn't help but frown at this message... This is typical of this and hundreds of other lists... instead of learning the language, people just jump in, try to write code, and then when something doesn't work, it's the language's fault... It absolutely amazes me that such a huge number of people don't bother reading the manual or even attempt learning the basics...
global variables have to be declared in functions. It's a basic fact, and should've been learned before even attempting a line of code...
> -----Original Message-----
> From: David Otton [mailto:david.otton
overnetdata.com]
> Sent: Monday, September 03, 2001 3:21 PM
> To: David Otton
> Cc: php-general
lists.php.net
> Subject: Re: [PHP] Problem with PHP_SELF
>
>
> On Mon, 03 Sep 2001 15:11:04 -0700, you wrote:
>
> Following up my own post (in case someone finds this in the archives):
>
> >Is there any situation where such variables would be available to
> >phpinfo(), but not the rest of the script?
>
> You can't see $PHP_SELF within a function until you declare it global.
>
> This language really frustrates me sometimes...
attached mail follows:
On Mon, 3 Sep 2001 09:16:00 -0700, you wrote:
>I couldn't help but frown at this message... This is typical of this and >hundreds of other lists... instead of learning the language, people just >jump in, try to write code, and then when something doesn't work, it's the >language's fault... It absolutely amazes me that such a huge number of >people don't bother reading the manual or even attempt learning the >basics...
The tone of your message is well-deserved... I switched to "help me" mode long before I should have because I was under pressure of time.
>global variables have to be declared in functions. It's a basic fact, and >should've been learned before even attempting a line of code...
In fact, the function in question /already/ had a bunch of my own variables declared global in it... I thoughtlessly jumped to the conclusion that the install was at fault because i have reason not to trust it.
My other point still stands though (I think) - that marking a variable as "global" to "pull it in to scope" is a clunky, ass-backwards way of doing things.
djo
attached mail follows:
From: "David Otton" <david.otton
overnetdata.com>
> My other point still stands though (I think) - that marking a variable
> as "global" to "pull it in to scope" is a clunky, ass-backwards way of
> doing things.
Which is why, of course, that parameters were invented "way back when".
attached mail follows:
In article <5pv7ptk783alimfd98h5nt4codv2u2bqii
4ax.com>,
david.otton
overnetdata.com (David Otton) wrote:
> I get a error - "Warning: Undefined variable: PATH_INFO in > [scriptname] on line 13" > > Is there any situation where such variables would be available to > phpinfo(), but not the rest of the script?
Yes, where $PATH_INFO is called from within a function without being declared as global first. See the manual's chapter on variable scope.
-- CC
attached mail follows:
Hi, Folks!
Can I read from an mdb database direct from PHP like DBF, for example?
[]´s Rogerio Coelho. Equipeweb - CompuLand Design http://www.equipeweb.com.br Tel/Fax:(xx) 24 237-2088
attached mail follows:
Hi, you can see the ODBCSocketServer application driver. Check some related topics in the google.com search engine.
Atte. Ignacio Estrada F. Centro Nacional de Control de Energia Area de Control Occidental 025+6463, 025+6464, 025+6469
attached mail follows:
Man, this is a real value!
I was in a trouble thinking how to publish data coming from the administration area. Thinking in programming visual basic interfaces, generate SQL inserts, etc. But now you can simply publish it and thats all! Browsing with google, I found this well written article from Tim Uckun "ODBC Socket Server" http://www.phpbuilder.com/columns/timuckun20001207.php3?print_mode=1
Dos cositas:
1. This works for any ODBC filter installed on the windows server? So, we can browse and update excel, text, SQL Server, etc, without having to compile native support in the php?
2. The page at http://odbc.linuxave.net/, stated as the source for the ODBCSocketServer server, is not on-line now. Does anybody knoes if this will be fixed soon? Is there another source for the ODBCSocketServer server?
Ignacio Estrada wrote:
> Hi, you can see the ODBCSocketServer application driver. Check some > related topics in the google.com search engine. > > Atte. Ignacio Estrada F. > Centro Nacional de Control de Energia > Area de Control Occidental > 025+6463, 025+6464, 025+6469 > >
attached mail follows:
> -----Original Message-----
> From: Alfredo Yong [mailto:alfredo_yong_php
yahoo.com]
> Sent: Monday, September 03, 2001 11:05 AM
> To: php-general
lists.php.net
> Subject: Re: [PHP] MDB
>
>
> 2. The page at http://odbc.linuxave.net/, stated as the
> source for the ODBCSocketServer server, is not on-line
> now. Does anybody knoes if this will be fixed soon? Is
> there another source for the ODBCSocketServer server?
--- Mark Roedel | "Blessed is he who has learned to laugh Systems Programmer | at himself, for he shall never cease LeTourneau University | to be entertained." Longview, Texas, USA | -- John Powell
attached mail follows:
Respecto al punto 1 la respuesta es SI, ya que no es necesario involucrar PHP en este lado. Atte. Ignacio Estrada F. Centro Nacional de Control de Energia Area de Control Occidental 025+6463, 025+6464, 025+6469
Alfredo Yong
<alfredo_yong_php
To: php-general
lists.php.net
yahoo.com> cc:
Subject: Re: [PHP] MDB
03/09/2001 10:05
Man, this is a real value!
I was in a trouble thinking how to publish data coming from the administration area. Thinking in programming visual basic interfaces, generate SQL inserts, etc. But now you can simply publish it and thats all! Browsing with google, I found this well written article from Tim Uckun "ODBC Socket Server" http://www.phpbuilder.com/columns/timuckun20001207.php3?print_mode=1
Dos cositas:
1. This works for any ODBC filter installed on the windows server? So, we can browse and update excel, text, SQL Server, etc, without having to compile native support in the php?
2. The page at http://odbc.linuxave.net/, stated as the source for the ODBCSocketServer server, is not on-line now. Does anybody knoes if this will be fixed soon? Is there another source for the ODBCSocketServer server?
Ignacio Estrada wrote:
> Hi, you can see the ODBCSocketServer application driver. Check some > related topics in the google.com search engine. > > Atte. Ignacio Estrada F. > Centro Nacional de Control de Energia > Area de Control Occidental > 025+6463, 025+6464, 025+6469 > >
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribelists.php.net For additional commands, e-mail: php-general-help
lists.php.net To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
Hi,
I am creating an image made up of other images. How can i read in a gif and put it onto the image I am creating through php?
Thanks,
Mike
attached mail follows:
"Jon Farmer" <jonfarmer
enta.net> wrote in message
news:003f01c1345c$53e385e0$70604ac3
enta.net...
> The company I work for is starting to lose contracts because they are not
> capable of EDI. As I seem to be the only person in the company who has
heard
> of EDI and knows what it stands for I am assumed to be an expert :-)
Ain't it always the way :-)
> Anyway, I would like to suggest that instead of EDI we use XML and use PHP > both as a parser and a creater of the EDI like transactions. I would propose > they are sent over the net and probably PGP encrypted or signed. I have done > some minor work with PHP and XML, mainly credit card authorisation, but > wondered how suited it would be to this kind of app?
http://www.computerworld.com/cwi/story/0,1199,NAV47-68-85-1552_STO55904,00.h tml http://www.xml.com/search/index.ncsp?sp-q=EDI
PHP should be quite capable of handling this, but you will end up creating a lot of the business logic from scratch. If your company already uses integrated management software like SAP, it may have EDI capabilities built in.
attached mail follows:
No, we would have to spend around £24,000 sterling to get the modules. We already have modules that allow importing of order, etc from txt files. I could write a PHP XML parser to interface into this.
What I am not sure is how acceptable it will be to our customers
-- -- Jon Farmer Systems Programmer, Entanet www.enta.net Tel 01952 428969 Mob 07968 524175 PGP Key available, send blank email to pgpkeybctech.co.uk
> http://www.computerworld.com/cwi/story/0,1199,NAV47-68-85-1552_STO55904,00.h > tml > http://www.xml.com/search/index.ncsp?sp-q=EDI > > PHP should be quite capable of handling this, > but you will end up creating a lot of the business > logic from scratch. If your company already uses > integrated management software like SAP, it may
attached mail follows:
Hi,
You can also try to use Java (the list is going to run over me with this comment). Xerces parser is quite good and amazinly fast, and opensource. We are validating XML document of 3Mb with it, and it is done in three seconds (creating a DOM object). It is just another idea if you haven't look at it.
Also you can keep the logic more organized with the object structure.
Sean C. McCarthy SCI, S.L. (www.sci-spain.com)
Jon Farmer wrote:
>
> No, we would have to spend around £24,000 sterling to get the modules. We
> already have modules that allow importing of order, etc from txt files. I
> could write a PHP XML parser to interface into this.
>
> What I am not sure is how acceptable it will be to our customers
> --
> --
> Jon Farmer
> Systems Programmer, Entanet www.enta.net
> Tel 01952 428969 Mob 07968 524175
> PGP Key available, send blank email to pgpkey
bctech.co.uk
>
> >
> http://www.computerworld.com/cwi/story/0,1199,NAV47-68-85-1552_STO55904,00.h
> > tml
> > http://www.xml.com/search/index.ncsp?sp-q=EDI
> >
> > PHP should be quite capable of handling this,
> > but you will end up creating a lot of the business
> > logic from scratch. If your company already uses
> > integrated management software like SAP, it may
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
> Hi
>
> I've put the full path in for mysql, i've included -h -u -p and included
the
> paths of the txt & table files
>
> Still don't work.
>
> I'm logged in as root, working on my own box (linux) .
> I'm really struggling with this one.
> Has anyone out there done this ??
>
> Many TIA
> Terry
> ----- Original Message -----
> From: "_lallous" <elias_bachaalany
yahoo.com>
> To: <php-general
lists.php.net>
> Sent: Monday, September 03, 2001 9:24 AM
> Subject: [PHP] Re: probs with exec, pls help
>
>
> > should'nt I guess....
> > I should at least specify full path of mysqlimport as in:
> > exec("/usr/local/mysql/bin/mysqlimport -u -p dada dasda")
> >
> > "Taz" <terry
tazwebservices.co.uk> wrote in message
> > news:002801c133f3$1e2204e0$0feafea9
reynolds...
> > Should this work, if not, why not
> >
> > <?php exec("mysqlimport -u root -ppasword test one.txt") ?>
> >
> > the import works fine from the command line
> >
> > TIA
> > Terry
> >
> >
> >
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> > For additional commands, e-mail: php-general-help
lists.php.net
> > To contact the list administrators, e-mail: php-list-admin
lists.php.net
> >
> >
>
attached mail follows:
Hello Bob,
Monday, September 03, 2001, 1:08:40 PM, you wrote: B> If in 1995 you tell a project manager that I can program B> hotmail.com in a couple weeks and that it would be a lot faster then cgi B> then they would of been forced to use it and all the marketing would not B> matter. Then (maybe) hotmail could have been written in php, but again, it would be hotmail, not squirrelmail. We know hotmail as it is now not because it is written in perl/asp/php/jsp/whatever, but because it is simply a successful project. Marketing and promotion here means more than the underlying engine - without it there would be no hotmail or yahoo, but something else, like, say, coldmail and hoooya, better promoted.
Meanwhile, there were no microwave oven in 1950. It simply could not exist in 1950. Like PHP, ASP, JSP, etc. could not exist in 1985 in the current form. Technology needs time to improve.
-- Best regards, Maxim Derkachev mailto:max.derkachevbooks.ru System administrator & programmer, Symbol-Plus Publishing Ltd. phone: +7 (812) 324-53-53 www.books.ru, www.symbol.ru
attached mail follows:
Hi Maxim,
Hotmail was hot because nobody had ever seen free webmail and it spread by word of mouth. I don't know but did anyone see a hotmail commerical???
What I am saying is that if php is always following or copying the technology that happened a couple years ago then what's the point? php will then always be known as the low cost option and project managers won't even give it a second look. What I am looking for is the cool factor. I know technology needs time to improve but what's going to be cool in PHP5??? It's like a race that never finishes and who is winning? ASP or PHP?
Maxim Derkachev wrote:
> Hello Bob,
>
> Monday, September 03, 2001, 1:08:40 PM, you wrote:
> B> If in 1995 you tell a project manager that I can program
> B> hotmail.com in a couple weeks and that it would be a lot faster then cgi
> B> then they would of been forced to use it and all the marketing would not
> B> matter.
> Then (maybe) hotmail could have been written in php, but again, it
> would be hotmail, not squirrelmail. We know hotmail as it is now not because
> it is written in perl/asp/php/jsp/whatever, but because it is simply a
> successful project. Marketing and promotion here means more than the
> underlying engine - without it there would be no hotmail or yahoo, but
> something else, like, say, coldmail and hoooya, better promoted.
>
> Meanwhile, there were no microwave oven in 1950. It simply could not
> exist in 1950. Like PHP, ASP, JSP, etc. could not exist in 1985 in the
> current form. Technology needs time to improve.
>
> --
> Best regards,
> Maxim Derkachev mailto:max.derkachev
books.ru
> System administrator & programmer,
> Symbol-Plus Publishing Ltd.
> phone: +7 (812) 324-53-53
> www.books.ru, www.symbol.ru
_________________________________________________________
Do You Yahoo!?
Get your free
yahoo.com address at http://mail.yahoo.com
attached mail follows:
> What I am saying is that if php is always following or copying the technology > that happened a couple years ago then what's the point? php will then always be > known as the low cost option and project managers won't even give it a second > look. What I am looking for is the cool factor. I know technology needs time > to improve but what's going to be cool in PHP5??? It's like a race that never > finishes and who is winning? ASP or PHP?
Uh? The first version of PHP was released over a year before the first version of ASP. Heck, there were even M$ developers on the first PHP mailing list that at one point sent out a survey asking the PHP community what they wanted to see in an HTML-embedded scripting language.
But sure, PHP will always be the "low cost option". No real way around that being an open source project, and frankly that is a big feature and certainly not a liability.
-Rasmus
attached mail follows:
On Mon, 3 Sep 2001, Bob wrote:
> look. What I am looking for is the cool factor. I know technology needs time > to improve but what's going to be cool in PHP5??? It's like a race that never > finishes and who is winning? ASP or PHP?
PHP5 will still run on your Free OS, your CLI OS, your Pay OS, your GUI OS, etc. ASP (of the VBSchidtz flavor) will only run on your Illegal Monopoly OS. It's so cool it burns! Flexibility, portability, and cost-effectiveness ... you won't get burned.
Ras ... ROCK ON!!
~Chris /"\ \ / Pine Ribbon Campaign Microsoft Security Specialist X Against Outlook The moron in Oxymoron. / \ http://www.thebackrow.net
attached mail follows:
On Lun 03 Sep 2001 17:49, Bob wrote: > Hi Maxim, > > Hotmail was hot because nobody had ever seen free webmail and it spread by > word of mouth. I don't know but did anyone see a hotmail commerical??? > > What I am saying is that if php is always following or copying the > technology that happened a couple years ago then what's the point? php > will then always be known as the low cost option and project managers won't > even give it a second look. What I am looking for is the cool factor. I > know technology needs time to improve but what's going to be cool in > PHP5??? It's like a race that never finishes and who is winning? ASP or > PHP?
Well, whats your contribution? I mean, ideas. Like what would you like PHP to have in the version 5?
I am in some other free projects, and I can tell you that there is so much to do, that the developers don't have time to finish them, so you'll see in the TODO lists things like: "Didn't have time to finish it. Maybe in the next version."
But let me say one last things, the developers also need some ideas, like what you want, and if ASP has something interesting that PHP doesn't then you have to go for it!
At least that's my thinking
Saludos... ;-)
-- Porqué usar una base de datos relacional cualquiera, si podés usar PostgreSQL? ----------------------------------------------------------------- Martín Marqués | mmarquesunl.edu.ar Programador, Administrador, DBA | Centro de Telematica Universidad Nacional del Litoral -----------------------------------------------------------------
attached mail follows:
David Robley wrote:
> On Mon, 3 Sep 2001 17:00, taz wrote: >><?php exec("mysqlimport -u root -ppasword test one.txt") ?>
> Probably the user that your webserver, and hence your php script, runs as > does not have permissions to execute mysqlimport.
Or, mysqlimport is not in the path - try using the complete path and see if that solves it.
--
_______ ___ _ ____ _____
Chris Hobbs / ____\ \ / / | | |/ ___\| __ \
Head Geek | (___ \ \ / /| | | | (___ | | | |
WebMaster \___ \ \ \/ / | | | |\___ \| | | |
PostMaster ____) | \ / | |__| |____) | |__| |
\____/ \/ \____/ \____/|_____/
http://www.silvervalley.k12.ca.us
chobbs
silvervalley.k12.ca.us
attached mail follows:
Hello everyone... I have been working on this random function for awhile now.. and it is close to being complete. It works as for a random function. But what my goal was is to make it where it goes through all the images before showing a random twice. Kind of like you put all the images in a bucket, and random select one out of the bucket while you eyes are closed, once you take it out of the bucket you put it on the table till there is no images left in the bucket, then you fill the bucket again and start over.
Now... I thought the following function did that, but for some reason it is not... I might have just missed a line of code, or misspelled something, but I come to you guys/gals to be more second pair of fresh eyes to see if you can find where I made a mistake.
Thanks..
-------------code snippet-------------------- function getRandomUser() { static $itemarray; if (empty($itemarray)) { $connection = mysql_pconnect(SQL_SERVER, SQL_UID, SQL_PWD); mysql_select_db(SQL_DB, $connection); $sql = "select * from user where valid = 1 and inrotation = 1"; $query = mysql_query($sql); while($thisrow = mysql_fetch_array($query)) { $itemarray[] = $thisrow; } } if (sizeof($itemarray) == 0) return Array('userid'=>'-1', "photo_name"=>'', "photo_num"=>'', "counter"=>'', "size"=>''); srand((double)microtime()*1000000); $row = rand(0, sizeof($itemarray)- 1); $toreturn = $itemarray[$row]; $itemarray = array_splice($itemarray,$row,1);
return $toreturn; } -------------code snippet--------------------
thanks guys... :)
Brad C
attached mail follows:
"Brad R. C." <bradc
addictedusers.com> wrote in message
news:ELEKJPELJEFCJONHNNAOMEBCCJAA.bradc
addictedusers.com...
> But what my goal was is to make it where it goes through all the images
> before showing a random twice.
... if you actually want to do this, you will have to keep track of which items you have seen in the last rotation.
> Now... I thought the following function did that, but for some reason it is > not...
Nope. You are just (inefficiently) choosing one item at random.
An equivalent-but-faster approach would be SELECT * FROM user WHERE valid=1 AND inrotation=1 ORDER BY RAND() LIMIT 1
If you really need random-order, once-per-cycle images, you could achieve it by adding a 'views' field to the table; initialize all entries to the same value (ie 0). Each time an image is displayed, increment the views; when you choose an image, choose from the pool where the views value is minimal, ie.
SELECT id,imgname FROM user WHERE valid=1 AND inrotation=1 AND views=MIN(views) ORDER BY RAND() LIMIT 1
UPDATE user SET views=views+1 WHERE id=$id
How's that?
attached mail follows:
You know what.. that might just work the way I need it to... will try it out tonight, thanks!!! :)
Brad C.
-----Original Message-----
From: Hugh Bothwell [mailto:hugh_bothwell
hotmail.com]
Sent: Monday, September 03, 2001 1:05 PM
To: php-general
lists.php.net
Subject: [PHP] Re: Pulling a random image
"Brad R. C." <bradc
addictedusers.com> wrote in message
news:ELEKJPELJEFCJONHNNAOMEBCCJAA.bradc
addictedusers.com...
> But what my goal was is to make it where it goes through all the images
> before showing a random twice.
... if you actually want to do this, you will have to keep track of which items you have seen in the last rotation.
> Now... I thought the following function did that, but for some reason it is > not...
Nope. You are just (inefficiently) choosing one item at random.
An equivalent-but-faster approach would be SELECT * FROM user WHERE valid=1 AND inrotation=1 ORDER BY RAND() LIMIT 1
If you really need random-order, once-per-cycle images, you could achieve it by adding a 'views' field to the table; initialize all entries to the same value (ie 0). Each time an image is displayed, increment the views; when you choose an image, choose from the pool where the views value is minimal, ie.
SELECT id,imgname FROM user WHERE valid=1 AND inrotation=1 AND views=MIN(views) ORDER BY RAND() LIMIT 1
UPDATE user SET views=views+1 WHERE id=$id
How's that?
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribelists.php.net For additional commands, e-mail: php-general-help
lists.php.net To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
>what does that entail?
>
>>"Rasmus Lerdorf" <rasmus
php.net> wrote in message
>>news:Pine.LNX.4.33.0109031300500.1243-100000
rasmus.php.net...
>> Why not just configure your server to use an auto_prepend_file ?
Reading the documentation that's easily available.
attached mail follows:
Hello Everybody,
I have a software writen in Delphi which I am migrating to Kylix but I would like to do it in PHP instead.
What the software does is to access an e-mail address and retrieve the messages saving the files ending with .zip to a local directory. After that, it decompresses the ZIP files and read their txt contents and import the contents to a MySQL database. Each ZIP file has a TXT file.
So what I need to know and the help I am asking you for is :
1) How to retrieve messages from a POP3 mailbox and save only the ZIP files attachments?
2) How to decompress the ZIP files?
Thank you,
Carlos Fernando.
Linux User #207984
attached mail follows:
> 1) How to retrieve messages from a POP3 mailbox and save only > the ZIP files attachments?
A couple of ways.
1. Use the imap (it does pop3 too) extension to connect to the mail server, parse the mails and extract the zip files.
2. Use mime decoding php scripts. There's one I've just committed to PEAR, which you can get by going to cvs.php.net --> php4 --> pear --> mail --> mimeDecode.php. It's beta quality at the moment, but should get better. Also, this is just a class/object, so it will require incorporating into your own scripts.
> 2) How to decompress the ZIP files?
If you're on unix, exec('unzip ...'). Or if windows, you can use the cmd line version of winzip.
-- Richard Heyes
attached mail follows:
Try writing a custom error handler. Chech out http://www.zend.com/zend/spotlight/error.php for a good article on the subject. Pay particular attention to the bit at the end about output buffering since I assume that what you would want to do is send a redirect header to the browser if the script fails to work.
"Tim Ward" <tim.ward
stivesdirect.com> wrote
> I've gone an annoying problem. On our site I've trapped "file does not
> exist" errors at Apache level to send out my own error screen with a
company
> logo, link to home page and a mailto link, but this doesn't work for any
> request for a page that would be parsed by php if it existed. In this case
a
> valid html page (containing the php error) is returned. The problem seems
to
> be that as far as Apache is concerned there isn't an error. I haven't
found
> anything in php that allows me to trap errors like this. Error reporting
> levels aren't helpful as I still need the error trapped.
>
> I'm sure I'm not the first person who has come across this, and I'm hoping
> someone out there has found a way around it.
>
> I'm running PHP 4.0.0, Apache 1.3 on NT (yes I know, but our network
manager
> has promised me a linux box)
>
> Tim Ward
> Senior Systems Engineer
>
> Please refer to the following disclaimer in respect of this message:
> http://www.stivesdirect.com/e-mail-disclaimer.html
>
>
attached mail follows:
Honestly, that seems like one damn big file to me. Are you using all those functions in every single file? If not, you're loading and (re)compiling a hell of a lot of code on every page request. If you're done developing, it may be time to split that up into more logical files (all db functions in one, all functions relating to page X in another, etc.)
speedboy wrote:
>What do people do with required files? I have a file called config.php >which contains all my functions. It is 329526 bytes. Should I split this >up into other files? I don't think so, but what do others think? > >
attached mail follows:
Thanks for the info. Did you install Apache and PHP binaries derived from the rpm's on the distribution disk or did you download sources from the websites and configure/compile/install from sources?
Peter Clarke wrote: > I've recently installed: > Red Hat Linux release 7.1 (Seawolf), PHP 4.0.6 Apache, 1.3.20 DSO from > scratch with no problems. > also: > Red Hat Linux release 6.1 (Cartman), PHP 4.0.6 Apache, 1.3.20 DSO from > scratch with no problems. > > Just so you know it can work. > > Peter
attached mail follows:
I have made a detetor of relevance in found results in form of colored ine od length depended on relevance. I did it this way:
In query I inserted match (...,...,...) against ('%$var%') as relevance in while loop I inserted $relevance = $row["relevance"]; $rel = round($relevance); print "<img src=\"images/rel.gif\" border=\"0\" height=\"7\" width=\"$rel"."0"."\" alt=\"relevance\">\n";
And everything works fine but I'm wondering if anyone has better idea, because I'm just a newbie, never did it before and this page is my first try, this code is my idea but I don't conside myself smart in PHP.
Thank you,
Youri
<>< <>< <>< <>< God is our provider ><> ><> ><> ><> http://www.body-builders.org
attached mail follows:
Hi,
I asked recently to help with the selection for FULLTEXT search and now with your help I found how to do that but I still have problem with advansed search.
This is what I have right now:
$result = mysql_query("SELECT skits.*,category.* from skits,category where (skits.title like '%$title_search%' && skits.descr like '%$descr_search%' && skits.skits like '%$act_search%' && skits.lang like '%$lang_search%' && category.kat_name like '%$category_search%') and (skits.category like category.cat_id) ORDER by skits.category limit $limit,10");
It sorts results by category, I want them to be sorted by relevance and there are three columns in my table are in FULLTEXT index - skits.title, skits.descr,skits.skits so I do this -
if ($title_search != "" && $descr_search= "" && $act_search = ""): $relev = $title_search; elseif ():// this is for every condition, just do not want to type it all. $... endifl
$result = mysql_query("SELECT skits.*,category.*,match (skits.title,skits.descr,skits.skits) against ('$relev') as from skits,category where (skits.title like '%$title_search%' && skits.descr like '%$descr_search%' && skits.skits like '%$act_search%' && skits.lang like '%$lang_search%' && category.kat_name like '%$category_search%') and (skits.category like category.cat_id) ORDER by relevance desc limit $limit,10");
But the proble is that this either don't find any results or select all records. What to do to make advenced search sorted by relevance?
Thank you,
Youri <>< <>< <>< <>< God is our provider ><> ><> ><> ><> http://www.body-builders.org
attached mail follows:
On Mon, 3 Sep 2001 19:33:38 +0200, BRACK (brak
nettaxi.com) wrote:
>$result = mysql_query("SELECT skits.*,category.*,match
>(skits.title,skits.descr,skits.skits) against ('$relev') as from
oops, should be 'against ('$relev') as relevance from'
>skits,category where (skits.title like '%$title_search%' &&
use 'and' instead of &&
>skits.descr like '%$descr_search%' && skits.skits like >'%$act_search%' && skits.lang like '%$lang_search%' && >category.kat_name like '%$category_search%') and >(skits.category like category.cat_id) ORDER by relevance desc >limit $limit,10");
attached mail follows:
i want to randomly choose a column in a database with a quote in it, by the number of the column. i have a random seed working, but it won't pull only one column, but all columns. How can I choose just one column, and print one column at a time?
thanks, Melih
attached mail follows:
"Melih Onvural" <melih
bellsouth.net> wrote in message
news:HHEKIFCGOCEGCKHMPLEHGEPACAAA.melih
bellsouth.net...
> i want to randomly choose a column in a database with a quote in it, by
the
> number of the column.
> i have a random seed working, but it won't pull only one column, but all
> columns. How can I choose
> just one column, and print one column at a time?
SELECT text FROM quotes ORDER BY RAND() LIMIT 1
attached mail follows:
Hi!
I want to encode a variable data this way...
session_start(); session_register("dhaval"); $dhaval = "trythisout"; session_encode($dhaval);
when I check out the c:\tmp\ directory and check out the session data I can still read the same as dhaval=trythisout and it's not encoded...is it coz the session_encode isn';t working or that I am wrong somewhere..?
Thanx
Dhaval Desai
__________________________________________________ Do You Yahoo!? Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger http://im.yahoo.com
attached mail follows:
On Mon, 3 Sep 2001, Dhaval Desai wrote:
> session_encode($dhaval); ... > when I check out the c:\tmp\ directory and check out > the session data I can still read the same as > dhaval=trythisout and it's not encoded...is it coz the
session_encode() returns a string for you to use in a PHP script. It doesn't encode or encrypt the session data on the server. If you need to encode or encrypt the data on the server, you have to create an encoding or encrypting scheme within your PHP scripts.
~Chris /"\ \ / Pine Ribbon Campaign Microsoft Security Specialist X Against Outlook The moron in Oxymoron. / \ http://www.thebackrow.net
attached mail follows:
speedboy wrote: > > What do people do with required files? I have a file called config.php > which contains all my functions. It is 329526 bytes. Should I split this > up into other files? I don't think so, but what do others think?
I too am curious about a recommended or best practice. I create a function file that contains numerous functions for generating forms that are used more than once in a site and it becomes large when the forms are complex. But the alternative is to bloat the individual files by including the function code on each page that uses it. Or, if you split the one, large file into some number of smaller files, it increases the administrative burden of knowing what is in each smaller file and requiring the correct sub-file in the right context rather than routinely requiring the one catch-all file every time one or more function is needed.
Kris O.
attached mail follows:
> > What do people do with required files? I have a file called config.php > > which contains all my functions. It is 329526 bytes. Should I split this > > up into other files? I don't think so, but what do others think? > > I too am curious about a recommended or best practice.
what you want todo is split them up by purpose so you can include as needed
also check the differences on include (include_once) versus require (require_once)
greets,
Lukas Smith
smith
dybnet.de
____________________________
DybNet Internet Solutions GbR
Alt Moabit 89
10559 Berlin
Tel. : +49 30 83 22 50 00
Fax : +49 30 83 22 50 07
www.dybnet.de info
dybnet.de
____________________________
attached mail follows:
> Yeah. Now that I understand more about COM and IDispatch > things are going smoothly. > Question: how do I close a connection to the COM object?
in general you simply call ->release() on the component. if you call release() as often as addref() (note that addref() is called implicitly on instanciation) the component should be closed by windows. windows 2k can also pool instances of components (i don't know if this is the case for dcom), so if you release an instance windows will still keep it alive and assign it to the next process that requests it.
in php references are counted internally and each php-thread calls the components addref() only once, regardless how often you call $obj->addref(); so all references will be released when the script terminates (this should prevent user errors) so a component gets closed when the script shuts down (beside the underlying instance pooling) so you don't need to close the connection by hand.
if you have to close components in a specified order or if script execution takes very long you can simply call
$obj->release(); $obj = null; // note that $obj = null; alone wouldn't close the connection immediately, because the garbage collector // runs very seldom. most of the time $obj would get released on script shutdown.
harald.
attached mail follows:
Can I increase speed by using this to buffer output ?
kind regards Jeroen Olthof
attached mail follows:
help!!!
I'm recursivley reading and editing every .htm and .html file in a 1000 page website and upgrading it to contain linked CSS, Javascript includes and PHP includes. the script works fine and all, trouble is that PHP doesn't.
Sometimes the script will run fine, other times PHP will decide to read the same file 10-20 times and then do the same recursivly, other times it'll say it's in one directory, and be reading files from another.
i'm running PHP verson 4.0.4pl1 off a 2000 server and IIS
attached mail follows:
Why not just configure your server to use an auto_prepend_file ?
On Mon, 3 Sep 2001, skater wrote:
> help!!! > > I'm recursivley reading and editing every .htm and .html file in a 1000 page > website and upgrading it to contain linked CSS, Javascript includes and PHP > includes. the script works fine and all, trouble is that PHP doesn't. > > Sometimes the script will run fine, other times PHP will decide to read the > same file 10-20 times and then do the same recursivly, other times it'll say > it's in one directory, and be reading files from another. > > i'm running PHP verson 4.0.4pl1 off a 2000 server and IIS > > > >
attached mail follows:
what does that entail?
"Rasmus Lerdorf" <rasmus
php.net> wrote in message
news:Pine.LNX.4.33.0109031300500.1243-100000
rasmus.php.net...
> Why not just configure your server to use an auto_prepend_file ?
attached mail follows:
Skater wrote:
> what does that entail?
>
>
> "Rasmus Lerdorf" <rasmus
php.net> wrote in message
> news:Pine.LNX.4.33.0109031300500.1243-100000
rasmus.php.net...
>
>>Why not just configure your server to use an auto_prepend_file ?
>>
>
>
Reading the manual every now and then wouldn't hurt... really, it wouldn't :).
<snip> auto_prepend_file string Specifies the name of a file that is automatically parsed before the main file. The file is included as if it was called with the include() function, so include_path is used.
The special value none disables auto-prepending. </snip>
-- Franklin van Velthuizen fvebiris.se +46-(0)70-6786613 Ebiris Applications AB http://www.ebiris.se/ +46-(0)19-109910
attached mail follows:
okay, sorry, had a blonde moment!!!
it's more than just having a prepend and appending file onto it, i'm changing existing CSS into linked ones, existing Javascripts into includes, and taking the whole thing out of frames by using PHP includes in a table. each page needs to be edited and have certain bits taken out and changed. i've done this with regular expressions and it solves the problem, but PHP seems to have problems recursivley.
without warning and completely randomly, PHP will read the same file or directory [x] amount of times... it's really annoying because after reading 8000 files in a 1000 file site, the script times out...
"Franklin Van Velthuizen" <php
yoki.org> wrote in message
news:3B93E609.9000505
yoki.org...
> Skater wrote:
> > what does that entail?
> >
> >
> > "Rasmus Lerdorf" <rasmus
php.net> wrote in message
> > news:Pine.LNX.4.33.0109031300500.1243-100000
rasmus.php.net...
> >
> >>Why not just configure your server to use an auto_prepend_file ?
> >>
> >
> >
>
> Reading the manual every now and then wouldn't hurt... really, it
> wouldn't :).
>
> <snip>
> auto_prepend_file string
> Specifies the name of a file that is automatically parsed before the
> main file. The file is included as if it was called with the include()
> function, so include_path is used.
>
> The special value none disables auto-prepending.
> </snip>
>
>
> --
> Franklin van Velthuizen fv
ebiris.se +46-(0)70-6786613
> Ebiris Applications AB http://www.ebiris.se/ +46-(0)19-109910
>
attached mail follows:
Hi all,
I am filling out a form <text area>, and submitting it to the next page which just prints what I submitted, but it doesnt print any returns, i used when i filled out the previous <text area>
I found on php.net there is a ereg_replace funtion and a trim function but I am unsure if either one will work and im not sure how to use them.
Thanks, nate
attached mail follows:
On Mon, 3 Sep 2001 nate
1feehosting.com wrote:
> I am filling out a form <text area>, and submitting it to the next > page which just prints what I submitted, but it doesnt print any > returns, i used when i filled out the previous <text area>
Try using nl2br() in the output script (page).
~Chris /"\ \ / Pine Ribbon Campaign Microsoft Security Specialist X Against Outlook The moron in Oxymoron. / \ http://www.thebackrow.net
attached mail follows:
nate
1feehosting.com wrote:
> I am filling out a form <text area>, and submitting it to the next page which just prints what I submitted, but it doesnt print any returns, i used when i filled out the previous <text area> > > I found on php.net there is a ereg_replace funtion and a trim function but I am unsure if either one will work and im not sure how to use them.
Try: http://www.php.net/manual/en/function.nl2br.php
--
_______ ___ _ ____ _____
Chris Hobbs / ____\ \ / / | | |/ ___\| __ \
Head Geek | (___ \ \ / /| | | | (___ | | | |
WebMaster \___ \ \ \/ / | | | |\___ \| | | |
PostMaster ____) | \ / | |__| |____) | |__| |
\____/ \/ \____/ \____/|_____/
http://www.silvervalley.k12.ca.us
chobbs
silvervalley.k12.ca.us
attached mail follows:
Hi all, Trying PHP for the first time. Snached the authentication code from the docs and put it in phpauth.php. When I surf to it, it just asks for my user and password again and again If I hit Cancel, it prints the little message just fine. Here's the code in case I'm the only one to RTFM:
------- Example 17-1. HTTP Authentication example
<?php if(!isset($PHP_AUTH_USER)) { header("WWW-Authenticate: Basic realm=\"My Realm\""); header("HTTP/1.0 401 Unauthorized"); echo "Text to send if user hits Cancel button\n"; exit; } else { echo "<p>Hello $PHP_AUTH_USER.</p>"; echo "<p>You entered $PHP_AUTH_PW as your password.</p>"; } ?> --------------------- I have php 4.0.6 installed as a module(DSO) in apache 1.3.20 and everything else I've tried seems to work.
Any Ideas? Anybody know if this is supposed to work? Should I stick with AuthPG and forget PHP authentication? BTW I don't have AuthType set in .htaccess or httpd.conf.
Lynn Getting old isn't hard, all you got to do is live long enough......or fast enough.
attached mail follows:
hi!
i'm trying to install php4 and apache 1.3.20. so, installing apache works and installing php4 works, too. but when i'm now trying to build a new apache with the php4 module it gives up: ./config.status --activate-module=src/modules/php4/libphp4.a
make ---> leaving directory 'usr/local/etc/apache_1.3.20/src' ... leaving directory 'usr/local/etc/apache_1.3.20/' [build] Error 2
does anybody has an idea????? merci beaucoup and thankx so much!
cheers, christian
attached mail follows:
I tried that one, and it didn't work...
Nicolas
> > <VirtualHost foo> > php_admin_value disable_functions strlen > </VirtualHost> > > On Fri, 31 Aug 2001, Nicolas Ross wrote: > > > I am searching a way of disabling certain functions in a particular Virtual > > Host. > > > > I search through the archive of this list and I found a begening of a > > solution. I can disable functions in php.ini, but I can't use them in vhost > > I want to. If I don't disable functions in php.ini, I cannot disable > > functions through httpd.conf with php_value or php_admin_value... > > > > Does some one have an Idea ? > > > > Nicolas Ross > > > > > > > >
attached mail follows:
Hi all,
I am having a problem with a PHP script, in which I am using a self-written OLE object to provide data to the script. I have two other OLE DLLs that I also use in PHP scripts which work fine. I wrote all of the DLLs in Borland Delphi, btw. (I am running PHP 4.0.6 and Apache 1.3.20 on Windows 2000 Pro)
For some reason, whenever I try to access one of the Char/String variables (in only this DLL) from PHP, it returns a warning: "Error in php_OLECHAR_to_char()". I have been trying to fix this problem for some time now, and am having no luck finding a source. I have had this message before, but it was easily fixed by setting a default value for the strings (in the DLLs) to a single ascii-32, so that the return would not be blank.
The only difference between this object and the others is that the low-level delphi code uses pointer variables to set up the data access, whereas the others do not. I have used this object in other non-PHP projects (and tests :) and it works as it is intended to. Also, all other types of variables in the object are intact.
Can anyone suggest a source of this problem? On what conditions does php_OLECHAR_to_char() error out?
Thanks in advance, Joshua Ecklund - mProwler
attached mail follows:
My ISP has a limit on my site of 10,000MB of data transfer per month.
4 days into september and I'm already at 2,500MB. It would seem they're including requests by their own PHP server.
I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB.
Should it? Am I in the right in thinking that it shouldn't?
regards,
- seb frost
--- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.274 / Virus Database: 144 - Release Date: 23/08/2001
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]