Re: [PHP] Include() problems IGNORE PARENT
Never mind. Apparently I can't tell the difference between a capital and a lowercase B. time to crash methinks. leo On February 13, 2003 11:59 pm, Leo Spalteholz wrote: > I just ran into a somewhat strange problem with an include failing. > I have the following in my script: > include(dirname(__FILE__)."/LNScreens/LNScrMain.php"); > include(dirname(__FILE__)."/LNDataBase/LNDataBase.php"); > > The first file is included just fine, but the LNDataBase file fails > (Failed opening for inclusion). My directory structure is: > > /LNDataBase > LNDataBase.php > /LNScreens > LNScrMain.php > index.php > > The file exists and it seems to be the exact same syntax as what I > used to include the other file. What else could possibly be wrong? > > Thanks for any help, > Leo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] image creation error
i've already installed gd but still recieving Fatal error: Call to undefined function: imagecreatefromjpeg() . - Original Message - From: "Michael P. Carel" <[EMAIL PROTECTED]> To: "Kevin Waterson" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 3:45 PM Subject: Re: [PHP] image creation error > i've recompile my php4.3 in redhat with > ./configure --with-mysql --with-apache=../apache_1.3.x --with-gd --with-zlib > > and i receive this error upon make > > make: *** Warning: File `libphp4.la' has modification time in the future > (2003-0 > 2-14 16:04:12 > 2003-02-14 15:47:10) > make: Nothing to be done for `all'. > make: *** Warning: Clock skew detected. Your build may be incomplete. > > > What should be the problem? > > > - Original Message - > From: "Kevin Waterson" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, February 14, 2003 3:07 PM > Subject: Re: [PHP] image creation error > > > > This one time, at band camp, > > "Michael P. Carel" <[EMAIL PROTECTED]> wrote: > > > > > Hi to all, > > > > > > Im receiving a Fatal error: Call to undefined function: > > > imagecreatefromjpeg() . > > > > You need to install gd > > > > in your config line add > > > > --with-gd > > > > Kevin > > > > -- > > __ > > (_ \ > > _) ) > > | / / _ ) / _ | / ___) / _ ) > > | | ( (/ / ( ( | |( (___ ( (/ / > > |_| \) \_||_| \) \) > > Kevin Waterson > > Port Macquarie, Australia > > > > -- > > 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 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
php-general Digest 14 Feb 2003 08:12:29 -0000 Issue 1882
php-general Digest 14 Feb 2003 08:12:29 - Issue 1882 Topics (messages 135511 through 135562): Re: problems with cookies and PHP 135511 by: Rick Emery 135514 by: Bryan Lipscy sososoosos 135512 by: Luis A 135513 by: Leif K-Brooks 135516 by: Tim Thorburn What's the scoop on PHP 5? 135515 by: Leif K-Brooks 135528 by: Danny Shepherd By reference 135517 by: Chris Boget 135523 by: Chris Wesley Re: GD and 4.3 135518 by: Joseph Bannon 135547 by: Jason Wong Enable CLI on Mac OS X 135519 by: Dan Tappin Add a record and recover it's ID in one operation 135520 by: Daniel Page 135521 by: Leif K-Brooks 135525 by: Daniel Page 135529 by: Chris Kay 135530 by: Chris Shiflett Simple PHP script 135522 by: Poon, Kelvin (Infomart) 135524 by: John Nichel 135526 by: Poon, Kelvin (Infomart) 135527 by: janet.valade.com Use GnuPG with PHP? 135531 by: MIKE YRABEDRA Sorting multidimensional arrays 135532 by: Sean Brown 135540 by: Chris Wesley Templates 135533 by: Darren Young 135534 by: Justin French 135535 by: Justin French 135537 by: Darren Young 135539 by: Justin French 135545 by: php.errorcode.com Calculating U.S. Taxes (regional) 135536 by: [-^-!-%- Error compiling php 135538 by: Adam Plocher Reading File Name 135541 by: PR 135546 by: Jason Wong I need examples of WRITING to XML wth PHP 135542 by: Daevid Vincent 135551 by: Manuel Lemos programming question 135543 by: Thomas Moore 135550 by: olinux Re: Login system using PHP/MySql 135544 by: YC Nyon 135549 by: olinux Re: crypt() 135548 by: Jason Wong 135558 by: SLanger.spirit21.de encrypt passwords on URL 135552 by: Petre Agenbag upgrading from 4.1.2 to 4.3.0 - can anyone point me to a list of MUST DO'S 135553 by: Brian Tully Re: Process array after form submission problem 135554 by: Steve Jackson image creation error 13 by: Michael P. Carel 135556 by: Kevin Waterson 135557 by: Michael P. Carel 135562 by: Michael P. Carel Re: PHP-based SMS solution 135559 by: Mika Tuupola Include() problems 135560 by: Leo Spalteholz Re: Include() problems IGNORE PARENT 135561 by: Leo Spalteholz Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- --- Begin Message --- In your code, it appears you are attempting to determine the value of the cookie immediately upon setting. The value of the cookie is NOT available at this point; a new page must be opened. Why are you setting time to 0? If you want cookie to disappear at end of the session, use NULL. Are you certain that $_COOKIE[] is available to you? have you tried $HTTP_COOKIE_VARS[]? Your code ends with two braces ( } ); why? It should end with a single brace. - Original Message - From: "Joshua Chapman" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, February 13, 2003 12:57 PM Subject: [PHP] problems with cookies and PHP This is driving me nuts... it won't set or reset the cookie no errors no nothing... I've learned quite a bit about cookies and PHP thus far but something important must still be eluding me. I've read the manual entry on it, is there any other tutorial out there that's better? what am I doing wrong? --- End Message --- --- Begin Message --- I have been playing with this at home. Perhaps this makes it a bit easier. boolean setcookie ( string name [, string value [, int expire [, string path [, string domain [, int secure]) boolean setcookie (name, value, expire, path, domain, secure) Fwiw, a solution from another project: --- End Message --- --- Begin Message --- HI EVERY BODY=20 I HAVE THE FOLLOWING TROUBLE INSTALING PHP GUYS I NEED THE INFO HOW CAN I INATALL PHP MODULE IN WINDOWS USING = APACHE VERSION apache_1.3.26-win32-x86-no_src.msi I BEEN TRIED THE VERSIONapache_1.3.26-win32-x86-no_src.exe BUT HE = SEND IT TO ME A ERROR ON THE SYSTEM AND HE DOES NOT WORKING WHAT DU U SUBGEST ?? --- End Message --- --- Begin Message --- Do you know how many internet etiquette rules you're breaking by typing in all caps like that? Well you're breaking one. Don't type in all caps. --Strong Bad Anyway, download the .zip from http://www.php.net/downloads.php and read the installation instructions included with it. Luis A wrote: HI EVERY BODY=20 I HAVE THE FOLLOWING TROUBLE INSTALING PHP GUYS I NEED THE INFO HOW CAN I INATALL PHP MODULE IN WINDOWS USING = APACHE VERSION apache_1.3.26-win32-x8
[PHP] What's the proper way to open a file? File access permissions?
Hello all! How do I ensure that all file access permissions are allowed? What is the proper way to do it? - I tried to 'fopen' an existing text file but got "Permission denied" error. - I tried different parameters, same error - I tried to use 'chmode', same thing Same thing with different servers so I'm obviously doing something wrong. Everything else works fine but the writing doesn't. The (writing)code is very basic (the textfile.txt exists before this): $filename = "textfile.txt"; $somecontent = "the text to add\n"; $handle = fopen($filename, 'a+w'); fwrite($handle, $somecontent); fclose($handle); ?> So, what should I do to get it work? Yours, Paul Dunkel -- [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] php4ts.dll
__ > Od: Gabor Hojtsy <[EMAIL PROTECTED]> > Komu: Kristyna Tuckova <[EMAIL PROTECTED]> > CC: [EMAIL PROTECTED] > Datum: Thu, 13 Feb 2003 23:24:18 +0100 > Předmět: Re: php4ts.dll > > Please direct such questions to [EMAIL PROTECTED] > > Goba [one [EMAIL PROTECTED]] > > Kristyna Tuckova wrote: > > Hi. > > > > I use php and apache and now I have a problem. If I try to open some > > file with php script, it says to me: > > > > File php4ts.dll is conected to not existig export OLEAUT32.DLL:77 > > > > I have tryed to install everything once more, but it didn't help. > > Could you be so pleased and help me? > > > > thank you very much. > > > > Kristyna > > > > > > PŘÍLOHA O DANÍCH! Interaktivní on-line formuláře pro daňová přiznání a tiskopisy ke stažení, adresář finančních úřadů na http://finance.centrum.cz/dane2 > > > > > > > > > > Poslouchejte Radio Impuls a vyhrajte víkendy pro dva v evropských metropolích. Více na Radiu Impuls a http://www.netimpuls.cz! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] How do I set the timezone on redhat via PHP? Ie. How to convert GMT to symbolic link?
Given that I have a GMT offset via the select box below, how the hell do I turn that into a symbolic link to one of these files? How do I know which file to link too?!!! UGH. This is such a stupid way to set the timezone, why didn't RedHat just have a file with the offset in it? Something like "echo -0800GMT > /etc/timezone" would have been sufficient doncha think? PHP's date("O") function = "-0800". [dae51d=pts/0]12:50am@daevid:{/etc}> ll /etc/localtime lrwxrwxrwx1 root root 39 Dec 13 11:26 /etc/localtime -> /usr/share/zoneinfo/America/Los_Angeles [dae51d=pts/0]12:50am@daevid:{/etc}> ls /usr/share/zoneinfo/ Africa Australia Cuba Etc GMT0 Iceland Japan MST Poland right UCTzone.tab America Brazil EET Europe GMT-0 Indian Kwajalein MST7MDT PortugalROCUniversal Zulu Antarctica Canada EgyptFactory GMT+0 Iran Libya Navajo posix ROKUS Arctic CETEire GB Greenwich iso3166.tab MET NZ posixrules Singapore UTC AsiaChile EST GB-Eire Hongkong Israel Mexico NZ-CHAT PRC SystemVWET AtlanticCST6CDTEST5EDT GMT HSTJamaica Mideast Pacific PST8PDT Turkey W-SU And since I couldn't figure out a graceful way to do this programatically, I just typed them all out. Time Zone ";?> >GMT -12 Hours >GMT -11.5 Hours >GMT -11 Hours >GMT -10.5 Hours >GMT -10 Hours >GMT -9.5 Hours >GMT -9 Hours >GMT -8.5 Hours >GMT -8 Hours >GMT -7.5 Hours >GMT -7 Hours >GMT -6.5 Hours >GMT -6 Hours >GMT -5.5 Hours >GMT -5 Hours >GMT -4.5 Hours >GMT -4 Hours >GMT -3.5 Hours >GMT -3 Hours >GMT -2.5 Hours >GMT -2 Hours >GMT -1.5 Hours >GMT -1 Hours >GMT 0 Hours >GMT +0.5 Hours >GMT +1 Hours >GMT +1.5 Hours >GMT +2 Hours >GMT +2.5 Hours >GMT +3 Hours >GMT +3.5 Hours >GMT +4 Hours >GMT +4.5 Hours >GMT +5 Hours >GMT +5.5 Hours >GMT +6 Hours >GMT +6.5 Hours >GMT +7 Hours >GMT +7.5 Hours >GMT +8 Hours >GMT +8.5 Hours >GMT +9 Hours >GMT +9.5 Hours >GMT +10 Hours >GMT +10.5 Hours >GMT +11 Hours >GMT +11.5 Hours >GMT +12 Hours -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Templates
"Darren Young" <[EMAIL PROTECTED]> wrote in message 000e01c2d3b3$a88217e0$[EMAIL PROTECTED]">news:000e01c2d3b3$a88217e0$[EMAIL PROTECTED]... > > I'm looking around for some options on using templates with PHP. I've > used several Perl solutions in the past, but never tried it in PHP. > Digging on the web yields several options so I'd love some thoughts or > comments. The real driver is that the basic site design could change > over time and I'd like to have the basic HTML in the templates, and the > real logic in the PHP code. Hi, take a look at the TemplateTamer (link is in the sig). Aside from beeing just template engine, it commes with complete environment that eases many chores while programming with templates. It is very easy to see the structure of your templates, and to use them. Also TT offers very strong separation of templates and logic, and does not suffer from code creeping back into the templates. rush -- http://www.templatetamer.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] programming question
Thomas -- ...and then Thomas Moore said... % ... % showMasterCategories($year, $model_id, $syear_model_id, $keyword, $make_id, % $display_mode, $catid) % { % $category_array2[$i] = getParent($category_id, $year_model_id, $i, $catid); % } % % % function getGrandParent($cat_id, $year_model_id, $x) { ... Are you actually using getGrandParent, or where is your getParent code? If the former, why are you passing $catid to getGrandParent if it's not expecting it? Let's make sure we're working with the right code before we try to debug ;-) HTH & HAND :-D -- David T-G * There is too much animal courage in (play) [EMAIL PROTECTED] * society and not sufficient moral courage. (work) [EMAIL PROTECTED] -- Mary Baker Eddy, "Science and Health" http://justpickone.org/davidtg/ Shpx gur Pbzzhavpngvbaf Qrprapl Npg! msg96920/pgp0.pgp Description: PGP signature
Re: [PHP] Use GnuPG with PHP?
Mike -- ...and then MIKE YRABEDRA said... % % I want to be able to encrypt a block of text using a passphrase. Then when I % get the email, I just need to unlock it using that passphrase (no keys...i % think). Then it has nothing to do with GnuPG. Not only did you hijack this thread, your subject isn't even meaningful! % % Can anyone tell me how to do this in PHP code? Let's first figure out what you actually want to do :-) I would say that the easiest way to encrypt and decrypt is certainly with gpg, though others might not. I took a quick surf through the manual and looked at the mcrypt functions and they will let you enter a crypt phrase and transform the data; maybe that's what you want. % % TIA HTH & HAND :-D -- David T-G * There is too much animal courage in (play) [EMAIL PROTECTED] * society and not sufficient moral courage. (work) [EMAIL PROTECTED] -- Mary Baker Eddy, "Science and Health" http://justpickone.org/davidtg/ Shpx gur Pbzzhavpngvbaf Qrprapl Npg! msg96921/pgp0.pgp Description: PGP signature
[PHP] Threads in PHP? URL call from PHp?
Hiya, Perhaps I don't mean threads! Basically I have a PHP script which is in a website, and runs when a certain input is recieved and it is quite complicated, and may take quite a time to finish, as it will be sending quite a few emails. The emails do not have to be sent straight away, and the emails are all customised with date from the database. What I could do I suppose is to call set_time_limit(0) to stop the script timing out, but I don't want to have the user waiting for the script to finish before he/she sees the next page. What are the options? I was thinking I could: 1- Run another script using the command line version, system call. But it is going live on Linux, but tested on Windows. And don't want to have to alter the code for the live version. Think you have to call PHP differently on the two platforms. 2- Do some sort of URL call from the PHP code? Is this possible. I mean like call a script, and pass arguements in the URL. And just ignore it, it can take as long as it wants, sort of do it in a seperate thread. 3- Somehow ask for some specific PHP code to work in a seperate thread. Is this possible? Any other ideas? Which is the best way? What is the PHP way! If I was doing something like this in Java, probably set a class running in another thread. Many thanks, Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] basic question
What is the most secure way to access a mysql db with a php script? And could someone provide an example? What are the best password practices for the script to connect to the mysql db? Also, how should I set the directory permissions for the html pages with php scripts? _ Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] class problem
Hello, I have a problem. Here is code: p1 = $p1; $this->p2 = $p2; } function getP1() { return $this->p1; } function setP1($p1) { $this->p1 = $p1; } function getP2() { return $this->p2; } function setP2($p2) { $this->p2 = $p2; } function toString() { return "p1=" . $this->p1 . "; p2=" . $this->p2; } } class Obj2 { var $p1; var $p2; var $obj1; function Obj2 () { } function init($p1, $p2, $obj1) { $this->p1 = $p1; $this->p2 = $p2; $this->obj1 = $obj1; } function getP1() { return $this->p1; } function setP1($p1) { $this->p1 = $p1; } function getP2() { return $this->p2; } function setP2($p2) { $this->p2 = $p2; } function getObj1() { return $this->obj1; } function setObj1($obj1) { $this->obj1 = $obj1; } function toString() { return "p1=" . $this->p1 . "; p2=" . $this->p2 . "; obj1=" . $this->obj1->toString(); } } $objs[] = new Obj1("jurek", "mizgiert"); $objs[] = new Obj1("marta", "wegner"); $objs[] = new Obj1("tomasz", "zdybicki"); $objs[] = new Obj1("artur", "milczarek"); $obj2 = new Obj2(); $tmp = Array(); for ($i = 0; $i < count($objs); $i++) { $obj2->init($i, $i, $objs[$i]); $tmp[] = $obj2; print ($i+1) . ". " . $obj2->toString() . " | "; $o = $tmp[$i]; $o2 = $o->getObj1(); print ($i+1) . ". p1=" . $o->getP1() . "; p2=" . $o->getP2() . "; obj1=p1=" . $o2->getP1() . "; p2=" . $o2->getP2() . ""; } print ""; print count($tmp); print ""; for ($i = 0; $i < count($tmp); $i++) { $o = $tmp[$i]; $o2 = $o->getObj1(); print ($i+1) . ". p1=" . $o->getP1() . "; p2=" . $o->getP2() . "; obj1=p1=" . $o2->getP1() . "; p2=" . $o2->getP2() . ""; } ?> Class Obj1 have 2 fields with set-get methods and constructor which inits fields. Method toString() return string representation of fields... Second class Obj2 have 3 fields from which the obj1 will be type Obj1. Method init inits fields of class. Method toString make the same action like in Obj1 Look at code near the classes. Run this give this effect: 1. p1=0; p2=0; obj1=p1=jurek; p2=mizgiert | 1. p1=0; p2=0; obj1=p1=jurek; p2=mizgiert 2. p1=1; p2=1; obj1=p1=marta; p2=wegner | 2. p1=1; p2=1; obj1=p1=marta; p2=wegner 3. p1=2; p2=2; obj1=p1=tomasz; p2=zdybicki | 3. p1=2; p2=2; obj1=p1=tomasz; p2=zdybicki 4. p1=3; p2=3; obj1=p1=artur; p2=milczarek | 4. p1=3; p2=3; obj1=p1=artur; p2=milczarek 4 1. p1=0; p2=0; obj1=p1=jurek; p2=mizgiert 2. p1=1; p2=1; obj1=p1=artur; p2=milczarek 3. p1=2; p2=2; obj1=p1=artur; p2=milczarek 4. p1=3; p2=3; obj1=p1=artur; p2=milczarek This is wrong result because effect before the myst be the same after . When I change method toString() in class Obj2 to return ""; it will be ok (look below). What is going on? Who knows? 1. | 1. p1=0; p2=0; obj1=p1=jurek; p2=mizgiert 2. | 2. p1=1; p2=1; obj1=p1=marta; p2=wegner 3. | 3. p1=2; p2=2; obj1=p1=tomasz; p2=zdybicki 4. | 4. p1=3; p2=3; obj1=p1=artur; p2=milczarek 4 1. p1=0; p2=0; obj1=p1=jurek; p2=mizgiert 2. p1=1; p2=1; obj1=p1=marta; p2=wegner 3. p1=2; p2=2; obj1=p1=tomasz; p2=zdybicki 4. p1=3; p2=3; obj1=p1=artur; p2=milczarek -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Anyway to interface to myob
I need a way to interface php with myob, is it possible? -- --- JJ Harrison [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] geek fishing stuff
My guiding season begins in April. Anybody out there know where I can purchase a nice mysql dolphin t-shirt? Thank you. TR -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] [Fwd: Delivery Status Notification (Failure)]
Could one of the admins of this list take this email address off? Everytime I send an email to the list, I get one of these. Thanks. Original Message Subject: Delivery Status Notification (Failure) Date: Fri, 14 Feb 2003 08:01:31 +ACs-0100 From: postmaster+AEA-belair.nl To: jnichel+AEA-by-tor.com This is an automatically generated Delivery Status Notification. Delivery to the following recipients failed. l.vanderwilk+AEA-belair.nl Reporting-MTA: dns;mbla01.belair.nl Received-From-MTA: dns;mbla01.belair.nl Arrival-Date: Fri, 14 Feb 2003 08:01:30 +0100 Final-Recipient: rfc822;[EMAIL PROTECTED] Action: failed Status: 5.1.1 --- Begin Message --- Sigh if ( $_POST['submit1'] ) { echo ( "Hello $_POST['vname']" ); } http://www.php.net/manual/en/language.variables.scope.php http://www.php.net/manual/en/language.variables.external.php Poon, Kelvin (Infomart) wrote: Hi, I am new to PHP and had just written a simple php script to get things started. I have the following code: Input yourname So this page is suppose to display a input box and a submit button and once you enter ur name and press the button, it should show Hello [ur name] and the input box at the bottom of it and the button below and the process continue. I tried running it and inputted some text and pressed the button, and the Hello [ur name] didn't show up, it just display an input box and the submit button. Can someone please help me? Thanks a lot Kelvin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php --- End Message --- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] XML
Hi all, I am just learning about XML and I was just wondering how mcuh you guys use it. Also what kind of things do you use it for? Jono __ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [Fwd: Delivery Status Notification (Failure)]
me too... John Nichel wrote: Could one of the admins of this list take this email address off? Everytime I send an email to the list, I get one of these. Thanks. Original Message Subject: Delivery Status Notification (Failure) Date: Fri, 14 Feb 2003 08:01:31 +0100 From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] This is an automatically generated Delivery Status Notification. Delivery to the following recipients failed. [EMAIL PROTECTED] Reporting-MTA: dns;mbla01.belair.nl Received-From-MTA: dns;mbla01.belair.nl Arrival-Date: Fri, 14 Feb 2003 08:01:30 ? Final-Recipient: rfc822;[EMAIL PROTECTED] Action: failed Status: 5.1.1 Subject: Re: [PHP] Simple PHP script From: John Nichel <[EMAIL PROTECTED]> Date: Thu, 13 Feb 2003 15:13:25 -0600 To: "Poon, Kelvin (Infomart)" <[EMAIL PROTECTED]> Sigh if ( $_POST['submit1'] ) { echo ( "Hello $_POST['vname']" ); } http://www.php.net/manual/en/language.variables.scope.php http://www.php.net/manual/en/language.variables.external.php Poon, Kelvin (Infomart) wrote: Hi, I am new to PHP and had just written a simple php script to get things started. I have the following code: if($submit1) { echo "hello $vname"; } else { ?> Input yourname } ?> So this page is suppose to display a input box and a submit button and once you enter ur name and press the button, it should show Hello [ur name] and the input box at the bottom of it and the button below and the process continue. I tried running it and inputted some text and pressed the button, and the Hello [ur name] didn't show up, it just display an input box and the submit button. Can someone please help me? Thanks a lot Kelvin -- Lucas Lain [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Problems sending mail
Hi all, Anyone having trouble mailing this list. I can send mail within Yahoo mail but not from Evolution it seems. I wondered if the list is being tempremental or whether it is a local problem for me. Jono __ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Keeping site metrics
Can someone direct me to a tutorial or provide insight on how to track site vistors usage. This would include Number of visits boken down by page Average time spent per visitor Total page views and Unique visitors. Thanks __ Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Keeping site metrics
http://www.devshed.com/Server_Side/PHP/Logging/page1.html http://www.google.com/search?hl=en&lr=&ie=UTF-8&oe=UTF-8&q=php+logging olinux --- Daniel Guerrier <[EMAIL PROTECTED]> wrote: > Can someone direct me to a tutorial or provide > insight > on how to track site vistors usage. > This would include > > Number of visits boken down by page > Average time spent per visitor > Total page views and Unique visitors. > > Thanks > > __ > Do you Yahoo!? > Yahoo! Shopping - Send Flowers for Valentine's Day > http://shopping.yahoo.com > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > __ Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php4ts.dll
Read this faqt: The PHP4TS.DLL file is linked to missing export OLEAUT32.DLL:77 - Please help!!! --- http://www.faqts.com/knowledge_base/view.phtml/aid/15670/fid/30 If you happen to be using Win95, don't, because PHP does not support Win95 as of PHP 4.3.0. Regards, Philip p.s. google.com is your friend. On Fri, 14 Feb 2003, Kristyna Tuckova wrote: > > __ > > Od: Gabor Hojtsy <[EMAIL PROTECTED]> > > Komu: Kristyna Tuckova <[EMAIL PROTECTED]> > > CC: [EMAIL PROTECTED] > > Datum: Thu, 13 Feb 2003 23:24:18 +0100 > > Pøedmìt: Re: php4ts.dll > > > > Please direct such questions to [EMAIL PROTECTED] > > > > Goba [one [EMAIL PROTECTED]] > > > > Kristyna Tuckova wrote: > > > Hi. > > > > > > I use php and apache and now I have a problem. If I try to open > some > > > file with php script, it says to me: > > > > > > File php4ts.dll is conected to not existig export OLEAUT32.DLL:77 > > > > > > I have tryed to install everything once more, but it didn't help. > > > Could you be so pleased and help me? > > > > > > thank you very much. > > > > > > Kristyna > > > > > > > > > PØÍLOHA O DANÍCH! Interaktivní on-line formuláøe pro daòová > pøiznání a tiskopisy ke sta¾ení, adresáø finanèních úøadù na > http://finance.centrum.cz/dane2 > > > > > > > > > > > > > > > > > > > > Poslouchejte Radio Impuls a vyhrajte víkendy pro dva v evropských > metropolích. Více na Radiu Impuls a http://www.netimpuls.cz! > > > > > -- > 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
[PHP] snmp problems
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello, Suse 8.0, ucdsnmp-4.2.3-145, tried both php-4.1.2 and 4.3.0, compiled from source, snmp support enabled. bash# snmpget 1.2.3.4 "communitystring" .1.3.6.1.2.1.2.2.1.1.2 interfaces.ifTable.ifEntry.ifIndex.2 = 2 But if I try the following lines: $a=snmpwalkoid("1.2.3.4", "communitystring", ".1.3.6.1.2.1.2.2.1.1.2"); print_r ($a) I get only Array ( ) Does anyone else experience the same problem? Or is there some way to find out if the problem is caused by: - - suse - - ucd - - php - - me being ignorant ? Thank you all. -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.1 (GNU/Linux) iD8DBQE+TQ4AlDG6Z61nQGIRAnkFAKCjkTEGx+rMXV3vUc7NySgZm0l7/gCgsmgG LiTy00n62rux9RfdjA4sKgU= =Wa5J -END PGP SIGNATURE- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Login system using PHP/MySql
you could try the phplib libraries (which as well as authentication implement other things such as database abstraction and templates) There is some overhead involved in getting up to speed with phplib but there is a lot of help out there (in the form of articles, email list etc..) I found phplib very, very valuable to get me started on my first php application (principally using it for the authentication) but have since preferred to write my own authentication code. Going it alone with the authentication does, as you allude to below, involve getting a good handle on sessions. To this and other related ends I would thoroughly recommend the 2 books 'Web Database Applications with PHP & MySQL' and 'Programming PHP' (both O'Reilly titles). Of course a lot of info is out here on the web, but these books are particularly well written, comprehensive and very handy sitting there on the desk while you work. Sorry - not the quick fix solution you request but one that'll help in the longer term. David "Yc Nyon" <[EMAIL PROTECTED]> wrote in message 01c2d434$f8be3c80$5340ba66@gis">news:01c2d434$f8be3c80$5340ba66@gis... > Hi, > > I have looked at many examples session-based of login/password system to > protect webpages but can't get it to work. Seems simple but... I have php > and mysql installed in my windows server. > > If any kind soul can point me to a working (easy) setup of this task, i > would be most grateful. > > Nyon > > > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.449 / Virus Database: 251 - Release Date: 27/01/2003 > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] HTML Mail problem
If I send a HTML email using either mail() or pear mail to an email account of someone who is on my email server it does not get delivered right. But if I send a HTML email to an external email address it is fine. It also works fine with plain text email, only if you send a HTML format email. I have even setup pear mail not to use the mail function but link right to qmail's bin folder. I can also send HTML between users in HTML using Outlook fine, only if PHP sends do I have problem. I am using PHP 4.3.0 and qmail as my email server. Has anyone any idea of were to start looking for why this is happening. Again this only happen if it is a HTML format email and it is to an internal user, thus my email server routes it without leaving the server. Thanks, Mark. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Templates
yeh, I'd totally agree with this. Smarty is fantastic The best one imho in PHP is Smarty. > I'd rank it up there with Template::Toolkit. Take a look: > > http://smarty.php.net/ > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] How does PHP transforms an integer on a string? like "3" onto "three"
Does PHP transforms an integer on a string? Like: "78" onto "seventy eight" How does it do it? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How does PHP transforms an integer on a string? like "3"onto "three"
It transforms 78 into "78". Francisco wrote: Does PHP transforms an integer on a string? Like: "78" onto "seventy eight" How does it do it? -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] text to image
Hello, I am thinking to create php script to dynamically convert a text string to image. My questions are: 1. with a given text string, say "hello, world", is it possible to dynamically convert it to an image? and what php built-in functions can be utilized? 2. if I want to use true-type verdana font, can I just upload the windows font file to the web server (linux) and use php to load the font? Thanks in advance! Alex Shi -- == Cell Phone Batteries at 30-50%+ off retail prices! http://www.pocellular.com == TrafficBuilder Network: http://www.bestadv.net/index.cfm?ref=7029 == -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Images
I am thinking in making some statistics graphics in php ... is there any library that i can use? thanks L.L. -- Lucas Lain [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] text to image
Alex, Easy to do what you want. Check out the "image" functions in the php manual. There are some font limitations, specifically dealing with alternate characters, but you'll find out what works and what doesn't soon enough. Hugh - Original Message - From: "Alex Shi" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 10:16 AM Subject: [PHP] text to image > Hello, > > I am thinking to create php script to dynamically convert a text string to > image. My questions are: > > 1. with a given text string, say "hello, world", is it possible to > dynamically > convert it to an image? and what php built-in functions can be utilized? > 2. if I want to use true-type verdana font, can I just upload the windows > font file to the web server (linux) and use php to load the font? > > Thanks in advance! > > Alex Shi > > > > -- > == > Cell Phone Batteries at 30-50%+ off retail prices! > http://www.pocellular.com > == > TrafficBuilder Network: > http://www.bestadv.net/index.cfm?ref=7029 > == > > > -- > 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
Re: [PHP] image creation error
On Friday 14 February 2003 16:15, Michael P. Carel wrote: > i've already installed gd but still recieving > Fatal error: Call to undefined function: > imagecreatefromjpeg() . You need to configure --with-jpeg-dir. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* "Be *excellent* to each other." -- Bill, or Ted, in Bill and Ted's Excellent Adventure */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Images
On Saturday 15 February 2003 02:35, Lucas Lain wrote: > I am thinking in making some statistics graphics in php ... is there any > library that i can use? > thanks jpgraph -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* Most people deserve each other. -- Shirley */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] geek fishing stuff
On Friday 14 February 2003 22:57, Anthony Ritter wrote: > My guiding season begins in April. > > Anybody out there know where I can purchase a nice mysql dolphin t-shirt? Try the mysql website or the mysql list? -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* short leg on process table */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Images
jpgraph professional license??? other FREE idea??? Jason Wong wrote: On Saturday 15 February 2003 02:35, Lucas Lain wrote: I am thinking in making some statistics graphics in php ... is there any library that i can use? thanks jpgraph -- Lucas Lain [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] What's the proper way to open a file? File access permissions?
On Friday 14 February 2003 16:36, Dunkel wrote: > How do I ensure that all file access permissions are allowed? What is > the proper way to do it? > > - I tried to 'fopen' an existing text file but got "Permission denied" > error. > - I tried different parameters, same error > - I tried to use 'chmode', same thing > > Same thing with different servers so I'm obviously doing something > wrong. Everything else works fine but the writing doesn't. > > The (writing)code is very basic > (the textfile.txt exists before this): > > > $filename = "textfile.txt"; > $somecontent = "the text to add\n"; > $handle = fopen($filename, 'a+w'); > fwrite($handle, $somecontent); > fclose($handle); > > ?> > > So, what should I do to get it work? Try using the /fullpath/to/the/file. If you're in doubt about the permissions try writing to the system temp directory (/tmp for example). -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* Whatever occurs from love is always beyond good and evil. -- Friedrich Nietzsche */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] calculating kilobytes
hi first of all i think this is a great community here :) now to the point... i need a script. it should work on safe mode php so it should be as simple as possible. it should calculate all the file sizes in the directory that it is in and in the subdirectories also (only 1 level subdirectories). it should echo the total size of the uploaded files. then it should take the filesize and substract it from 25 megabytes. that is the limit on this server. then it should echo the result (the maximum number of kilobytes that can still fit on this account). unfortunately i have insuffitient knowlege to do it miself. i just want to thank anyone who can help me. if you want to send it to my email then its [EMAIL PROTECTED] . or you can just write it here. thank you :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] geek fishing stuff
Jason Wong wrote in message: > Try the mysql website or the mysql list? . Yep. I went to the mysql site and they didn't have any promo material like t-shirts, visors, etc. My news server doesn't have any mysql newsgroups. SQL - yes - but not mysql. There was a shop online that had geek stuff...I forget the name. And that dolphin _is_ a nice looking logo. If you know it - please post. Thanks. TR -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] geek fishing stuff
Don't know if they have one, but you could try http://www.thinkgeek.com/ Anthony Ritter wrote: Jason Wong wrote in message: Try the mysql website or the mysql list? . Yep. I went to the mysql site and they didn't have any promo material like t-shirts, visors, etc. My news server doesn't have any mysql newsgroups. SQL - yes - but not mysql. There was a shop online that had geek stuff...I forget the name. And that dolphin _is_ a nice looking logo. If you know it - please post. Thanks. TR -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] calculating kilobytes
On Saturday 15 February 2003 03:17, joe wrote: > now to the point... > i need a script. it should work on safe mode php so it should be as simple > as possible. > it should calculate all the file sizes in the directory that it is in and > in the subdirectories also (only 1 level subdirectories). it should echo > the total size of the uploaded files. > then it should take the filesize and substract it from 25 megabytes. that > is the limit on this server. then it should echo the result (the maximum > number of kilobytes that can still fit on this account). > unfortunately i have insuffitient knowlege to do it miself. > i just want to thank anyone who can help me. Most of the functions that you need to accomplish this can be found in chapters 'Directory functions' & 'Filesystem functions'. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* We gave you an atomic bomb, what do you want, mermaids? -- I. I. Rabi to the Atomic Energy Commission */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] need apostrophe solution
i need to escape all my apostrophes in values submitted to a mySQL database. i know how to do the string replace, but is there a way i can loop thru all the post variables and replace the apostrophes? if so, do i need to refer to my variables like "$_POST[$variable]" instead of simply "$variable" (like i have currently) for it to work? any help would be greatly appreciated... -Doug -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
php-general Digest 14 Feb 2003 20:31:09 -0000 Issue 1883
php-general Digest 14 Feb 2003 20:31:09 - Issue 1883 Topics (messages 135563 through 135599): What's the proper way to open a file? File access permissions? 135563 by: Dunkel 135594 by: Jason Wong php4ts.dll 135564 by: Kristyna Tuckova 135580 by: Philip Olson How do I set the timezone on redhat via PHP? Ie. How to convert GMT to symbolic link? 135565 by: Daevid Vincent Re: Templates 135566 by: rush 135584 by: David Eisenhart Re: programming question 135567 by: David T-G Re: Use GnuPG with PHP? 135568 by: David T-G Threads in PHP? URL call from PHp? 135569 by: Steve Vernon basic question 135570 by: Tyler Durdin class problem 135571 by: Jurek Mizgiert Anyway to interface to myob 135572 by: JJ Harrison geek fishing stuff 135573 by: Anthony Ritter 135592 by: Jason Wong 135596 by: Anthony Ritter 135597 by: John Nichel Re: Delivery Status Notification (Failure)] 135574 by: John Nichel 135576 by: Lucas Lain XML 135575 by: Jono Bacon Problems sending mail 135577 by: Jono Bacon Keeping site metrics 135578 by: Daniel Guerrier 135579 by: olinux snmp problems 135581 by: Razvan Cosma Re: Login system using PHP/MySql 135582 by: David Eisenhart HTML Mail problem 135583 by: Mark McCulligh How does PHP transforms an integer on a string? like "3" onto "three" 135585 by: Francisco 135586 by: Leif K-Brooks text to image 135587 by: Alex Shi 135589 by: Hugh Danaher Images 135588 by: Lucas Lain 135591 by: Jason Wong 135593 by: Lucas Lain Re: image creation error 135590 by: Jason Wong calculating kilobytes 135595 by: joe 135598 by: Jason Wong need apostrophe solution 135599 by: drparker Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- --- Begin Message --- Hello all! How do I ensure that all file access permissions are allowed? What is the proper way to do it? - I tried to 'fopen' an existing text file but got "Permission denied" error. - I tried different parameters, same error - I tried to use 'chmode', same thing Same thing with different servers so I'm obviously doing something wrong. Everything else works fine but the writing doesn't. The (writing)code is very basic (the textfile.txt exists before this): $filename = "textfile.txt"; $somecontent = "the text to add\n"; $handle = fopen($filename, 'a+w'); fwrite($handle, $somecontent); fclose($handle); ?> So, what should I do to get it work? Yours, Paul Dunkel -- [EMAIL PROTECTED] --- End Message --- --- Begin Message --- On Friday 14 February 2003 16:36, Dunkel wrote: > How do I ensure that all file access permissions are allowed? What is > the proper way to do it? > > - I tried to 'fopen' an existing text file but got "Permission denied" > error. > - I tried different parameters, same error > - I tried to use 'chmode', same thing > > Same thing with different servers so I'm obviously doing something > wrong. Everything else works fine but the writing doesn't. > > The (writing)code is very basic > (the textfile.txt exists before this): > > > $filename = "textfile.txt"; > $somecontent = "the text to add\n"; > $handle = fopen($filename, 'a+w'); > fwrite($handle, $somecontent); > fclose($handle); > > ?> > > So, what should I do to get it work? Try using the /fullpath/to/the/file. If you're in doubt about the permissions try writing to the system temp directory (/tmp for example). -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* Whatever occurs from love is always beyond good and evil. -- Friedrich Nietzsche */ --- End Message --- --- Begin Message --- __ > Od: Gabor Hojtsy <[EMAIL PROTECTED]> > Komu: Kristyna Tuckova <[EMAIL PROTECTED]> > CC: [EMAIL PROTECTED] > Datum: Thu, 13 Feb 2003 23:24:18 +0100 > Předmět: Re: php4ts.dll > > Please direct such questions to [EMAIL PROTECTED] > > Goba [one [EMAIL PROTECTED]] > > Kristyna Tuckova wrote: > > Hi. > > > > I use php and apache and now I have a problem. If I try to open some > > file with php script, it says to me: > > > > File php4ts.dll is conected to not existig export OLEAUT32.DLL:77 > > >
Fw: [PHP] calculating kilobytes
Joe, you might try something like this instead of a slow PHP function. I based it off of a user example on the PHP site. This is tested and I use it often for various purposes. I think it may be ideal for you becuase it is extremely fast. Requires Linux though I'm certain there's an equivilant command in Windows. --- $dir="/path/to/home/directory/"; $out = `find $dir -depth -type f`; $files = explode("\n", $out); $numfiles = count($files); for ($i=0; $i<$numfiles; $i++) { $filelist .= $files[$i].""; if (false != ($size = @filesize($files[$i]))); { $totalfilesize += $size; } } echo $numfiles." files"; echo $totalfilesize." kilobytes total"; echo $filelist; Let me know how that works for you. - Kevin - Original Message - From: "joe" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 12:17 PM Subject: [PHP] calculating kilobytes > hi > first of all i think this is a great community here :) > > now to the point... > i need a script. it should work on safe mode php so it should be as simple > as possible. > it should calculate all the file sizes in the directory that it is in and in > the subdirectories also (only 1 level subdirectories). it should echo the > total size of the uploaded files. > then it should take the filesize and substract it from 25 megabytes. that is > the limit on this server. then it should echo the result (the maximum number > of kilobytes that can still fit on this account). > unfortunately i have insuffitient knowlege to do it miself. > i just want to thank anyone who can help me. > if you want to send it to my email then its [EMAIL PROTECTED] . or you can > just write it here. > > thank you :) > > > > -- > 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
[PHP] http://www.act.com---CRM
Has anyone used ACT or tried to integrate it with any other applications? I need some advice, please respond. Thanks, Leonard. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] need apostrophe solution
--- drparker <[EMAIL PROTECTED]> wrote: > i need to escape all my apostrophes in values submitted to a mySQL > database. http://www.php.net/manual/en/function.addslashes.php > is there a way i can loop thru all the post variables and replace the > apostrophes? Read about the magic_quotes setting in your php.ini. Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] text to image
Hi, THanks for your reply. I search the manual and created following script. I got following error msg when ran it: Warning: ImageTtfText: No TTF support in this PHP build in /home/dotkard/www/current_time.php on line 6 Warning: ImageGif: No GIF support in this PHP build in /home/dotkard/www/current_time.php on line 7 I checked the phpinfo but failed to find which variable I should turn on. Alex > Alex, > Easy to do what you want. Check out the "image" functions in the php > manual. There are some font limitations, specifically dealing with > alternate characters, but you'll find out what works and what doesn't soon > enough. > Hugh > > - Original Message - > From: "Alex Shi" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, February 14, 2003 10:16 AM > Subject: [PHP] text to image > > > > Hello, > > > > I am thinking to create php script to dynamically convert a text string to > > image. My questions are: > > > > 1. with a given text string, say "hello, world", is it possible to > > dynamically > > convert it to an image? and what php built-in functions can be utilized? > > 2. if I want to use true-type verdana font, can I just upload the windows > > font file to the web server (linux) and use php to load the font? > > > > Thanks in advance! > > > > Alex Shi > > > > > > > > -- > > == > > Cell Phone Batteries at 30-50%+ off retail prices! > > http://www.pocellular.com > > == > > TrafficBuilder Network: > > http://www.bestadv.net/index.cfm?ref=7029 > > == > > > > > > -- > > 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
[PHP] browser identification problem
I have an ecommerce app (MAS200 eBusiness Manager) that works. I am updating my web site to php frames. Now when I want to connect to the eBusiness Manager server I get this error: Unsupported Browser The browser you are using (PHP/4.2.3) is currently unsupported. Please update your browser to the most current level. This happens regardless of the browser I am using. How can I get this to send the actual browser info, not this php info in its place? -- Chip Wiegand Computer Services Simrad, Inc www.simradusa.com [EMAIL PROTECTED] "There is no reason anyone would want a computer in their home." --Ken Olson, president, chairman and founder of Digital Equipment Corporation, 1977 (Then why do I have 8? Somebody help me!) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] text to image
forgot somethingwhen try following script in another server I got 500 internal server error. Alex again > > I got following error msg when ran it: > > > Warning: ImageTtfText: No TTF support in this PHP build in > /home/dotkard/www/current_time.php on line 6 > > Warning: ImageGif: No GIF support in this PHP build in > /home/dotkard/www/current_time.php on line 7 > > I checked the phpinfo but failed to find which variable I should turn on. > > Alex > > > Alex, > > Easy to do what you want. Check out the "image" functions in the php > > manual. There are some font limitations, specifically dealing with > > alternate characters, but you'll find out what works and what doesn't soon > > enough. > > Hugh > > > > - Original Message - > > From: "Alex Shi" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Friday, February 14, 2003 10:16 AM > > Subject: [PHP] text to image > > > > > > > Hello, > > > > > > I am thinking to create php script to dynamically convert a text string > to > > > image. My questions are: > > > > > > 1. with a given text string, say "hello, world", is it possible to > > > dynamically > > > convert it to an image? and what php built-in functions can be utilized? > > > 2. if I want to use true-type verdana font, can I just upload the > windows > > > font file to the web server (linux) and use php to load the font? > > > > > > Thanks in advance! > > > > > > Alex Shi > > > > > > > > > > > > -- > > > == > > > Cell Phone Batteries at 30-50%+ off retail prices! > > > http://www.pocellular.com > > > == > > > TrafficBuilder Network: > > > http://www.bestadv.net/index.cfm?ref=7029 > > > == > > > > > > > > > -- > > > 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
Re: [PHP] calculating kilobytes
"Jason Wong" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > On Saturday 15 February 2003 03:17, joe wrote: > > > now to the point... > > i need a script. it should work on safe mode php so it should be as simple > > as possible. > > it should calculate all the file sizes in the directory that it is in and > > in the subdirectories also (only 1 level subdirectories). it should echo > > the total size of the uploaded files. > > then it should take the filesize and substract it from 25 megabytes. that > > is the limit on this server. then it should echo the result (the maximum > > number of kilobytes that can still fit on this account). > > unfortunately i have insuffitient knowlege to do it miself. > > i just want to thank anyone who can help me. > > Most of the functions that you need to accomplish this can be found in > chapters 'Directory functions' & 'Filesystem functions'. > > -- > Jason Wong -> Gremlins Associates -> www.gremlins.biz > Open Source Software Systems Integrators > * Web Design & Hosting * Internet & Intranet Applications Development * > -- > Search the list archives before you post > http://marc.theaimsgroup.com/?l=php-general > -- > /* > We gave you an atomic bomb, what do you want, mermaids? > -- I. I. Rabi to the Atomic Energy Commission > */ > i searched and i tried and i failed. most of the functions dont work in safe mode, some didnt do what i wanted (returned the whole drive size instead of one directroy) etc. my head hurts already and i think i am on the verge on nervous breakdown because i have been trying to solve this problem for days so could somebody please drop me a function here? thank you... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] calculating kilobytes
On Fri, 14 Feb 2003, joe wrote: >i searched and i tried and i failed. most of the functions dont work in safe >mode, some didnt do what i wanted (returned the whole drive size instead of >one directroy) etc. >my head hurts already and i think i am on the verge on nervous breakdown >because i have been trying to solve this problem for days so could >somebody please drop me a function here? >thank you... Most people who write code for other people on request are compensated in one form or another. This is a listserv, I doubt anyone here will do your work for you for free. This is place where people get _assistance_ with code they already attempted to write themselves. If you tried and failed already like you say, post your broken code and people will help you figure out your errors. That's pretty much how it works. Also, what you ask may simply not be possible in safe mode, but there's no way to tell since you posted no code. -- Greg Donald http://destiney.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Urgent Help Needed removing \n\r
Hi all, Slight problem, I have about 200 pages of HTML stored in a mysqlDB. I had to manually edit some information on EVERY single page. I used MySQL-Front and edited these pages. All of the tags were correct and I have run into a problem now, that every page I have edited has somehow corrupted most/all of the and tags. so they look like this Now when the page is read it actually prints out "" instead of changing the font or showing the IMAGE. The font I am not so much worried about it is the image that is not showing up and the there are too many pages to go through manually. Can someone help me with a PHP script to go through the db and replace the \n\r ? Thank you, --- -Daniel Negron // \\* / _ __ ___ \Lotus Notes Admin / Developer | | |/ /| _ ) | KB Electronic, Inc. | | ' < | _ \ | 12095 NW 39th Street | |_|\ \|___/ | Coral Springs, FL. 33065 \ \_\ /954.346.4900 x 122 \\ // email: [EMAIL PROTECTED] - http://www.kbelectronics.com --- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] imap_append
I'm unable to append using imap_append. I can access the account without a problem but the append fails. Any ideas? - Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day
Re: [PHP] Urgent Help Needed removing \n\r
At 23:12 14.02.2003, Daniel Negron/KBE said: [snip] >have run into a problem now, that every page I have edited has somehow >corrupted most/all of the and tags. so they look like this > > face="ARIAL, HELVETICA"> > >Now when the page is read it actually prints out "" instead of changing the font or showing the IMAGE. The font I [snip] There must be a different problem since the tag is perfectly valid, even with the spaces/newlines you are showing. If it prints our the HTML tags have a look at the source if they didn't get encoded somehow (like ) -- >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
[PHP] problem with importing fields.
Hi List. I have been working on a problem that is driving me crazy. I have to create a process in which I upload some info to a table. Since I have to add some different information to that table, I decided to do it like this. 1.I create a temporary table copying the structure of my final table. I.E. $query_temp_table="CREATE TEMPORARY TABLE tguias SELECT * FROM guias WHERE 1=0"; $temp_table=mysql_query($query_temp_table, $cosmo_logistic) or die(mysql_error()); I do this in PHP. It works fine It seems. 2. I populate the temporary table. $query_populate_tguias="LOAD DATA LOCAL INFILE 'c:/cosmo/www/upload/guias.txt' INTO TABLE tguias FIELDS TERMINATED BY ',' ENCLOSED BY '\"' (cliente,asesora,extra1,peso,albaran,gerente,tipo,imprimir)"; $populate_tguias=mysql_query($query_populate_tguias, $cosmo_logistic) or die(mysql_error()); 3. Then I pass the information along with some other variables to the real table. mysql_select_db($database_cosmo_logistic, $cosmo_logistic); $query_poblar = "SELECT * FROM tguias"; $poblar = mysql_query($query_poblar, $cosmo_logistic) or die(mysql_error()); $row_poblar= mysql_fetch_assoc($poblar); $totalRows_poblar= mysql_num_rows($poblar); do { mysql_select_db($database_cosmo_logistic, $cosmo_logistic); $query_poblar_guias="INSERT INTO guias (cliente,asesora,peso,albaran,gerente,tipo,imprimir,manifiesto,Status) VALUES (\"".$row_poblar['cliente']."\",\"".$row_poblar['asesora']."\",".$row_poblar ['peso'].",\"".$row_poblar['albaran']."\",\"".$row_poblar['gerente']."\",\"" .$row_poblar['tipo']."\",".$row_poblar['imprimir'].",\"".$manifiesto."\",\"A \")"; $poblar_guias=mysql_query($query_poblar_guias, $cosmo_logistic) or die("No pude insertar el registro ".mysql_error()); } while ($row_poblar=mysql_fetch_assoc($poblar));?> with this source file: "13DAN010","D79406","13DAN010", 1 ,"20430002201","75301;753","PAQUETE","1" "13DAN010","D55816","13DAN010", 1.32 ,"20430003101","100201;1002","PAQUETE","1" it Does not work at all. I wonder if it is because it has a . in the number even as the field receiving it is a decimal(10,2) or if it is because in one of the field I have ;. The thing is that it will import one, and skip one full record each time. But the one it inserts, is correctly inserted with the ; and the decimal point correct. Any idea why it might be pasing one row and adding one? This is driving me crazy. When I do this same procedure on another table with source code like: "D79427","LOPEZ DURAN ELISA","ACUEDUCTO TARRAGONA 59","15","PASEOS DEL BOSQUE","NAUCALPAN","53297"," ","LOPEZ DURAN ELISA","",F,T it Works correctly even as it has two false or true fields. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] browser identification problem
--- [EMAIL PROTECTED] wrote: > I have an ecommerce app (MAS200 eBusiness Manager) that works. I am > updating my web site to php frames. There is no such thing. Perhaps you mean HTML frames? > Now when I want to connect to the eBusiness Manager server I get this error: > > Unsupported Browser > The browser you are using (PHP/4.2.3) is currently unsupported. Please > update your browser to the most current level. So, eBusiness Manager is lame. Thanks for the tip. :-) > This happens regardless of the browser I am using. How can I get this to > send the actual browser info, not this php info in its place? What are you talking about? What is PHP info? The "error" message? Whatever eBusiness Manager is apparently checks what browser you are using and does not operate unless it approves of your choice. This is an indication of pitiful software design, but I don't see how this relates to PHP nor what question you are attempting to ask. Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] function problem
I have a function below which populates a select list, based on the query string and the field name. It then prints a string: function populate_selects($query_name, $db_field, $link, $string) { $result = mysql_query($query_name, $link) or die ("Could not execute query."); while ($columns = mysql_fetch_array($result)) { $column = $columns[$db_field]; global $option_block; $option_block .= "$column\n"; } print $string; } Part of the string that is printed in $string is the $option_block which is in the function. There seems to be some problem with scope here. I made the $option_block variable global but it still won't print. I have tested that the $column field is being populated and it is, so I believe that it must be the $option_block part that isn't working. Does anyone have any suggestions? Peter Gumbrell [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] xslt_process problem
I am trying to figure out the whole XML/XSL thing and am experimenting with the Gentoo docs which have a simple XSL sheet. I downloaded the XML, XSL and DTD, and ran the files through the Sablotron module in php using: $xp = xslt_create(); xslt_set_base($xp, 'file://c:/shared/mywebs/beta/test/'); $result = xslt_process($xp, 'rsync.xml', 'guide.xsl'); echo $result; xslt_free($xp); Everything worked like a champ except for one strange little problem: the XSL stylsheet defines anchors and links in a drop-down menu for each "chapter", sequentially... (as you can see here: http://www.gentoo.org/doc/en/rsync.xml) but in the PHP transformation with the local files, all of the chapter numbers and the numbers in the drop down are "1"! The guide.xsl I am using is online at: http://www.gentoo.org/xsl/guide.xsl and I am using a current rsync.xml from the CVS repository, so it has to be something in the local transformation with PHP. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] function problem
Exactly where does $option_block get put into $string? -Kevin - Original Message - From: "Peter Gumbrell" <[EMAIL PROTECTED]> To: "Php-General" <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 4:11 PM Subject: [PHP] function problem > I have a function below which populates a select list, based on the query > string and the field name. It then prints a string: > > function populate_selects($query_name, $db_field, $link, $string) > { > $result = mysql_query($query_name, $link) or die ("Could not execute > query."); > while ($columns = mysql_fetch_array($result)) > { > $column = $columns[$db_field]; > global $option_block; > $option_block .= " value=\"$column\">$column\n"; > } > print $string; > } > > Part of the string that is printed in $string is the $option_block which is > in the function. There seems to be some problem with scope here. I made the > $option_block variable global but it still won't print. I have tested that > the $column field is being populated and it is, so I believe that it must be > the $option_block part that isn't working. Does anyone have any suggestions? > > Peter Gumbrell > [EMAIL PROTECTED] > > > > -- > 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
[PHP] slideshow/flush
Hello, I'm looking for a way to do something, not sure if someone can help me. I would like to be able to "control", in a way, what a remote user is seeing, almost like running a slideshow. For example, user goes to website, it shows block of text or picture. I login to admin area.I click "next" or something, and it either advances to another page, or to another picture, and so on. I know you can kind of do a live output using flush, but what about forcing it to another page? Any ideas would be great! Thanks, Bryan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] function problem
Here is the string that is being used in this function example. Everything print except the option_block // Vendor string $vendor_string .= << Select the vendor of your choice: $option_block; EOVS; -Original Message- From: Kevin Stone [mailto:[EMAIL PROTECTED]] Sent: Friday, February 14, 2003 6:41 PM To: Php-General Subject: Re: [PHP] function problem Exactly where does $option_block get put into $string? -Kevin - Original Message - From: "Peter Gumbrell" <[EMAIL PROTECTED]> To: "Php-General" <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 4:11 PM Subject: [PHP] function problem > I have a function below which populates a select list, based on the query > string and the field name. It then prints a string: > > function populate_selects($query_name, $db_field, $link, $string) > { > $result = mysql_query($query_name, $link) or die ("Could not execute > query."); > while ($columns = mysql_fetch_array($result)) > { > $column = $columns[$db_field]; > global $option_block; > $option_block .= " value=\"$column\">$column\n"; > } > print $string; > } > > Part of the string that is printed in $string is the $option_block which is > in the function. There seems to be some problem with scope here. I made the > $option_block variable global but it still won't print. I have tested that > the $column field is being populated and it is, so I believe that it must be > the $option_block part that isn't working. Does anyone have any suggestions? > > Peter Gumbrell > [EMAIL PROTECTED] > > > > -- > 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 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: HTML Mail problem
Hello, On 02/14/2003 01:56 PM, Mark McCulligh wrote: If I send a HTML email using either mail() or pear mail to an email account of someone who is on my email server it does not get delivered right. But if I send a HTML email to an external email address it is fine. It also works fine with plain text email, only if you send a HTML format email. I have even setup pear mail not to use the mail function but link right to qmail's bin folder. I can also send HTML between users in HTML using Outlook fine, only if PHP sends do I have problem. I am using PHP 4.3.0 and qmail as my email server. Has anyone any idea of were to start looking for why this is happening. Again this only happen if it is a HTML format email and it is to an internal user, thus my email server routes it without leaving the server. Never send HTML only messages. It is possible that there maybe a spam filter in your server blocking HTML only messages. In the worst case, always try to send a message with a plain text and a HTML alternative parts. You may want to try this class to learn how to do it right. This class also works around some bugs of mail() function. There is also a subclass for delivery with qmail-inject program: http://www.phpclasses.org/mimemessage -- Regards, Manuel Lemos -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] recursion?????
Ok ... here is the sitituation... I am creating a registration form. What I have so far works ... the user registers using this form and the form calls another page that will check the validity of the data (checking for username availability, etc...). If there is an error, display the error and have the user GO BACK AND TRY AGAIN <- This is the problem I want to fix. What I want to do is have the registration form, on submit, check the data validity right then, if there is an error, redisplay the form with an * next to the field that is incorrect. This way the user does not have to go back and try again, it will be there in front of them. Basically, have the form action call itself hince the recursion. Any suggestion/examples? Thanks, -Alex -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] recursion?????
not tested > Basically, have the form action call itself hince the recursion. > Any suggestion/examples? method="POST"> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] function problem
On 2003.02.15 00:11 Peter Gumbrell wrote: [...] $option_block .= " [...] Are you sure it's a scope problem ? You haven't instantiated any $option_block variable when the loop starts, so you're concatenating a string to a bunch of uninitialized memory :) I can't run your script at the moment, so it's just a supposition... Hope it helps, Nicholas -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How does PHP transforms an integer on a string? like "3" onto "three"
Hi, Friday, February 14, 2003, 10:10:55 AM, you wrote: F> Does PHP transforms an integer on a string? F> Like: "78" onto "seventy eight" F> How does it do it? Here is a class I started to do that kind of transform class num_to_text { var $mode; //NUMERIC CURRENCY var $words = array( 0=>array('zero','one','two','three','four','five','six','seven','eight','nine','ten','eleven','twelve','thirteen','fourteen','fifteen','sixteen','seventeen','eighteen','nineteen','twenty'), 1=>array('zero','one','twenty','thirty','fourty','fifty','sixty','seventy','eighty','ninety'), 2=>array('thousand','million') ); var $money = array( 0=>array('Dollar','Dollars'), 1=>array('Cent','Cents') ); function num_class($mode = 'NUMERIC'){ $this->mode = $mode; } function convert($num){ return $this->num($num,1); } function num($num,$key = 0){ static $t; static $call; $res = intval($num/100); $left = $num%100; if($key == 1){ //first non recursive call reset text and thousand/million toggle $t = ""; $call = 0; } else{ // do we need to print thousand as this is a recursive call if($num%1000 > 0)$t = ' '.$this->words[2][$call].' '.$t; $call ^= 1; //toggle call for next recursion } if($left <= 20){ // no need to split it if($left == 0){ // is the whole mess just zero if($res == 0) $t = $this->words[0][$left].$t; } else{ $t = $this->words[0][$left].$t; } } else{ //need to split it up $tens = intval($left/10); $units = $left%10; ($units > 0)? $units = ' '.$this->words[0][$units] : $units = ''; //eg thirty or thirty one $t = $this->words[1][$tens].$units.$t; } if($res < 10){ if($res > 0){ ($left == 0)? $and = '':$and = ' and '; // do we need to print 'and' if($res > 0) $t = $this->words[0][$res]. " hundred".$and.$t; } } else{ $res = $res%10; if($res > 0){ ($left == 0)? $and = '':$and = ' and '; $t = $this->words[0][$res]. " hundred".$and.$t; } else{ if($left > 0)$t = ' and '.$t; } $num = intval($num/1000); $this->num($num); } return $t; } } //usage $n2t = new num_to_text(); for($num = 0;$num < 11;$num++){ echo $num.' '.$n2t->convert($num).''; } -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] redirect
What is the syntax to have php redirect to another web site? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] SQL Query
I have a problem writing a query that can select a Interest for a specific user... There are tvo tables, IList and IIndex... IList contains this : ID SubID Interest Valid Edit Delete 1 0 Datorer 0 Edit Delete 2 1 Spel 0 Edit Delete 3 2 Strategi 0 Edit Delete 4 3 Star Craft 1 Edit Delete 5 3 Star Wars: Gallactic Battelinggrounds 1 Edit Delete 6 2 Shoot-Em-Up 0 Edit Delete 7 6 Half-Life 0 Edit Delete 8 7 Team Fortress 1 Edit Delete 9 7 Counter-Strike 1 And IIndex contains a UserID And InterestID... this query : "SELECT DISTINCTROW InterestsList.ID, InterestsList.SubID, InterestsList.Interest, InterestsList.Valid FROM InterestsList AS II RIGHT JOIN InterestsList ON InterestsList.ID=II.SubID LEFT JOIN InterestsIndex ON InterestsList.ID=InterestsIndex.InterestID AND InterestsIndex.UserID='1'" Selects all rows from IList... even if there Is'nt any instans in IIndex... this thougt is that a User can choose a "Valid" Interest and then the query should select all SubInterests... anyone know how to do that ? // Regards Zydox -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] redirect
> What is the syntax to have php redirect to another web site? http://domain.com/";); ?> -- Greg Donald http://destiney.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] SQL Query
There is a nice piece of software that you should get, http://ems-hitech.com/mymanager/! It's not free, but you can download a trial. (I would get it) It is great for building querys across tables. -Original Message- From: Zydox [mailto:[EMAIL PROTECTED]] Sent: Friday, February 14, 2003 11:18 PM To: [EMAIL PROTECTED] Subject: [PHP] SQL Query I have a problem writing a query that can select a Interest for a specific user... There are tvo tables, IList and IIndex... IList contains this : ID SubID Interest Valid Edit Delete 1 0 Datorer 0 Edit Delete 2 1 Spel 0 Edit Delete 3 2 Strategi 0 Edit Delete 4 3 Star Craft 1 Edit Delete 5 3 Star Wars: Gallactic Battelinggrounds 1 Edit Delete 6 2 Shoot-Em-Up 0 Edit Delete 7 6 Half-Life 0 Edit Delete 8 7 Team Fortress 1 Edit Delete 9 7 Counter-Strike 1 And IIndex contains a UserID And InterestID... this query : "SELECT DISTINCTROW InterestsList.ID, InterestsList.SubID, InterestsList.Interest, InterestsList.Valid FROM InterestsList AS II RIGHT JOIN InterestsList ON InterestsList.ID=II.SubID LEFT JOIN InterestsIndex ON InterestsList.ID=InterestsIndex.InterestID AND InterestsIndex.UserID='1'" Selects all rows from IList... even if there Is'nt any instans in IIndex... this thougt is that a User can choose a "Valid" Interest and then the query should select all SubInterests... anyone know how to do that ? // Regards Zydox -- 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
[PHP] Re: HTML Mail problem
I am sending both text and HTML. The message I get looks like this: boundary="=_ec9ac598a5bbb069fd9a696b254780ef" --=_ec9ac598a5bbb069fd9a696b254780ef Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit TEST MESSAGE WAS HERE --=_ec9ac598a5bbb069fd9a696b254780ef Content-Type: multipart/related; boundary="=_74b5fb5ddc651b2065ec31d700d8d15c" --=_74b5fb5ddc651b2065ec31d700d8d15c Content-Type: text/html; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable ??? etc As you can see both are being displayed including some of the header info. Any idea of how this happened. Mark. "Manuel Lemos" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hello, > > On 02/14/2003 01:56 PM, Mark McCulligh wrote: > > If I send a HTML email using either mail() or pear mail to an email account > > of someone who is on my email server it does not get delivered right. But > > if I send a HTML email to an external email address it is fine. It also > > works fine with plain text email, only if you send a HTML format email. > > > > I have even setup pear mail not to use the mail function but link right to > > qmail's bin folder. > > I can also send HTML between users in HTML using Outlook fine, only if PHP > > sends do I have problem. > > > > I am using PHP 4.3.0 and qmail as my email server. > > > > Has anyone any idea of were to start looking for why this is happening. > > Again this only happen if it is a HTML format email and it is to an internal > > user, thus my email server routes it without leaving the server. > > Never send HTML only messages. It is possible that there maybe a spam > filter in your server blocking HTML only messages. > > In the worst case, always try to send a message with a plain text and a > HTML alternative parts. You may want to try this class to learn how to > do it right. This class also works around some bugs of mail() function. > There is also a subclass for delivery with qmail-inject program: > > http://www.phpclasses.org/mimemessage > > -- > > Regards, > Manuel Lemos > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PHP ODBC Problem
Hi, I've installed PHP 4.3.0 on a Win2k (SP3) IIS 5 server, as we were moving the site to another server (old server was also win2k, php 4.3.0), and ODBC calls no longer function correctly when served from the webserver, however they work perfectly when called from the command line. So http://site/odbc_test.php hanged, while 'php odbc_test.php' in cmd.exe worked perfectly. The ODBC drivers and settings are the same as what was on the previous server. Tracked down the problem to the ODBC_Connect line. If I specified an invalid DSN, e.g. odbc_connect("wrong", "","") or die (); the script would terminate with the correct error message. However, if I specified a valid DSN then PHP would simply hang. No error message. Nothing in the Event Viewier. At first I was using the ISAPI version of PHP for IIS, but then after I saw ODBC work using PHP from the command line, I changed IIS over to use php.exe, but with no success. Any ideas? Oh, and I did end up setting the security permissions for the ODBC database directory to give System & Everyone & IUSER_ full access. Mike C. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] browser identification problem
On Saturday 15 February 2003 05:01, [EMAIL PROTECTED] wrote: > I have an ecommerce app (MAS200 eBusiness Manager) that works. I am > updating my > web site to php frames. Now when I want to connect to the eBusiness > Manager server Presumably you mean connect to that app with some php code? > I get this error: > > Unsupported Browser > The browser you are using (PHP/4.2.3) is currently unsupported. Please > update your browser to the most current level. > This happens regardless of the browser I am using. How can I get this to > send the actual browser info, not this php info in its place? The error comes from some php code accessing that app and has nothing to do with whatever browser you're using. Find out what browsers that app is satisfied with, then set 'user_agent' in php.ini to match that of one of the compatible browsers. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* The Usenet news is out of date */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] text to image
On Saturday 15 February 2003 04:49, Alex Shi wrote: > I got following error msg when ran it: > > > Warning: ImageTtfText: No TTF support in this PHP build in > /home/dotkard/www/current_time.php on line 6 You need to configure/recompile php with TTF support. > Warning: ImageGif: No GIF support in this PHP build in > /home/dotkard/www/current_time.php on line 7 Ditto for GIF support -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* There is no sin but ignorance. -- Christopher Marlowe */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] recursion?????
> What I want to do is have the registration form, on submit, check the > data validity right then, if there is an error, redisplay > the form with an * next to the field that is incorrect. This is the code logic rather than the actual working code: ---Start of PHP Page--- 1. Check for form having been submitted a. If form submitted, check values that have been input i. If valid form input, redirect to another page (or process form data) ii. If not valid form input, set a 'problem flag' for each broken bit b. Do any other form input data manipulation that you need (strip html or whatever) 2. Display form a. Do a check to see if there was a 'problem flag' set for a field - if so display '*' b. If you've done it right, the post data can be reloaded into the form ---End of PHP Page--- That's the basic idea anyway - essentially, you process your form input data at the start of the page and act on what you find. If you want to avoid problems with browser reloads doing another submit then it's probably worth redirecting a successful form submit to a new page. CYA, Dave -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] text to image
Alex, You should either use png or jpg rather than gif. The most common builds of the gd library support those image formats--go to the GD Library site to find out why. The support of ttf fonts should be taken up with your host. When testing whether the code in your image creation file works, use something like say something wonderful here and any error messages will be displayed. Once you've got it down pat, then you can just swap out the line with an image tag, $font="./fonts/verdana.ttf"; // the path to the font is needed if it isn't in the same directory as the script $im = imagecreate (400, 16); $black = imagecolorallocate ($im, 0, 0, 0); $white = imagecolorallocate ($im, 255, 255, 255); imagettftext ($im, 10, 0, 10, 20, $black, $font, date('| l | F | d | Y |')); header ("Content-type: image/png"); //header just before the imagepng call. imagepng ($im); imagedestroy ($im); Hope this helps, Hugh - Original Message - From: "Alex Shi" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, February 14, 2003 1:00 PM Subject: Re: [PHP] text to image > forgot somethingwhen try following script in another server I got > 500 internal server error. > >header ("Content-type: image/gif"); > $im = imagecreate (400, 16); > $black = imagecolorallocate ($im, 0, 0, 0); > $white = imagecolorallocate ($im, 255, 255, 255); > imagettftext ($im, 10, 0, 10, 20, $black, "verdana.ttf", date('| l | F | d > | Y |')); > imagegif ($im); > imagedestroy ($im); > ?> > > Alex again > > > > > I got following error msg when ran it: > > > > > > Warning: ImageTtfText: No TTF support in this PHP build in > > /home/dotkard/www/current_time.php on line 6 > > > > Warning: ImageGif: No GIF support in this PHP build in > > /home/dotkard/www/current_time.php on line 7 > > > > I checked the phpinfo but failed to find which variable I should turn on. > > > > Alex > > > > > Alex, > > > Easy to do what you want. Check out the "image" functions in the php > > > manual. There are some font limitations, specifically dealing with > > > alternate characters, but you'll find out what works and what doesn't > soon > > > enough. > > > Hugh > > > > > > - Original Message - > > > From: "Alex Shi" <[EMAIL PROTECTED]> > > > To: <[EMAIL PROTECTED]> > > > Sent: Friday, February 14, 2003 10:16 AM > > > Subject: [PHP] text to image > > > > > > > > > > Hello, > > > > > > > > I am thinking to create php script to dynamically convert a text > string > > to > > > > image. My questions are: > > > > > > > > 1. with a given text string, say "hello, world", is it possible to > > > > dynamically > > > > convert it to an image? and what php built-in functions can be > utilized? > > > > 2. if I want to use true-type verdana font, can I just upload the > > windows > > > > font file to the web server (linux) and use php to load the font? > > > > > > > > Thanks in advance! > > > > > > > > Alex Shi > > > > > > > > > > > > > > > > -- > > > > == > > > > Cell Phone Batteries at 30-50%+ off retail prices! > > > > http://www.pocellular.com > > > > == > > > > TrafficBuilder Network: > > > > http://www.bestadv.net/index.cfm?ref=7029 > > > > == > > > > > > > > > > > > -- > > > > 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 > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php