[PHP] Re: Pictures and sound in MySQL and access via PHP
Personally I wouldn't store BIG files (like .mp3) into the database. If you insist checkout the mysql LOAD_FILE() Elias "Danny" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > hi, > > I already posted this message but the time on my computer was wrong (26/07 > so i post it again). > > I am new on MySQL and PHP. > I'm making a on-line dictionary. I use PHP and a MySQL Database. > Now I want to add audio-streaming (MP3) and pictures (JPG) to the database > and retrieve it true PHP. Can sombody help me out with a little > example-code? > The database is working well (only text). > > Danny > > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Two version of php in the same system
It have some order for installation of the versions of PHP? First 4.03 Second 4.22 or First install 4.22 Second 4.03 You showed as installing version of php for Windows ? That go work with system Linux and FreeBSD ? Below this configuration of systems Linux and FreeBSD AddType application/x-httpd-php .php .php4 .php3 .phtml AddType application/x-httpd-php-source .phps Thanks for your help again "Breno Cardoso Perucchi" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]... > You think what exist a order for to install versions of php ? > > Thanks for your help > > "Analysis & Solutions" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED]... > > Hi Breno: > > > > On Tue, Aug 06, 2002 at 02:20:19AM -0300, Breno Cardoso Perucchi wrote: > > > Exists some way of to have 2 different versions in the same system ? > > > I am trying to running the version 4.2.2 and 4.0.3 . > > > > Sure. Install them in separate directories. In this example, > > /usr/local/bin/php has two sub directories, ver403 and ver422. > > > > Then, in httpd.conf, put: > > > >Action application/x-httpd-php403 "/php403/php.exe" > >ScriptAlias /php403/ "/usr/local/bin/php/ver403" > > > >Action application/x-httpd-php "/php422/php.exe" > >ScriptAlias /php422/ "/usr/local/bin/php/ver422" > > > > > > Now, in your various directories, use .htaccess files to control which > > version is to be called: > > > >AddType application/x-httpd-php403 .html > >AddType application/x-httpd-php .php > > > > Modify everything above to suit your real needs. > > > > --Dan > > > > -- > >PHP classes that make web design easier > > SQL Solution | Layout Solution | Form Solution > > sqlsolution.info | layoutsolution.info | formsolution.info > > T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y > > 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] storing errors from shell_exec command
On Saturday 10 August 2002 04:14, [EMAIL PROTECTED] wrote: > I need to redirect the output from the shell_exec return variable to a > file. What I have below is not working. What I need to get from the > shell_exec is ant errors that happen and then I what to store those > errors in a error file > > $output=shell_exec($cmd); > $cmd ="`$output > /usr/autoserv/errlog`"; Not sure whether it'll make any difference, but you do NOT need the backticks. > exec($cmd); Why not do it in a single step? shell_exec("command_to_execute > /usr/autoserv/errlog"); -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* A fool and his money are soon popular. */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Next and Previous links
On Friday 09 August 2002 22:35, webmaster wrote: > Also, I keep getting an error that pg_fetch_row() and pg_fetch_array() > requires at least 2 parameters where all the examples I find only use > 1. Is this a DB configuration problem? Did you try the obvious step of consulting the manual? -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* HELLO KITTY gang terrorizes town, family STICKERED to death! */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Please help with array_diff()
On Saturday 10 August 2002 01:50, Gandalf wrote: > Well of course $foo[0] contains the first dimension of the $foo array and > the same goes for $bar[0]. The first rule of debugging is not to assume anything. Perhaps I should've phrased my question better: "Print out the damn things and see what they contain!" > It is still not working as it should, i am close to going nuts. You're not helping others to help you with your reply. -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* Lake Erie died for your sins. */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Thumb nail of a web page
On Saturday 10 August 2002 05:03, Henry wrote: > Hi All, > > Just out of interest, does anyone know of a way to generate a thumb nail of > a web page given a URL? This would be a major task. You would have to write a complete HTML renderer in PHP. Maybe some clever soul could write a library that interfaces to Mozilla's gecko engine. -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* Nothing matters very much, and few things matter at all. -- Arthur Balfour */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Can't find my font file - Please help
On Saturday 10 August 2002 09:48, JR wrote: > I am trying to use the "imagettfbbox" function. Am testing the script on > my local network > running W2K. Have defined : > $fontfile = "arial.tff"; // this file is in the same Shouldn't that be "arial.ttf" ? -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* "I have just one word for you, my boy...plastics." - from "The Graduate" */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Win PHP Editor...
> But why not use notepad. Because it reduces your production speed and time is money. So, what costs you more? Maxim Maletsky [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Win PHP Editor...
For Windows, Edit Plus is the best! I even wrote a PHP library for it. (Check though their user files) Sincerely, Maxim Maletsky PHP Beginner www.phpbeginner.com > -Original Message- > From: Jonni [mailto:[EMAIL PROTECTED]] > Sent: Saturday, August 10, 2002 4:34 AM > To: PHPlist > Subject: RE: [PHP] Win PHP Editor... > > i LOVE my edit plus! :) > > > > > -Original Message- > > From: Liam MacKenzie [mailto:[EMAIL PROTECTED]] > > Sent: Friday, August 09, 2002 6:38 PM > > To: Dave at Sinewaves.net; PHPlist > > Subject: Re: [PHP] Win PHP Editor... > > > > > > Well, I still believe the best editor for windows is Editplus > > (www.editplus.com) > > > > Small, fast, stable, tonnes of features and it supports a lot of > > file type. > > If it doesn't give you colour coding for a particular language, say Cold > > Fusion, go to the homepage and download the plugin. > > > > It's only 800K to download, give it a shot. It's uninstall > > program actually > > gets rid of it aswell, completely. so if you don't like it, no > sweat :-P > > > > Just my 2 cents... > > > > Liam > > > > > > > > - Original Message - > > From: "Dave at Sinewaves.net" <[EMAIL PROTECTED]> > > To: "PHPlist" <[EMAIL PROTECTED]> > > Sent: Saturday, August 10, 2002 3:42 AM > > Subject: [PHP] Win PHP Editor... > > > > > > > Just have to add one little fine piece of free software that nobody's > > > mentioned yet, Crimson Editor (http://www.crimsoneditor.com ) > > > > > > No code completion, but it's got every other feature of the big > > commercial > > > beasts... definitely check it out - I just switched over, and > > it's great. > > > > > > > > > From the site: > > > -- > > > Edit multiple documents > > >- switch between documents using file selection tab > > >- pressing Ctrl+Tab brings the last accessed document to top > > > > > > Syntax highlighting > > >- configurable via custom syntax files > > >- preconfigured for more than 50 computer languages > > > > > > Multi-level undo / redo > > >- all editing actions are recorded from the opening of a file > > >- unlimited undo and redo buffers > > > > > > Find & Replace > > >- replace specified text one by one, or as a whole > > >- support regular expression > > > > > > Natural word wrapping > > >- word wrapping does not affect syntax highlighting > > >- configurable wrapping indentation (easer to understand the > syntax) > > > > > > Spell checker > > >- around 10 words were added in the dictionary > > >- users can register new words in their own dictionary > > > (InstallDir/user.dic) > > > > > > User tools and macros > > >- execute external programs with proper arguments > > >- compile, execute and test your code > > >- ease your fingers with key stroke recording (record & replay) > > > > > > Directory tree view window > > >- click to open documents > > >- filter to display only selected file class > > > > > > Edit remote files directly using built-in FTP client > > >- open, edit, and save documents in remote FTP servers > > >- save account information (encoded) for automatic logon > > > > > > Print & Print preview > > >- configurable page header and footer > > >- print with line numbers > > >- print with syntax highlighting (used in color printer) > > >- true type font selection for printer > > > > > > Other useful features > > >single instance / multiple instances, ability to detect > > changed files, > > >bookmark & go to, highlight active line, highlight matching pairs, > > >multi-byte support with integrated IME (for eastern languages), > > >auto indent, wheel mouse support, copy & paste, line numbers, > > >configurable line spacing, option to save files in Unix format, > > >option to set working directory > > > > > > > > > > > > > > > Very nice little IDE, and the price is right! Nothing! > > > > > > Dave > > > > > > > > > -- > > > 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 Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Win PHP Editor...
i LOVE my edit plus! :) > -Original Message- > From: Liam MacKenzie [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 6:38 PM > To: Dave at Sinewaves.net; PHPlist > Subject: Re: [PHP] Win PHP Editor... > > > Well, I still believe the best editor for windows is Editplus > (www.editplus.com) > > Small, fast, stable, tonnes of features and it supports a lot of > file type. > If it doesn't give you colour coding for a particular language, say Cold > Fusion, go to the homepage and download the plugin. > > It's only 800K to download, give it a shot. It's uninstall > program actually > gets rid of it aswell, completely. so if you don't like it, no sweat :-P > > Just my 2 cents... > > Liam > > > > - Original Message - > From: "Dave at Sinewaves.net" <[EMAIL PROTECTED]> > To: "PHPlist" <[EMAIL PROTECTED]> > Sent: Saturday, August 10, 2002 3:42 AM > Subject: [PHP] Win PHP Editor... > > > > Just have to add one little fine piece of free software that nobody's > > mentioned yet, Crimson Editor (http://www.crimsoneditor.com ) > > > > No code completion, but it's got every other feature of the big > commercial > > beasts... definitely check it out - I just switched over, and > it's great. > > > > > > From the site: > > -- > > Edit multiple documents > >- switch between documents using file selection tab > >- pressing Ctrl+Tab brings the last accessed document to top > > > > Syntax highlighting > >- configurable via custom syntax files > >- preconfigured for more than 50 computer languages > > > > Multi-level undo / redo > >- all editing actions are recorded from the opening of a file > >- unlimited undo and redo buffers > > > > Find & Replace > >- replace specified text one by one, or as a whole > >- support regular expression > > > > Natural word wrapping > >- word wrapping does not affect syntax highlighting > >- configurable wrapping indentation (easer to understand the syntax) > > > > Spell checker > >- around 10 words were added in the dictionary > >- users can register new words in their own dictionary > > (InstallDir/user.dic) > > > > User tools and macros > >- execute external programs with proper arguments > >- compile, execute and test your code > >- ease your fingers with key stroke recording (record & replay) > > > > Directory tree view window > >- click to open documents > >- filter to display only selected file class > > > > Edit remote files directly using built-in FTP client > >- open, edit, and save documents in remote FTP servers > >- save account information (encoded) for automatic logon > > > > Print & Print preview > >- configurable page header and footer > >- print with line numbers > >- print with syntax highlighting (used in color printer) > >- true type font selection for printer > > > > Other useful features > >single instance / multiple instances, ability to detect > changed files, > >bookmark & go to, highlight active line, highlight matching pairs, > >multi-byte support with integrated IME (for eastern languages), > >auto indent, wheel mouse support, copy & paste, line numbers, > >configurable line spacing, option to save files in Unix format, > >option to set working directory > > > > > > > > > > Very nice little IDE, and the price is right! Nothing! > > > > Dave > > > > > > -- > > 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] Can't find my font file - Please help
I am trying to use the "imagettfbbox" function. Am testing the script on my local network running W2K. Have defined : $fontfile = "arial.tff"; // this file is in the same directory with my script The instruction that fails: $thetextbox = ImageTTFBBox ($fontsize, 0, $fontfile, "My Button"); The error message is: Warning: Could not find/open font in c:\phpdev\www\public\kazaam\rendertext.php on line 9 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Win PHP Editor...
Well, I still believe the best editor for windows is Editplus (www.editplus.com) Small, fast, stable, tonnes of features and it supports a lot of file type. If it doesn't give you colour coding for a particular language, say Cold Fusion, go to the homepage and download the plugin. It's only 800K to download, give it a shot. It's uninstall program actually gets rid of it aswell, completely. so if you don't like it, no sweat :-P Just my 2 cents... Liam - Original Message - From: "Dave at Sinewaves.net" <[EMAIL PROTECTED]> To: "PHPlist" <[EMAIL PROTECTED]> Sent: Saturday, August 10, 2002 3:42 AM Subject: [PHP] Win PHP Editor... > Just have to add one little fine piece of free software that nobody's > mentioned yet, Crimson Editor (http://www.crimsoneditor.com ) > > No code completion, but it's got every other feature of the big commercial > beasts... definitely check it out - I just switched over, and it's great. > > > From the site: > -- > Edit multiple documents >- switch between documents using file selection tab >- pressing Ctrl+Tab brings the last accessed document to top > > Syntax highlighting >- configurable via custom syntax files >- preconfigured for more than 50 computer languages > > Multi-level undo / redo >- all editing actions are recorded from the opening of a file >- unlimited undo and redo buffers > > Find & Replace >- replace specified text one by one, or as a whole >- support regular expression > > Natural word wrapping >- word wrapping does not affect syntax highlighting >- configurable wrapping indentation (easer to understand the syntax) > > Spell checker >- around 10 words were added in the dictionary >- users can register new words in their own dictionary > (InstallDir/user.dic) > > User tools and macros >- execute external programs with proper arguments >- compile, execute and test your code >- ease your fingers with key stroke recording (record & replay) > > Directory tree view window >- click to open documents >- filter to display only selected file class > > Edit remote files directly using built-in FTP client >- open, edit, and save documents in remote FTP servers >- save account information (encoded) for automatic logon > > Print & Print preview >- configurable page header and footer >- print with line numbers >- print with syntax highlighting (used in color printer) >- true type font selection for printer > > Other useful features >single instance / multiple instances, ability to detect changed files, >bookmark & go to, highlight active line, highlight matching pairs, >multi-byte support with integrated IME (for eastern languages), >auto indent, wheel mouse support, copy & paste, line numbers, >configurable line spacing, option to save files in Unix format, >option to set working directory > > > > > Very nice little IDE, and the price is right! Nothing! > > Dave > > > -- > 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] Re: Getting information of a client
Try this: $_POST['var_name'] Monty > From: [EMAIL PROTECTED] (Radio X) > Newsgroups: php.general > Date: Fri, 9 Aug 2002 23:38:42 -0700 > To: <[EMAIL PROTECTED]> > Subject: Re: [PHP] Re: Getting information of a client > > how can i get a variable posted from a form by a user whitout having > register_globals set On? > > Nick > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Name of Include File breaking a Function - Strange!
Dan, you were right and I feel so retarded now! I found another include file of the same name in the folder with the script that wasn't working. It was driving me crazy but I didn't even think to check that. Thank you for replying! Monty. > Perhaps, somewhere in your include path is another file named > functions.inc.php? > > Perhpas another file you're mistakenly including has a function already > named user_acess()? > > In your test script, use the function_exists() function before you define > the user_acess() function to see what's going on. > > --Dan > > -- > PHP classes that make web design easier > SQL Solution | Layout Solution | Form Solution > sqlsolution.info | layoutsolution.info | formsolution.info > T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y > 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Next and Previous links
I found an answer for anyone who may be interested on phpbuilder.com http://phpbuilder.com/annotate/message.php3?id=1010986 -Elkan webmaster wrote: > Hello, > > I've been trying write a .php page that displays 10 results per page > with links to the next 10 avail. I've found a couple examples on how to > do this with MySQL, and I tried to convert it to work with Postgres with > no luck. Has anyone ever done this using PHP4.0.6 and Postgres 7.1? > > Also, I keep getting an error that pg_fetch_row() and pg_fetch_array() > requires at least 2 parameters where all the examples I find only use > 1. Is this a DB configuration problem? > > Thanks in advance, > -Elkan > > -- > 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] Can I perform a PHP script from a form but stay on the same page afterwards?
http://www.faqts.com/knowledge_base/view.phtml/aid/235/fid/17 - Original Message - From: "php @ banana" <[EMAIL PROTECTED]> To: "PHP-GENERAL" <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 5:51 PM Subject: Re: [PHP] Can I perform a PHP script from a form but stay on the same page afterwards? >You can send a 204 No Content header, and the browser won't move to the new >page, but instead the PHP script will be executed and the browser will stay >on the same page. could you gimmie a code snippet of the above Thanks R> > >Jim Dam >[EMAIL PROTECTED] > > >- Original Message - >From: "César Aracena" <[EMAIL PROTECTED]> >To: "'DonPro'" <[EMAIL PROTECTED]>; "'php list'" <[EMAIL PROTECTED]> >Sent: Friday, August 09, 2002 4:53 PM >Subject: RE: [PHP] Can I perform a PHP script from a form but stay on the >same page afterwards? > > >> > -Original Message- >> > From: DonPro [mailto:[EMAIL PROTECTED]] >> > Sent: Friday, August 09, 2002 5:34 PM >> > To: php list >> > Subject: [PHP] Can I perform a PHP script from a form but stay on the >> same >> > page afterwards? >> > >> > Hi, >> > >> > I have a form where the user can change a value ion a text box and >> then >> > click on a button which will update a table in a MySQL database. I >> assume >> > that the only way to do this is to have the button POST the form value >> to >> > my >> > script which updates the MySQL table. >> > >> > However, once updated (whether the update is successfull or not), I >> need >> > to >> > remain or return to the same page that the form is on. >> > >> > Can this easily be done? >> > >> > >> [Cesar Aracena] >> >> Sure. All you have to do is point the form's action to $PHP_SELF and the >> play a little with the *IF* and *ELSE IF* statements. >> >> > >> > -- >> > 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 > --__-__-__ eat pasta type fasta -- 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] Connection to Access 2000 mdb file on another computer.
Jason, One option you have is to install OpenLink's Multi-Tier driver, ODBC Agent, which will allow you to "piggyback" on DSNs on other machines, e.g: webserver with PHP, client side MT driver DSN (let's call it "local_dsn") with ODBC as ServerType, and IDS as Name db server with MS Access, server side MT driver DSN called IDS using MS driver for Access. so: PHP-->local_dsn in client side MT->server side MT driver--->ODBC Agent--->IDS DSN.mdb file. Selecting the appropriate platforms and database at the OpenLink "Software Availability" link will lead you to the appropriate components. Let me know if you need additional clarification, although this example is pretty well laid out in the OpenLink MT docs. Cheers, Andrew On Friday, August 9, 2002, at 04:48 PM, Jason Morcom wrote: > Forgive my ignorance but i can not find how to connect to an Access 2000 > (mdb) file through PHP if the file is on another computer in a lan (not > on > same computer as Apache/PHP server) I have no problem connectig to an > mdb > through ODBC and a valid DSN(system) for a local mdb file, but i get a > general error (see below) when the DSN points to a file through a mapped > drive "R:\file.mdb" or an actual path "\ \server\dir\dir\file.mdb" > {{{ > Warning: SQL error: [Microsoft][ODBC Microsoft Access Driver] The > Microsoft > Jet database engine cannot open the file '(unknown)'. It is already > opened > exclusively by another user, or you need permission to view its data., > SQL > state S1000 in SQLConnect in c:\apache\htdocs\www\php\tmpa2w9rldsv.php > on > line 1 > }}} > I have no passwords on this file and its not being used exclusively by > anyone. > > Here is my PHP code: > > The "IDS" is of course a valid system DSN. I have used this DSN by > Crystal > Reports with no problems. And i am not using the file when i do my PHP > tests. > > There is no username or password in the DSN as i assume i do not need > one. I > can only assume i have to pass some sort of authorization string with > the > ODBC connect or i just cant do it this way. I've heard many things about > using IIS for the server but I am using Apache on Win2k and don't wish > to > change. If it matters the file i need to access is on a Win NT 4 server > but > its just a shared folder with the correct permissions. > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] While loop not working - please help
Can anyone tell me why this part of my code is not functional? The code might be quite messy to look at, but I've commented wherever I can. $gp = fopen("myFile.txt","r"); while(($t = fgets($gp,1024)) && !feof($gp)) { if ($t[0] == '=' && $t[1] == 'D') { \\Looks for =D in myFile.txt $entryDate[] = fgets($gp,30); \\then takes next line and } elseif ($t[0] == '=' && $t[1] == 'A') {\\puts it into $entryDate[] $entryAuth[] = fgets($gp,50); } elseif ($t[0] == '=' && $t[1] == 'C') { \\With a =C in myFile.txt $readAll = fread($gp,1024); \\it reads 1024 characters & $readAll = str_replace("\\replaces all newlines ", "", $readAll);\\ with a HTML tag. $endPoint = strpos($readAll,"^end"); \\Detects the position of ^end $readTil = $endPoint - 1; \\ and outputs $readTil $entryCont[] = substr($readAll,0,$readTil); \\ content to this point } else { /* Nothing to be done, go back to beginning of while */ } } The problem is that it doesn't actually go back to the beginning of the while loop. I've checked the array counts for the $entryDate[] array and it always tells me that I have only 1 entry, even though myFile.txt has 2 or more entries. So it doesn't seem to go anywhere. When I replace the part after checking for =C with a simple fgets (like the other 'if' parts of the code), it works perfectly. Something in the functions after the if( =C) is stopping the while loop and I don't know what it is! Note: It does execute all the functions after the if(... =C), because the $entryCont[] array contains all the formatted/substituted text. Please help? -Wendy - This mail sent through IMP: www-mail.usyd.edu.au -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: JPgraph: Autoscaling [OT perhaps]
Just so you don't feel alone. I use jpgraph alot, however, I have not run into this problem. What version of jpgraph are you suning. "Lee P. Reilly" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Anybody out there using JpGraph? I directed the following question to > the support web site, but as yet... there's been no reply: > > Could somebody tell me how to disable the autoscaling in JpGraph, and/or > > how to provide my own scaling? It's perfect for 99% of the graphs and > plots I create, but when I plot some data in a linearXlogY scale it's > surrounded by way too much white space. Particularly, I've noticed that > the logY scale always seems to go from 10,000 to 100,000 for my data > sets when the Y range is only from 20k to 10k. > > E.g. Say I had 2 data points : 1,5 and 5,1 > +The graph may show a grid e.g. 10 x 10 > + How can I set it so that it only pads a few pixels, or say display > 0,0 up to 6,6? > > Does this make sense? Hope someone can help! > > While I'm on the topic, does JpGraph support Sub/SuperScript text? > Nothing about it in the documentation, but I need to display N^2 (N > squared) and stuff like that. > > Thanks in advance, > Lee > > PS: JpGraph is an awesome little library ;-) > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] (HELP) - PHP has encountered an Access Violation
I get the following errors when I run my script. It works fine with only 20 records, but at 100 I get errors. "PHP has encountered an Access Violation at 00DA088E Warning: Unknown list entry type in request shutdown (2) in c:\www\htdocs\demos\ct.org\directory.php on line 0" or "PHP has encountered an Access Violation at 00DA088E " Basically, I have a CSV file with about 3500 records (lines). I have a while statement that goes through the file line by line. I am using fgetcsv(). While on a line I also open another file and search for a matching field (CustomerID) and if it matches print the information on that line unless a field in that file is set to "1". This was initially tried using a query since this data is in a database. That did not work. I exported the data into csv files. It worked in testing limiting the amount of records to be displayed to less than 30. I just tried it with limit set to 100 and that's when I got the problem. Here is the code; http://inxdesign.com| | [EMAIL PROTECTED]| | | |__| This script was created to help prepare the directory information, for the Connecticut Technical Council for the Year 2002. My Material - Please do not copy or modify it with checking with me first. ([EMAIL PROTECTED]) Please leave the INFORMATION banner in place. */ file://==Global Definitions file:// define('SCRIPT_NAME', 'Connecticut Technology Council Directory Maker'); define('SCRIPT_VERSION', 'v1.0'); define('SCRIPT_CREATOR', 'mailto:[EMAIL PROTECTED]";>Christopher J. Crane'); define('CREATE_DATE', '08/06/02'); define('REVISED_DATE', '08/06/02'); $TestingMode = "On"; file://On or Off $ShowCount = "10"; $row = 0; print "Company Directory 2002"; print "T e s t i n gM o d e - "; if($TestingMode == "On") { print "OnOnly Showing The First $ShowCount Records.\n"; } else { print "Off\n"; } print "End"; print "\n"; file://==C o m p a n y D a t a O u t p u t file://=== $Data1 = fopen("Final.csv","r"); while ($Line1 = fgetcsv($Data1, 1000, ",")) { $CompanyID = $Line1[0]; $CompanyName = $Line1[1]; $MemberTypeID = $Line1[2]; $RevenueID = $Line1[3]; $Ownership = $Line1[4]; $NoPubRevenue = $Line1[5]; $YearEstablished = $Line1[6]; $Exchange = $Line1[7]; $TotalEmployees = $Line1[8]; $ConnEmployees = $Line1[9]; $Ticker = $Line1[10]; $Email = $Line1[11]; $Website = $Line1[12]; $IndustryID = $Line1[13]; $AddressTypeID = $Line1[14]; $AddressLine1 = $Line1[15]; $AddressLine2 = $Line1[16]; $City = $Line1[17]; $State = $Line1[18]; $Zip = $Line1[19]; $CountyName = $Line1[20]; $Profile = $Line1[21]; if($row != 0) { print " $CompanyName\n"; if($AddressLine1 != "") { print "$AddressLine1\n"; } if($AddressLine2 != "") { print "$AddressLine2\n"; } print "$City, $State $Zip\n"; file://==P h o n e D a t a O u t p u t file://=== $Data2 = fopen("PhoneTable.csv","r"); while ($Line2 = fgetcsv ($Data2, 1000, ",")) { $CompanyID2 = $Line2[0]; $PhoneType = $Line2[1]; $AreaCode = $Line2[2]; $Prefix = $Line2[3]; $Suffix = $Line2[4]; if($CompanyID2 == $CompanyID) { if($PhoneType == "Office") { print "Phone: ($AreaCode)$Prefix-$Suffix"; } } } fclose($Data2); file://==F a x D a t a O u t p u t file://=== $Data3 = fopen("PhoneTable.csv","r"); while ($Line3 = fgetcsv ($Data3, 1000, ",")) { $CompanyID3 = $Line3[0]; $PhoneType = $Line3[1]; $AreaCode = $Line3[2]; $Prefix = $Line3[3]; $Suffix = $Line3[4]; if($CompanyID3 == $CompanyID) { if($PhoneType == "FAX") { print "Fax: ($AreaCode)$Prefix-$Suffix"; } } } fclose($Data3); print ""; file://==W e b s i t e / E m a i l D a t a O u t p u t file://== if(($Website != "") || ($Email != "[EMAIL PROTECTED]")) { if($Website != "") { print "Website: $Website\n"; } if($Email != "[EMAIL PROTECTED]") { print "E-Mail: $Email\n"; } } file://==O w n e r s h i p D a t a O u t p u t file://=== print "Ownership: "; if($Ownership == "1") { print "Private "; } if($Ownership == "2") { print "Public "; if(!($Exchange == "OTHER" or $Exchange == "")) { print "($Exchange: $Ticker) "; } } if($YearEstablished != "0") { print "Est. $YearEstablished"; } print ""; file://==E m p l o y e e D a t a O u t p u t file://= print "CT Emp: "; if(($ConnEmployees >= 1) && ($ConnEmployees <= 9)) { print "1-9 "; } elseif(($ConnEmployees >= 10) && ($ConnEmployees <= 50)) { print "10-50 "; } elseif(($ConnEmployees >= 51) && ($ConnEmployees <= 100)) { print "51-100 "; } elseif(($ConnEmployees >= 101) && ($ConnEmployees <= 250)) { print "101-250 "; } elseif(
RE: [PHP] Next and Previous links
Could you send me the URL's for the MySQL examples? Thanks!! > -Original Message- > From: webmaster [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 10:36 AM > To: [EMAIL PROTECTED] > Subject: [PHP] Next and Previous links > > > Hello, > > I've been trying write a .php page that displays 10 results per page > with links to the next 10 avail. I've found a couple examples on how to > do this with MySQL, and I tried to convert it to work with Postgres with > no luck. Has anyone ever done this using PHP4.0.6 and Postgres 7.1? > > Also, I keep getting an error that pg_fetch_row() and pg_fetch_array() > requires at least 2 parameters where all the examples I find only use > 1. Is this a DB configuration problem? > > Thanks in advance, > -Elkan > > > -- > 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] Next and Previous links
Hello, I've been trying write a .php page that displays 10 results per page with links to the next 10 avail. I've found a couple examples on how to do this with MySQL, and I tried to convert it to work with Postgres with no luck. Has anyone ever done this using PHP4.0.6 and Postgres 7.1? Also, I keep getting an error that pg_fetch_row() and pg_fetch_array() requires at least 2 parameters where all the examples I find only use 1. Is this a DB configuration problem? Thanks in advance, -Elkan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Connection to Access 2000 mdb file on another computer.
Forgive my ignorance but i can not find how to connect to an Access 2000 (mdb) file through PHP if the file is on another computer in a lan (not on same computer as Apache/PHP server) I have no problem connectig to an mdb through ODBC and a valid DSN(system) for a local mdb file, but i get a general error (see below) when the DSN points to a file through a mapped drive "R:\file.mdb" or an actual path "\ \server\dir\dir\file.mdb" {{{ Warning: SQL error: [Microsoft][ODBC Microsoft Access Driver] The Microsoft Jet database engine cannot open the file '(unknown)'. It is already opened exclusively by another user, or you need permission to view its data., SQL state S1000 in SQLConnect in c:\apache\htdocs\www\php\tmpa2w9rldsv.php on line 1 }}} I have no passwords on this file and its not being used exclusively by anyone. Here is my PHP code:
Re: [PHP] Can I perform a PHP script from a form but stay on the same page afterwards?
>You can send a 204 No Content header, and the browser won't move to the new >page, but instead the PHP script will be executed and the browser will stay >on the same page. could you gimmie a code snippet of the above Thanks R> > >Jim Dam >[EMAIL PROTECTED] > > >- Original Message - >From: "César Aracena" <[EMAIL PROTECTED]> >To: "'DonPro'" <[EMAIL PROTECTED]>; "'php list'" <[EMAIL PROTECTED]> >Sent: Friday, August 09, 2002 4:53 PM >Subject: RE: [PHP] Can I perform a PHP script from a form but stay on the >same page afterwards? > > >> > -Original Message- >> > From: DonPro [mailto:[EMAIL PROTECTED]] >> > Sent: Friday, August 09, 2002 5:34 PM >> > To: php list >> > Subject: [PHP] Can I perform a PHP script from a form but stay on the >> same >> > page afterwards? >> > >> > Hi, >> > >> > I have a form where the user can change a value ion a text box and >> then >> > click on a button which will update a table in a MySQL database. I >> assume >> > that the only way to do this is to have the button POST the form value >> to >> > my >> > script which updates the MySQL table. >> > >> > However, once updated (whether the update is successfull or not), I >> need >> > to >> > remain or return to the same page that the form is on. >> > >> > Can this easily be done? >> > >> > >> [Cesar Aracena] >> >> Sure. All you have to do is point the form's action to $PHP_SELF and the >> play a little with the *IF* and *ELSE IF* statements. >> >> > >> > -- >> > 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 > --__-__-__ eat pasta type fasta -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Can I perform a PHP script from a form but stay on the same page afterwards?
You can send a 204 No Content header, and the browser won't move to the new page, but instead the PHP script will be executed and the browser will stay on the same page. Jim Dam [EMAIL PROTECTED] - Original Message - From: "César Aracena" <[EMAIL PROTECTED]> To: "'DonPro'" <[EMAIL PROTECTED]>; "'php list'" <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 4:53 PM Subject: RE: [PHP] Can I perform a PHP script from a form but stay on the same page afterwards? > > -Original Message- > > From: DonPro [mailto:[EMAIL PROTECTED]] > > Sent: Friday, August 09, 2002 5:34 PM > > To: php list > > Subject: [PHP] Can I perform a PHP script from a form but stay on the > same > > page afterwards? > > > > Hi, > > > > I have a form where the user can change a value ion a text box and > then > > click on a button which will update a table in a MySQL database. I > assume > > that the only way to do this is to have the button POST the form value > to > > my > > script which updates the MySQL table. > > > > However, once updated (whether the update is successfull or not), I > need > > to > > remain or return to the same page that the form is on. > > > > Can this easily be done? > > > > > [Cesar Aracena] > > Sure. All you have to do is point the form's action to $PHP_SELF and the > play a little with the *IF* and *ELSE IF* statements. > > > > > -- > > 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
RE: [PHP] need help
And that is good actually since malicious users can't see your source code, variables it is difficult to hack the site. > that's the nature of php. it is executed server side then disappears > showing only it's results. :) > > > -Original Message- > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > > Sent: Friday, August 09, 2002 2:21 PM > > To: [EMAIL PROTECTED] > > Subject: [PHP] need help > > > > > > Hi, how come on the "view source" link on the bottom of the > > php.net homepage shows a whole mess of php code but when I select > > "view page source" in Internet explorer or netscape in shows > > everything as html on the home. This is kinda hard for me to > > explain, here is an example below: > > > > > > > > Ever wondered how popular PHP is? see the ' . > > make_link("/usage.php", "Netcraft Survey") . '. > > > > > > (how come they use that "make_link" tag?) > > > > > > Ever wondered how popular PHP is? see the > href="/usage.php">Netcraft Survey. > > > > > > (how come when you view the source from the browser like IE or > > netscape it shows it as regular HTML?) > > > > > > I'm totaly confused can someone please help me?!!! > > > > > > __ > > Pre-order the NEW Netscape 7.0 browser. Reserve your FREE CD and > > pay only $2.99 shipping and handling. http://cd.netscape.com/promo_one/ > > > > Get your own FREE, personal Netscape Mail account today at > http://webmail.netscape.com/ > > -- > 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 > -Pushkar S. Pradhan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] First Attempt to use DB failed.
Jim, Are you using a port other than the default (3306)? If so you can specify it by localhost:3306 Is the server really running? > I ran the following PHP script: > > $die_msg = "Connection to Database Failed" > $connect = mysql_connect("localhost","UserName","UserPW") > or die("Connect Failed" ): > echo $connect; > $db = mysql_select_db("db_cap",$connect) > or Die("db Select Failed"); > ?> > > I received the following error message > Parse error: parse error, unexpected T_VARIABLE in > C:\FREEDEV\XITAMI\webpages\private\test.php on line 3 > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -Pushkar S. Pradhan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] need help
that's the nature of php. it is executed server side then disappears showing only it's results. :) > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 2:21 PM > To: [EMAIL PROTECTED] > Subject: [PHP] need help > > > Hi, how come on the "view source" link on the bottom of the > php.net homepage shows a whole mess of php code but when I select > "view page source" in Internet explorer or netscape in shows > everything as html on the home. This is kinda hard for me to > explain, here is an example below: > > > > Ever wondered how popular PHP is? see the ' . > make_link("/usage.php", "Netcraft Survey") . '. > > > (how come they use that "make_link" tag?) > > > Ever wondered how popular PHP is? see the href="/usage.php">Netcraft Survey. > > > (how come when you view the source from the browser like IE or > netscape it shows it as regular HTML?) > > > I'm totaly confused can someone please help me?!!! > > > __ > Pre-order the NEW Netscape 7.0 browser. Reserve your FREE CD and > pay only $2.99 shipping and handling. http://cd.netscape.com/promo_one/ > > Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ -- 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] First Attempt to use DB failed.
On Fri, Aug 09, 2002 at 04:27:56PM -0500, Jim Bailey wrote: > $die_msg = "Connection to Database Failed" Where's the terminating ";" on that prior line? > $connect = mysql_connect("localhost","UserName","UserPW") > or die("Connect Failed" ): You put a ":" rather than ";" on the prior line. Also, to make your debugging easier, use mysql_error() in your die statements in order to figure out why things didn't work as expected. Naturally, for that to be of any assistance, you'll need to clean up your parse errors first. :) --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] First Attempt to use DB failed.
I ran the following PHP script: I received the following error message Parse error: parse error, unexpected T_VARIABLE in C:\FREEDEV\XITAMI\webpages\private\test.php on line 3 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Having an issue with a Directory Listing in the php Scripting
Hi Duncan: On Fri, Aug 09, 2002 at 04:14:47PM -0500, §§ Duncan MacLeod §§ wrote: > it seems as though this wold work great if I had the script running in a > actual php.. the initial file is index.php but calls to indexcontent.inc > that calls to another inc file that has the actual content info in it. Where the script is doesn't matter. You could include 5 billion layers deep and the operation I sent you will still work the same. Regardless, the point of my code was to show you the direction you need to start thinking in to properly read a directory and extract the names of the files you're looking for. If what I showed you doesn't suit your needs, then tweak things in your script and/or my script until they do. If there's a part of the example you don't understand, go to the manual and check it out. >From what I quickly saw of your large script in your first posting, it seemed WAY overly complex for the simple task at hand. > maybe it would help if put a copy of the inc file and a copy of the php > files.. Not really. The likelyhood of someone wanting to read huge chunks of code is low. Especially when it's base64 encoded. Posting such stuff (let alone top posting w/o removing irrelevant parts of prior posts) to the list wastes a lot of bandwith and disk storage space. Later, --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] need help
Hi, how come on the "view source" link on the bottom of the php.net homepage shows a whole mess of php code but when I select "view page source" in Internet explorer or netscape in shows everything as html on the home. This is kinda hard for me to explain, here is an example below: Ever wondered how popular PHP is? see the ' . make_link("/usage.php", "Netcraft Survey") . '. (how come they use that "make_link" tag?) Ever wondered how popular PHP is? see the Netcraft Survey. (how come when you view the source from the browser like IE or netscape it shows it as regular HTML?) I'm totaly confused can someone please help me?!!! __ Pre-order the NEW Netscape 7.0 browser. Reserve your FREE CD and pay only $2.99 shipping and handling. http://cd.netscape.com/promo_one/ Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Newbie question about SQL result formatting
There we go :) If there's any consolation, you just helped NataliePortman.com become a better website :) Thx /Kris "Philip Hallstrom" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > see nl2br(). You might also want to convert spaces to 's > > On Fri, 9 Aug 2002, Kristoffer Strom wrote: > > > Ok, this is totally newbie but I just started messing around with PHP after > > programming IBM's NetData for a while. > > > > My first big problem I haven't been able to solve myself is how to format > > the result of an SQL query into HTML code. > > In the (MySQL) database, I have one field for very long texts. One test > > entry looks like this: > > -- > > test > > > >test > > > > test > > -- > > But when printing the result, even with HTMLENTITIES and HTMLSPECIALCHARS, > > just looks like: > > - > > test test test > > - > > > > How do I convert the result to HTML code, I especially want the linebreaks!! > > > > The answer is probably very simple > > > > /Kris > > > > > > > > -- > > 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] Having an issue with a Directory Listing in the php Scripting
it seems as though this wold work great if I had the script running in a actual php.. the initial file is index.php but calls to indexcontent.inc that calls to another inc file that has the actual content info in it. maybe it would help if put a copy of the inc file and a copy of the php files.. ?? anyhow if anyone else cares to help it would be great unless the original Daniel would like to try this one out.. lol.. let me know it is greatly appreciated. §§ Duncan MacLeod §§ "Analysis & Solutions" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > On Fri, Aug 09, 2002 at 08:58:41AM -0500, §§ Duncan MacLeod §§ wrote: > > I am only being able to list the first > > file in each of the directories. Not the entire directory. > ... snip ... > > > Although, the only files I really need out of the > > directory are going to be '.JPG', '.jpg', '.GIF', '.gif', '.JPEG', '.jpeg'. > > While this doesn't do exactly what your script does, it will point you in > the right direction... > > > $DirHandle=opendir('.'); > > while ($FileName = readdir($DirHandle)) { >switch ( substr($FileName, -4) ) { > case '.jpg': > case '.JPG': > case 'jpeg': > case 'JPEG': > case '.gif': > case '.GIF': > $FileList[] = $FileName; > break; >} > } > > # Sort the list alphabetically: > asort($FileList); > > echo ''; > while (list(,$Name) = each($FileList) ) { >echo "$Name\n"; > } > echo ''; > > ?> > > -- >PHP classes that make web design easier > SQL Solution | Layout Solution | Form Solution > sqlsolution.info | layoutsolution.info | formsolution.info > T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y > 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 begin 666 my_inc_files.zip M4$L#!!0``@`(`/M^"2W97?3\4D-58D ME4$):)RA7C-\J* M:QD7&-2)..]U!T9;-8C42!:Q-5LZ"0&?JU\+C1F;2P$V]S?67Z29-3]O3I+- M7PXVXS24,[U-/S9D=#-WM0*O=YTVTYG:WQQ+G.Z&>0E+Z/M(HC,9OH<$)F(^L4 MB?ZU4.)*U83P3I1&>CRQ*A_HB%3K$/7G&2,"B$?6T(G=SI6,M^$$.AEO0S@E ME V;B_@&%A,)*: )&W!]3+35,O9HX#(FS:U(DVH:_1[P*%M3&EOS(45KR JX@#T=Z%,QIKQ$#&\:!" M`N^3SMM+-@+ ![\%F*FS80HC[5W=O(K(]JBTXBBICAJ ML(&:XKBA8F7Q\J&A8RBUZ530\#I@T4V19;DR1F%BF)[/Q;56,Q%UK=1QY-("O,Y&,4M(*H4'AFN4XI M:O!JI;D*FJ4.I,,_@0_G`9BY"DQ+!,/"VC2A5T1?,,YEAK@*:GVZ69=V[E3J MP?=K]NX`,.+5PR4!9JH4T.EC@ C.YP"R>:'V[XV2^/4@)'JYL;[V@<,.&M)D M!5AX2_ G`RO'L1BJ4ME(+[$:64[JE!$P]U9\49X3!18D8<14 MR<0L..(4KL'.1)]N)0,0-:&BA;1U/*RJ")&/94WL4J '"]Z6DRAO&1L)XO>*Z-H MFV9L&RB',G&2%58,TQME''>YGB[%09F=DRR$2:Q*[")6*#E/9ZQC0!![FL$Q MM\%K:U,<"H^Z5W@JVMK8!9F>G(3IRF9")<[I%5# L> M%B93H1Z1KC@*84%2F--WBQA16^,M(6IL!R+8W=G);LB7U]8`_V(413\'F.'\ M8A&R<6^L5L]+\5+SKDW'P+_%WSSBN8U`[/8.>$B!DDBL:-&DU0/4:<8=AC3PL*,C(26 MP,<0$5Y/01CK\(J6V*!,'=620([RUG'BD,!34.;&-GT;D$$7/D^LS=YN;P?[ M=\!?9'*LOC.V&(W^&.5A[036. M6*ATR "N3G#CI O!A3,IFI$3G!ODB',U[9)1XE$X=SSI]TX%_78C%,+")9O! M"'EO,D"IF8;>_CP#(*QF7PY'=3[DS%UF-/$O2(<4K3-.$UAC/8./3;&>YX2',D^>QE5,E6;5[&/UFN%-RY5!JRH-6E5M MT.+RAM?.TP9R5I-_>T==*'(N@EN)6-H%BC"'1. E\?S>M/.'ILEJHU,;Y=;L MDX=F0PE8'2$UKB=H5N=0)>7?,]C1'Z N$^L6:1'&)U4$Q]1Y_1T'3YWIQ&XZS M2&.W]>9-<_\6'^"6DP0K32Q^=RO+/4YYR5MDUN\H1VF15/ZX* !7&0A.B26< MEP>B1_7)VD<7L54$+%*/E LJC/A0B4U:XV5U+%"O(\)SQ4I%X"&Y]^9=E %5 MP661)A.W.P8@X?$\UDQCWBT&MNJ4>4MUT9#<>#K'?_&R$@,%@=O):[?3\7*7 MV]&7]]!X"Q F]WH/HK3%04"[//_K/CN+.CM YC)4EGOHFL'[#/B2GB;IR&L# MG,-?6J]:KYN+PGTYZ5YTZ6RD6"8)5Z?#^4/4Q:>+X^Z%>/_3(A*H3):N`JTI MS1I#H4B)JWOVNS=8HOLC8'"IB@\`:,@ZQ=#+@#874B;K@PX"(ZP$)P@!^/K_C(X M5:$DZ#0Y02BWV118MI;.\'N5H/_V=RL`O-X`LAS U?;PE\0Z`#\D0JQI0SIO MFD,AR;@EL",3B5)1E6#=4R*%A]BW0VU ML"]!E1A[OS N*\$)KK"P$;D%?XEG]G56\>3[XPVU&1CHW=J6:,/9? M8>2^0OBD;#D;I_*;<3%%'12K%7ST>/!K.-E]OEV&.K>30;1*)^]I6!P_IA?: M\=SEY?E:^5>JD]6L_ VCWXH3U%U7#\>T$1> N55O(+\L&A/X'[ M@2<'?R\4)K:"LY2*#/]?_) 0(_A9O5RJ1",97G)ZH-_ERY',K-2$XC*-(XUT MWPK.E30H4(,F4_9G@<1S.?"X@EZMT- 1W[#Q5,V?IP%/YWRBIIO^@ MELHSQH>R\+$_+5J:C9^BM==/5=I/I)8ELCPBQ$QB2Y4/C!XG:M5"]X5AQ"7# M_!:%R(M8F8=EN""0W[ (1MVLX/Q2W?Q7&>Z!X0_W&>X]PK",(JK7=E=PW?'# MWVC)]=R\>IB;5]^(FU#;^:KTR9;D(ST_'O.3OW\\XR>/_G#) MSY_H>HRGQ_ ]]X4Q]'A6C^%[3+?'=,\8_NQ'?I[P\V_\[/&3,9\Q5V>, M\Q/#?&)9/EW0\YRIG//[!=.Z9/A+AN\SW?X_Z/F9*?[HGCSK1X;_PN]?F(;W"-G4XA8SI# M:#ZB\TR'MLA7>K,;_2K_>+WS!&F?LJT+Z?1WU0)#8_\;]D15&?,]QZI2[-B- M_D>+FF7N\F]79E4W`83BTTJ2KFHCX%/A=JRN5>R/)$4H,SG4L>\^HCMH95ON MQ#F,BZB^&EH\L'7'\/.%Z_C+[FGWJ"]X_9ZJQ!*R^DBRY*D\'@9?F^Y$B_IZ MKI0(_K"[^X= =,Z._4G7JW>[?Z'^(9**SK<<__UTU:7S6F"KKGMR5?/; MN-92>.4VW7BF+.T")&3E!K0P*S, MY^["`3BH>3 !C9 ./4 M:R(-TV2HH2H5K2)W;DRP=*6JT\(`B3_Q1QZ.8[JFD>%50 >RFL]U03Q1M'N< M4$,,-E^>J^KFA60@.F6;992R2 @;RQ>K-!;87";&^5O;R)$*G%(6S9IK<\6= M($"J0W\6+;F!)?=$1 +)J'VKQK:Q3LU7"/UVF^DQ*W>I<<^"2QC@ON]:-W/H MY1Z@;Q9%"N-;)L<$1XT_+*_\F%UP6""(-]8;U/# L.V>O&DZ+==W9-3 4^3D M-9A"_%'+:)%QWZ!CG@ZPXUOL#ZQ5W\X^&:A;0/<+HS6?#DTB7XWJVR"O43 M@5]N?^+[,G;7?*HBS4[*UXKNV)_SU)8HW33+TW$NIU-%%S@&G"81;&1I!O^% MHJPHE,M)FR\?T]Y9W0)A_E]BOOLHLW&K3^ MF$R&G*E,F%(CD[]\J*EQ@W$9BB MV^EW1;_S_K1+G43)6 %*-*BEW,F'G*CA+Q;YO;'[IR:U?8NSSZ>G+0:AB^QK MZF"3>6,
Re: [PHP] special characters
On Fri, Aug 09, 2002 at 02:58:26PM -0400, Jeb A. Scarbrough (home) wrote: > > a) strip out any non-standard ascii characters (like the TM or > copyright symbol) preg_replace() or ereg_replace(). > b) have PHP encode all these symbols. > > I know about htmlentities, but it not catch everything. htmlentities() is the only automatic game in town. --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Newbie question about SQL result formatting
On Fri, Aug 09, 2002 at 10:55:52PM +0200, Kristoffer Strom wrote: > > How do I convert the result to HTML code, I especially want the linebreaks!! Two options. Put the output in between tags. Or if you want the regular font, in PHP use the nl2br() function. --Dan PS: For future reference... The mailing list archive is at http://groups.google.com/groups?hl=en&safe=off&group=php.general Putting in the search terms "line break" produces a plethora of results with this same answer. -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Newbie question about SQL result formatting
see nl2br(). You might also want to convert spaces to 's On Fri, 9 Aug 2002, Kristoffer Strom wrote: > Ok, this is totally newbie but I just started messing around with PHP after > programming IBM's NetData for a while. > > My first big problem I haven't been able to solve myself is how to format > the result of an SQL query into HTML code. > In the (MySQL) database, I have one field for very long texts. One test > entry looks like this: > -- > test > >test > > test > -- > But when printing the result, even with HTMLENTITIES and HTMLSPECIALCHARS, > just looks like: > - > test test test > - > > How do I convert the result to HTML code, I especially want the linebreaks!! > > The answer is probably very simple > > /Kris > > > > -- > 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] Name of Include File breaking a Function - Strange!
On Fri, Aug 09, 2002 at 01:59:09PM -0400, Monty wrote: > > function user_acess() { > if ( isset($_SESSION['valid_user']) ) { > return 1; > } > return 0; > } > > Most of the time it returns 0 (zero) even though I know the session variable > is set. However, if I rename the functions.inc.php file to functions.php and > make NO changes at all to the code, it suddenly works!? Perhaps, somewhere in your include path is another file named functions.inc.php? Perhpas another file you're mistakenly including has a function already named user_acess()? In your test script, use the function_exists() function before you define the user_acess() function to see what's going on. --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Newbie question about SQL result formatting
Ok, this is totally newbie but I just started messing around with PHP after programming IBM's NetData for a while. My first big problem I haven't been able to solve myself is how to format the result of an SQL query into HTML code. In the (MySQL) database, I have one field for very long texts. One test entry looks like this: -- test test test -- But when printing the result, even with HTMLENTITIES and HTMLSPECIALCHARS, just looks like: - test test test - How do I convert the result to HTML code, I especially want the linebreaks!! The answer is probably very simple /Kris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Thumb nail of a web page
Hi All, Just out of interest, does anyone know of a way to generate a thumb nail of a web page given a URL? Henry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Can I perform a PHP script from a form but stay on the same page afterwards?
> -Original Message- > From: DonPro [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 5:34 PM > To: php list > Subject: [PHP] Can I perform a PHP script from a form but stay on the same > page afterwards? > > Hi, > > I have a form where the user can change a value ion a text box and then > click on a button which will update a table in a MySQL database. I assume > that the only way to do this is to have the button POST the form value to > my > script which updates the MySQL table. > > However, once updated (whether the update is successfull or not), I need > to > remain or return to the same page that the form is on. > > Can this easily be done? > > [Cesar Aracena] Sure. All you have to do is point the form's action to $PHP_SELF and the play a little with the *IF* and *ELSE IF* statements. > > -- > 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] Re: Getting information of a client
On Sat, 2002-08-10 at 01:38, radio x wrote: > how can i get a variable posted from a form by a user whitout having > register_globals set On? > $_POST["variable"] or $HTTP_POST_VARS["variable"] > Nick > > > - Original Message - > From: "Saci" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, August 09, 2002 1:08 PM > Subject: [PHP] Re: Getting information of a client > > > > > $mensagem = $mensagem."Remote_addr : ".$_SERVER['REMOTE_ADDR']."\n"; > > $mensagem = $mensagem."Remote_host : ".$_SERVER['REMOTE_HOST']."\n"; > > $mensagem = $mensagem."Remote_agent : ".$_SERVER['HTTP_USER_AGENT']."\n"; > > $mensagem = $mensagem."Host : ".$_SERVER['HTTP_HOST']."\n"; > > echo $mensagem; > > ?> > > > > > > > > "Jan Souman" <[EMAIL PROTECTED]> escreveu na mensagem > > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > > I would like to get information of a person who is browsing my site. > Does > > > anyone know how to get this information? > > > > > > Kind regards, > > > > > > Jan > > > > > > > > > > > > > > -- > > 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 > -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED] US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Re: Getting information of a client
how can i get a variable posted from a form by a user whitout having register_globals set On? Nick - Original Message - From: "Saci" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 1:08 PM Subject: [PHP] Re: Getting information of a client > $mensagem = $mensagem."Remote_addr : ".$_SERVER['REMOTE_ADDR']."\n"; > $mensagem = $mensagem."Remote_host : ".$_SERVER['REMOTE_HOST']."\n"; > $mensagem = $mensagem."Remote_agent : ".$_SERVER['HTTP_USER_AGENT']."\n"; > $mensagem = $mensagem."Host : ".$_SERVER['HTTP_HOST']."\n"; > echo $mensagem; > ?> > > > > "Jan Souman" <[EMAIL PROTECTED]> escreveu na mensagem > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > I would like to get information of a person who is browsing my site. Does > > anyone know how to get this information? > > > > Kind regards, > > > > Jan > > > > > > > > -- > 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] Can I perform a PHP script from a form but stay on the same page afterwards?
Hi, I have a form where the user can change a value ion a text box and then click on a button which will update a table in a MySQL database. I assume that the only way to do this is to have the button POST the form value to my script which updates the MySQL table. However, once updated (whether the update is successfull or not), I need to remain or return to the same page that the form is on. Can this easily be done? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Advogato metric
Has anyone written or seen the Advogato.org trust metric implemented in PHP? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] security concern with curl
Hi everybody, I am planing to install oasis a management tool for ads. This software requires to install curl http://curl.haxx.se/ My concern is that this would open a serious security whole on my server. Curl is stating out that: Curl is a command line tool for transferring files with URL syntax, supporting FTP, FTPS, HTTP, HTTPS, GOPHER, TELNET, DICT, FILE and LDAP. Curl supports HTTPS certificates, HTTP POST, HTTP PUT, FTP uploading, kerberos, HTTP form based upload, proxies, cookies, user+password authentication, file transfer resume, http proxy tunneling and a busload of other useful tricks. So I fear that someone would be able to tranfer files on / off my server. Has anybody some experiance on that, or can give a comment on that? Thanx for any hint, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Getting information of a client
"Jan Souman" <[EMAIL PROTECTED]> escreveu na mensagem [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I would like to get information of a person who is browsing my site. Does > anyone know how to get this information? > > Kind regards, > > Jan > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] storing errors from shell_exec command
I need to redirect the output from the shell_exec return variable to a file. What I have below is not working. What I need to get from the shell_exec is ant errors that happen and then I what to store those errors in a error file $output=shell_exec($cmd); $cmd ="`$output > /usr/autoserv/errlog`"; exec($cmd); -- Best regards, rdkurth mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] I'm going to shoot myself
You may have some extra, or missing some, quotes in the TEXTFIELD-SQL. Try echoing the string coming from the text field. Also, use mysql_error() to see what errors mysql is reporting. -j =P e p i e D e s i g n s www.pepiedesigns.com Providing Solutions That Increase Productivity Web Developement. Database. Hosting. Multimedia. On Fri, 9 Aug 2002, Liam Gibbs wrote: > < properly in a mysql_query command, but will run > properly when I put the *exact same* statement into a > textbox that inputs into a mysql_query command?>> > > UBF. Sorry for the false alarm, guys. I'm gonna go > under a rock now. Thanks anyway, Rasmus. Your > suggestion helps me for the future, anyway. > > > __ > Do You Yahoo!? > HotJobs - Search Thousands of New Jobs > http://www.hotjobs.com > > -- > 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] What the heck is this Zope?
My two cents: I used Zope a while back for a university project, and I've been using PHP for the best part of a year. Zope is very similar to PHP, but Zope is better suited for the novice web designer / developer. Zope makes it easy to interact with databases and allows you to iterate through a result set using HTML-like tags (DTML) like: Simple web application require very little or no programming. It also allows you to edit the (HTML) source via a web browser, which (too some) is an attractive feature. Zope is good for silly little DB apps, and coding in Python is easy (although the syntax is probably a LOT different to anything you've used before). AFAIK, it can do everything that PHP can, but I believe that PHP is faster & it's definitely more widely used and has a bigger user base. Lee recommends PHP any day. - Lee -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] can i use --with-unixODBC instead of --with-ibm-db2?
Doug, can you log in via plain db2 in linux (sorry if you said you could, I didnt read that far back). Heres what I do: * [root@somelinuxbox /root]# su - db2inst1 [db2inst1@somelinuxbox db2inst1]$ /usr/IBMdb2/V7.1/bin/db2 (c) Copyright IBM Corporation 1993,2001 Command Line Processor for DB2 SDK 7.2.0 You can issue database manager commands and SQL statements from the command prompt. For example: db2 => connect to sample db2 => bind sample.bnd For general help, type: ?. For command help, type: ? command, where command can be the first few keywords of a database manager command. For example: ? CATALOG DATABASE for help on the CATALOG DATABASE command ? CATALOG for help on all of the CATALOG commands. To exit db2 interactive mode, type QUIT at the command prompt. Outside interactive mode, all commands must be prefixed with 'db2'. To list the current command option settings, type LIST COMMAND OPTIONS. For more detailed help, refer to the Online Reference Manual. db2 => CONNECT TO MYDB2DB user MICHAEL Enter current password for MICHAEL: Database Connection Information Database server= OS/400 4.4.0 SQL authorization ID = MICHAEL Local database alias = CMSFIL db2 => ** Names changed to protect my network!:) Can you do that? Thanks Dan -Original Message- From: Doug Smith [mailto:[EMAIL PROTECTED]] Sent: Friday, August 09, 2002 7:02 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] can i use --with-unixODBC instead of --with-ibm-db2? Matt, I wish you were my boss :) I love MySQL and would want to use it instead of db2 (seeing i could probably have had it working with php last week ;) ) but Somehow my boss loves to waste money on IBM products... and then hires on people who don't know how to use them well (i.e. me!). My philosophy is: don't waste money on it, if you can use some open source -- for example he wanted to use IBM WAS (websphere application server) but, PHP will do everything we need to do, and is a lot easier to deal with than the bulky WAS. Anyways. I had seen the IBM document that you referenced about connecting DB2 to PHP, in fact, it's the main document i used to start attempting to get PHP to work with DB2. The second doc you referenced from phpbuilder.net was definately a good find -- had a couple ideas that i hadn't tried (i.e. catalogging the db, running apache as db2inst1 [still trying to get that to work, db2inst1 doesn't have the priviledges that root has, and henceforth can't access all the files needed by apache]) Matt, thanks again for all your help! -Doug "Matt" <[EMAIL PROTECTED]> wrote in message 047001c23f46$f7707c40$[EMAIL PROTECTED]">news:047001c23f46$f7707c40$[EMAIL PROTECTED]... > It seems way too difficult to configure db2 on linux. Let alone trying to do > it on freebsd, which I hope to tackle that next week. > > I tell you though, I really love mysql, it's so easy to use, and configure. > mysql just works. mysql's performance on a table I have that has roughly > 250,000 rows of address entries, beats our as/400 with db2 by orders of > magnitude and mytest box is a Celeron 300. > > Anyway, this is where I found the solution to the gibberish line that I put > in my doc (see step 3) : > http://www7b.boulder.ibm.com/dmdd/library/techarticle/scott/0614_scott.html > > You may find this of help: > http://www.phpbuilder.com/mail/php-db/2001011/0076.php > > Oh, did you call your instance db2inst1? > > -- 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: extra calls to pcDataHandler method
I figured it out. Turns out that my "pretty" structure of XML formating within the xml file shot me. everytime i indented a new tag i intoduced a \tab character, and apparently everything not within any tag is also #PCDATA?! i never seen this mentioned anywhere. oh well; i am just posting an answer in case smone else down the road encounters that same problem. alex Alex Maslov wrote: > Hi, > > i have a question about how PHP XML support works, in particular how > handler methods are called. > > if i have element-only tag, like: > > foo > usa > > > and i invoke xml parser on this, should my registered pcDataHandler > method be called when tag is being parsed, or parser is "smart" > enough not too, becasue their is no #PCDATA in the tag? > > I have smth like that going on, my pcDataHandler function is beeing > called 2 times too many, and on every single tag(even the one's with no > #PCDATA in them). > > I have a feeling a have a gross mistake smwhere, but i can't find it. > please help. and sorry for longwinded message. > > this is the snap-shot of my XML data file: > updated="213237827347"> > General Information > > Janine > Nadia > Mohammed > [EMAIL PROTECTED] > > ... > > > and this is the correcponding DTD shiplet: > > > publish (true|false) "true" > release_host_info (true|false) "false" > updated CDATA #REQUIRED > > > > email)> > > id ID #REQUIRED > publish_poster_info (yes|no|anonymous) > "yes" > post_date CDATA #REQUIRED > > > last_name, email)> > > > posted CDATA #REQUIRED > > > > this is the sniplet of debug output (code follows): > > before assigment currentTag = section_name - after assigment currentTag > = host > pcdata = > pcdata = > before assigment currentTag = host - after assigment currentTag = > first_name > pcdata = Janine > end of tag = first_name > pcdata = > pcdata = > before assigment currentTag = first_name - after assigment currentTag = > middle_name > pcdata = Nadia > end of tag = middle_name > pcdata = > pcdata = > before assigment currentTag = middle_name - after assigment currentTag = > last_name > pcdata = Mohammed > end of tag = last_name > pcdata = > pcdata = > before assigment currentTag = last_name - after assigment currentTag = > email > pcdata = [EMAIL PROTECTED] > end of tag = email > pcdata = > pcdata = > end of tag = host > pcdata = > pcdata = > pcdata = > ... > > the parser code: > > class faqHandler { > > var $parser;//xml parser > var $file; > var $currentTag; > > var $ATTRIBS = array(); > var $FAQ_HEAD = array(); > > function faqHandler($file="faq.xml", $fold="false") { > $this->file = $file; > > $this->parser = xml_parser_create(); > //xml_set_object($this->parser, &$this); > xml_parser_set_option($this->parser, XML_OPTION_CASE_FOLDING, $fold); > xml_set_element_handler($this->parser, "startTagHandler", > "endTagHandler"); > xml_set_character_data_handler($this->parser, "pcDataHandler"); > } > > function parseNow() { > xml_set_object($this->parser, &$this); > > if ( ! ($fd = fopen($this->file, "r")) ) { >die(sprintf("Could not open xml file %s", $this->file)); > } > > while ( ($rawxml = fread($fd, 4096)) ) { >if ( !(xml_parse($this->parser, $rawxml, feof($fd))) ) { > die(sprintf("XML error in file > %s at line%d possition %d", > $this->file, > xml_get_current_line_number($this->parser), > xml_get_current_column_number($this->parser) )); >}//eo if > }//ei while > } > > function clean() { > xml_parser_free($this->parser); > } > > function getTagContent($tag_name) { > > } > > function startTagHandler($parser, $name, $attrib) { > echo("before assigment currentTag = $this->currentTag - "); > $this->currentTag = $name; > echo("after assigment currentTag = $this->currentTag "); > > switch(strtolower($name)) { >case "faq" : { > $this->ATTRIBS["faq_version"] = $attrib["version"]; > $this->ATTRIBS["faq_revised"] = $attrib["revised"]; > break; >} >case "faq_head" : { > break; >} >case "zip" : { > $this->ATTRIBS["zip_location"] = $attrib["location"]; > break; >} >case "phone" : { > $this->ATTRIBS["fone_area"] = $attrib["area"]; > $this->ATTRIBS
[PHP] special characters
Is there a way to have PHP to either: a) strip out any non-standard ascii characters (like the TM or copyright symbol) b) have PHP encode all these symbols. I know about htmlentities, but it not catch everything. Thanks!
[PHP] Re: compile PHP --with-imap, on OS X: progress, but...
Hi Michael: Í have done this on suse72 and after a while I did get it running. The problem was that I did forget to move the 3 directories to their spot as described in the docu. You have also to change some lines in another file which I do not know if this is available on X (cant remember the name though, but I guess you know which file I mean) Good luck, Andy -- -- http://www.globosapiens.net Global Travellers Network! http://www.ozforum.info Discussing Australia Forum "Michael Geary" <[EMAIL PROTECTED]> schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi folks, > > I am desperately trying to get PHP (4.2.2) --with-imap running on OS X, > so I can run the IMP web-mail client. I already have IMAP installed, and > have downloaded and compiled the U-W c-client. I have also followed the > directions on the PHP.NET website under IMAP. > > Here is my PHP configure line: > > ./configure --prefix=/mg --with-apxs=/mg/sbin/apxs \ > --with-config-file-path=/mg/etc --with-gettext=/sw \ > --with-xml --enable-ftp --with-imap=/usr/local/src/imap-2002.RC2 \ > --with-imap-ssl > > I can configure PHP just fine, that is, I don't get any errors. However, > when I run "make", I get a message: > > *** Warning: This library needs some functionality provided by > -lc-client. > *** I have the capability to make that library automatically link in when > *** you link to this library. But I can only do this if you have a > *** shared version of the library, which you do not appear to have. > *** The inter-library dependencies that have been dropped here will be > *** automatically added whenever a program is linked with this library > *** or is declared to -dlopen it. > > I do still get a libphp4.dylib file, but when I rename this to > libphp4.so and place it in the appropriate apache directory, i get the > following error from apache: > > Syntax error on line 239 of /mg/etc/httpd.conf: > Cannot load /mg/libexec/httpd/libphp4.so into server: (reason unknown) > > on line 239 of httpd.conf I have: > > LoadModule php4_module libexec/httpd/libphp4.so > > Can anyone make any sense of this? I would really appreciate some help. > > regards, > > michael geary > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] session.save_path problem again
Hi, I'm sorry, I know this is a commonly asked question, but I've checked every suggestion offered here and in other groups/lists. Yet, I still get "Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp/php)" I have save_path set to "/tmp/php" in php.ini. This directory exists and is owner/group/world writable. There is even a single session file already present in the directory (I suspect it was created when I tried turning on session.auto_start; unfortunately postnuke didn't want to work with that setting on). I'm running PHP 4.1.2/Apache 1.3.26 on MacOSX 10.1.5 Server. Any thoughts? Thanks Dmitry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Environment Variables
My guess is that you should look into your server's configuration, to see if it recognizes index.php as a valid main page. Maybe it's configured (standard) to detect index.htm / index.html as valid main pages. HTH, C. > -Original Message- > From: Robert Morse [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 2:52 PM > To: [EMAIL PROTECTED] > Subject: [PHP] Environment Variables > > > Hello. > > I have run into a weird problem with php. I have a very > short php script that will print out a particular environment > variable. Here is the contents of an index.php file: > > Test > > LOOK -- > > > Now, when I go to http://server/index.php, it prints > out my variable as I want. > > LOOK -- MY Test Variable > > > But, when I just go to http://server/ (and I have index.php > as a directory index in the apache server config file) > the variable isn't set and all I get is: > > LOOK -- > > Anybody have any ideas what may be causing this behavior? > > Thanks in advance. > > -- > Bob Morse > Senior Systems Programmer > Brown University > > -- > 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] Passing hidden form var?
I think I am just over looking something here, a new pair of eyes would be useful. Thanks in advance. The var $ipaddy is not getting passed to code listed below /* Form for IP checking */ $table = "cm_sessions"; $record = @mysql_query("SELECT * FROM $table",$dbh); while ($row = mysql_fetch_array($record)) { $session = $row['session']; $ipaddy = $row['ipaddy']; $host = $row['host']; $referrer = $row['referrer']; $hck = $row['hck']; $nrml = $row['nrml']; $hour = $row['hour']; $date_stamp = $row['date_stamp']; $stats .= "$session $ipaddy $host $hck $nrml $date_stamp https://localhost/admin/view.whois.php') \" name=\"whois\"> "; } /* Function to check IP vs. Whois db */ $ipaddy = ""; function message($msg){ echo "$msg"; flush(); } function arin($ipaddy){ $server = "whois.arin.net"; if (!$ipaddy = gethostbyname($ipaddy)) $msg .= "Can't check Whois without an IP address."; else{ if (! $sock = fsockopen($server, 43, &$num, &$error, 20)){ unset($sock); $msg .= "Timed-out connecting to $server (port 43)"; } else{ fputs($sock, "$ipaddy\n"); while (!feof($sock)) $buffer .= fgets($sock, 10240); fclose($sock); } if (eregi("RIPE.NET", $buffer)) $nextServer = "whois.ripe.net"; else if (eregi("whois.apnic.net", $buffer)) $nextServer = "whois.apnic.net"; else if (eregi("nic.ad.jp", $buffer)){ $nextServer = "whois.nic.ad.jp"; #/e suppresses Japanese character output from JPNIC $extra = "/e"; } else if (eregi("whois.registro.br", $buffer)) $nextServer = "whois.registro.br"; if($nextServer){ $buffer = ""; message("Deferred to specific whois server: $nextServer..."); if(! $sock = fsockopen($nextServer, 43, &$num, &$error, 10)){ unset($sock); $msg .= "Timed-out connecting to $nextServer (port 43)"; } else{ fputs($sock, "$ipaddy$extra\n"); while (!feof($sock)) $buffer .= fgets($sock, 10240); fclose($sock); } } $buffer = str_replace(" ", " ", $buffer); $msg .= nl2br($buffer); } message($msg); } echo arin($ipaddy); echo $ipaddy; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] compile PHP --with-imap, on OS X: progress, but...
Hi folks, I am desperately trying to get PHP (4.2.2) --with-imap running on OS X, so I can run the IMP web-mail client. I already have IMAP installed, and have downloaded and compiled the U-W c-client. I have also followed the directions on the PHP.NET website under IMAP. Here is my PHP configure line: ./configure --prefix=/mg --with-apxs=/mg/sbin/apxs \ --with-config-file-path=/mg/etc --with-gettext=/sw \ --with-xml --enable-ftp --with-imap=/usr/local/src/imap-2002.RC2 \ --with-imap-ssl I can configure PHP just fine, that is, I don't get any errors. However, when I run "make", I get a message: *** Warning: This library needs some functionality provided by -lc-client. *** I have the capability to make that library automatically link in when *** you link to this library. But I can only do this if you have a *** shared version of the library, which you do not appear to have. *** The inter-library dependencies that have been dropped here will be *** automatically added whenever a program is linked with this library *** or is declared to -dlopen it. I do still get a libphp4.dylib file, but when I rename this to libphp4.so and place it in the appropriate apache directory, i get the following error from apache: Syntax error on line 239 of /mg/etc/httpd.conf: Cannot load /mg/libexec/httpd/libphp4.so into server: (reason unknown) on line 239 of httpd.conf I have: LoadModule php4_module libexec/httpd/libphp4.so Can anyone make any sense of this? I would really appreciate some help. regards, michael geary -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] JSP vs. PHP?
[EMAIL PROTECTED] em Friday 09 August 2002 14:14 foi agraciado com uma resposta por: > but how many huge dot-coms wrote their sites in PHP? We did :-) A Linux/Apache/PHP/Mysql system that will run credit solicitations for financial institutions. Management of around 500 million dollars, yearly. But s, the people at the Evangelism mailing list are expecting details already ;-) -- Julio Nobrega http://gnet.inerciasensorial.com.br -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Environment Variables
Hello. I have run into a weird problem with php. I have a very short php script that will print out a particular environment variable. Here is the contents of an index.php file: Test LOOK -- Now, when I go to http://server/index.php, it prints out my variable as I want. LOOK -- MY Test Variable But, when I just go to http://server/ (and I have index.php as a directory index in the apache server config file) the variable isn't set and all I get is: LOOK -- Anybody have any ideas what may be causing this behavior? Thanks in advance. -- Bob Morse Senior Systems Programmer Brown University -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Please help with array_diff()
On Fri, Aug 09, 2002 at 07:50:46PM +0200, Gandalf wrote: > Well of course $foo[0] contains the first dimension of the $foo array and > the same goes for $bar[0]. > > It is still not working as it should, i am close to going nuts. If I understood you correctly, there is no element 0 in $foo and no element 0 in $bar, only name and email or whatever it was. The array array("name"=>"Gandalf", "email"=>"[EMAIL PROTECTED]") for instance has no 0 element. Or did I misunderstand you? When trying to understand how things work or asking for help it's good ti simplify the script as much as possible. Stig -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Name of Include File breaking a Function - Strange!
I have an include file named functions.inc.php that I include in nearly every script. For some bizarre reason, the following function inside this file does not always work: function user_acess() { if ( isset($_SESSION['valid_user']) ) { return 1; } return 0; } Most of the time it returns 0 (zero) even though I know the session variable is set. However, if I rename the functions.inc.php file to functions.php and make NO changes at all to the code, it suddenly works!? In fact, it seems that if I rename the include file to anything but functions.inc.php, the above function works as expected, returning 1 instead of 0. I tried functions2.inc.php, funct.inc.php ... they all worked. What the hell is going on here? How could the name of the include file affect whether or not a function inside it will work? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] $http_host use case
You re right i will make a if statement ... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Win PHP Editor...
Just have to add one little fine piece of free software that nobody's mentioned yet, Crimson Editor (http://www.crimsoneditor.com ) No code completion, but it's got every other feature of the big commercial beasts... definitely check it out - I just switched over, and it's great. >From the site: -- Edit multiple documents - switch between documents using file selection tab - pressing Ctrl+Tab brings the last accessed document to top Syntax highlighting - configurable via custom syntax files - preconfigured for more than 50 computer languages Multi-level undo / redo - all editing actions are recorded from the opening of a file - unlimited undo and redo buffers Find & Replace - replace specified text one by one, or as a whole - support regular expression Natural word wrapping - word wrapping does not affect syntax highlighting - configurable wrapping indentation (easer to understand the syntax) Spell checker - around 10 words were added in the dictionary - users can register new words in their own dictionary (InstallDir/user.dic) User tools and macros - execute external programs with proper arguments - compile, execute and test your code - ease your fingers with key stroke recording (record & replay) Directory tree view window - click to open documents - filter to display only selected file class Edit remote files directly using built-in FTP client - open, edit, and save documents in remote FTP servers - save account information (encoded) for automatic logon Print & Print preview - configurable page header and footer - print with line numbers - print with syntax highlighting (used in color printer) - true type font selection for printer Other useful features single instance / multiple instances, ability to detect changed files, bookmark & go to, highlight active line, highlight matching pairs, multi-byte support with integrated IME (for eastern languages), auto indent, wheel mouse support, copy & paste, line numbers, configurable line spacing, option to save files in Unix format, option to set working directory Very nice little IDE, and the price is right! Nothing! Dave -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Please help with array_diff()
Well of course $foo[0] contains the first dimension of the $foo array and the same goes for $bar[0]. It is still not working as it should, i am close to going nuts. At 11:43 09.08.2002 +0800, you wrote: >On Friday 09 August 2002 06:14, Gandalf wrote: > > > > > $diff = array_diff($foo[0], $bar[0]); > >What does $foo[0] and $bar[0] contain? > >-- >Jason Wong -> Gremlins Associates -> www.gremlins.com.hk >Open Source Software Systems Integrators >* Web Design & Hosting * Internet & Intranet Applications Development * > >/* >Remember that there is an outside world to see and enjoy. > -- Hans Liepmann >*/ > > >-- >PHP General Mailing List (http://www.php.net/) >To unsubscribe, visit: http://www.php.net/unsub.php Jürgen (aka. Frodo the scribe == Visit the MECCG Forums at http://www.coen.at.tf
RE: [PHP] Sending automatically mail
You're probably right. I tend to think like this 'cause I'm a guy with no access to my server at all. I just rent-a-server for all my hosting needs. C. > -Original Message- > From: Kondwani Spike Mkandawire [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 2:36 PM > To: [EMAIL PROTECTED] > Subject: Re: [PHP] Sending automatically mail > > > "Kondwani Spike Mkandawire" <[EMAIL PROTECTED]> wrote in message > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > > > "César aracena" <[EMAIL PROTECTED]> wrote in message > > 002101c23fcb$4e43c390$93c405c8@gateway">news:002101c23fcb$4e43c390$93c405c8@gateway... > > > I had a question like this once, and the most applicable answer I got > > > from this list was to make a script which triggers *IF* a certain time > > > of day was reached. The only problem is that it had to be triggered by > > > one visitor's clicking at least (the script was asleep in a page until > > > that page was called). > > > > > > Now, it comes to my mind that you could have one hidden page which > META > > > refresh tags (refreshing itself let's say every hour), with a script > > > inside that will trigger *IF* a certain hour (time) has passed. > > > > > > I hope this makes any sense, C. > > > > > > > -Original Message- > > > > From: Jan Souman [mailto:[EMAIL PROTECTED]] > > > > Sent: Friday, August 09, 2002 2:03 PM > > > > To: [EMAIL PROTECTED] > > > > Subject: [PHP] Sending automatically mail > > > > > > > > I would like my php-script to send a mail every day automatically, > > > without > > > > anyone opening my site. > > > > > > > > Is this possible and if yes can anyone tell how to do this? > > > > > > > > Kind regards, > > > > > > > > Jan > > I think exec() with Cron would also do the trick... Obviously this is > > under the assumption that you are under a UNIX-type platform... > sorry I meant shell_exec() > > > > -- > 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] Sending automatically mail
Well, if you compile a cgi version of php, just add a cronjob to run your script. When you automate these things though, especially if it's sending out e-mail, it's best to carefully setup error reporting to catch any script failures or faults -- you want them reported to you quickly and to kill the script gracefully. I learned the hard way with members our e-mail publication. Regards, Jeff Hill - Original Message - From: "César Aracena" <[EMAIL PROTECTED]> To: "'Jan Souman'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 1:36 PM Subject: RE: [PHP] Sending automatically mail > I had a question like this once, and the most applicable answer I got > from this list was to make a script which triggers *IF* a certain time > of day was reached. The only problem is that it had to be triggered by > one visitor's clicking at least (the script was asleep in a page until > that page was called). > > Now, it comes to my mind that you could have one hidden page which META > refresh tags (refreshing itself let's say every hour), with a script > inside that will trigger *IF* a certain hour (time) has passed. > > I hope this makes any sense, C. > > > -Original Message- > > From: Jan Souman [mailto:[EMAIL PROTECTED]] > > Sent: Friday, August 09, 2002 2:03 PM > > To: [EMAIL PROTECTED] > > Subject: [PHP] Sending automatically mail > > > > I would like my php-script to send a mail every day automatically, > without > > anyone opening my site. > > > > Is this possible and if yes can anyone tell how to do this? > > > > Kind regards, > > > > Jan > > > > > > > > -- > > 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
Re: [PHP] Sending automatically mail
"Kondwani Spike Mkandawire" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > "César aracena" <[EMAIL PROTECTED]> wrote in message > 002101c23fcb$4e43c390$93c405c8@gateway">news:002101c23fcb$4e43c390$93c405c8@gateway... > > I had a question like this once, and the most applicable answer I got > > from this list was to make a script which triggers *IF* a certain time > > of day was reached. The only problem is that it had to be triggered by > > one visitor's clicking at least (the script was asleep in a page until > > that page was called). > > > > Now, it comes to my mind that you could have one hidden page which META > > refresh tags (refreshing itself let's say every hour), with a script > > inside that will trigger *IF* a certain hour (time) has passed. > > > > I hope this makes any sense, C. > > > > > -Original Message- > > > From: Jan Souman [mailto:[EMAIL PROTECTED]] > > > Sent: Friday, August 09, 2002 2:03 PM > > > To: [EMAIL PROTECTED] > > > Subject: [PHP] Sending automatically mail > > > > > > I would like my php-script to send a mail every day automatically, > > without > > > anyone opening my site. > > > > > > Is this possible and if yes can anyone tell how to do this? > > > > > > Kind regards, > > > > > > Jan > I think exec() with Cron would also do the trick... Obviously this is > under the assumption that you are under a UNIX-type platform... sorry I meant shell_exec() -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Re: Linux PHP editor
You might want to check the archives. This topic has been discussed exhaustively many times... To name a very small few: HTML-Kit Zend IDE HomeSite Dreamweaver jEdit ... and many, many more. -- Aaron Gould [EMAIL PROTECTED] Web Developer - Original Message - From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 12:52 PM Subject: Re: [PHP] Re: Linux PHP editor > Is there a php editor for Win2k ? > > Negrea Mihai wrote: > > > try nedit from nedit.org > > you can download the patterns from the site to do php syntax highlight.. > > > > I have combined it with cervisia from kde 3 and made it look smth like an IDE > > :) .. and I've been working 4-6 hours per day for about half an year with it > > with no problems. > > > > I also have tried Quanta but it is too huge for nothing... but if you need > > syntax completion maybe you should take a look at it. > > > > Good luck in your open source trip ;) > > > > -- > > Negrea Mihai > > web: http://www.negrea.net > > > > On Friday 09 August 2002 02:11 pm, [EMAIL PROTECTED] wrote: > > > JJ Harrison\ writes: > > > > I just switched over to Red Hat Linux from Win2k... > > > > > > > > Only to find my fav editor only works on windows systems... > > > > > > > > could someone suggest a good replacement? > > > > > > > > > > > > -- > > > > JJ Harrison > > > > [EMAIL PROTECTED] > > > > www.tececo.com > > > > > > > > > > > > > > > > -- > > > > PHP General Mailing List (http://www.php.net/) > > > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > > > simply vi or vim of pico :) > > > > -- > > 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
Re: [PHP] Sending automatically mail
"César aracena" <[EMAIL PROTECTED]> wrote in message 002101c23fcb$4e43c390$93c405c8@gateway">news:002101c23fcb$4e43c390$93c405c8@gateway... > I had a question like this once, and the most applicable answer I got > from this list was to make a script which triggers *IF* a certain time > of day was reached. The only problem is that it had to be triggered by > one visitor's clicking at least (the script was asleep in a page until > that page was called). > > Now, it comes to my mind that you could have one hidden page which META > refresh tags (refreshing itself let's say every hour), with a script > inside that will trigger *IF* a certain hour (time) has passed. > > I hope this makes any sense, C. > > > -Original Message- > > From: Jan Souman [mailto:[EMAIL PROTECTED]] > > Sent: Friday, August 09, 2002 2:03 PM > > To: [EMAIL PROTECTED] > > Subject: [PHP] Sending automatically mail > > > > I would like my php-script to send a mail every day automatically, > without > > anyone opening my site. > > > > Is this possible and if yes can anyone tell how to do this? > > > > Kind regards, > > > > Jan I think exec() with Cron would also do the trick... Obviously this is under the assumption that you are under a UNIX-type platform... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Re: Linux PHP editor
Yep. Theres several for windows. I've used: -PHP4EE -Homesite -Dreamweaver (MX version finally has syntax highlighting) -Good old notepad -PHP Coder Pro (What PHP4EE was based on) Jason Reid [EMAIL PROTECTED] -- AC Host Canada www.achost.ca - Original Message - From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 10:52 AM Subject: Re: [PHP] Re: Linux PHP editor > Is there a php editor for Win2k ? > > Negrea Mihai wrote: > > > try nedit from nedit.org > > you can download the patterns from the site to do php syntax highlight.. > > > > I have combined it with cervisia from kde 3 and made it look smth like an IDE > > :) .. and I've been working 4-6 hours per day for about half an year with it > > with no problems. > > > > I also have tried Quanta but it is too huge for nothing... but if you need > > syntax completion maybe you should take a look at it. > > > > Good luck in your open source trip ;) > > > > -- > > Negrea Mihai > > web: http://www.negrea.net > > > > On Friday 09 August 2002 02:11 pm, [EMAIL PROTECTED] wrote: > > > JJ Harrison\ writes: > > > > I just switched over to Red Hat Linux from Win2k... > > > > > > > > Only to find my fav editor only works on windows systems... > > > > > > > > could someone suggest a good replacement? > > > > > > > > > > > > -- > > > > JJ Harrison > > > > [EMAIL PROTECTED] > > > > www.tececo.com > > > > > > > > > > > > > > > > -- > > > > PHP General Mailing List (http://www.php.net/) > > > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > > > simply vi or vim of pico :) > > > > -- > > 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
RE: [PHP] Sending automatically mail
I had a question like this once, and the most applicable answer I got from this list was to make a script which triggers *IF* a certain time of day was reached. The only problem is that it had to be triggered by one visitor's clicking at least (the script was asleep in a page until that page was called). Now, it comes to my mind that you could have one hidden page which META refresh tags (refreshing itself let's say every hour), with a script inside that will trigger *IF* a certain hour (time) has passed. I hope this makes any sense, C. > -Original Message- > From: Jan Souman [mailto:[EMAIL PROTECTED]] > Sent: Friday, August 09, 2002 2:03 PM > To: [EMAIL PROTECTED] > Subject: [PHP] Sending automatically mail > > I would like my php-script to send a mail every day automatically, without > anyone opening my site. > > Is this possible and if yes can anyone tell how to do this? > > Kind regards, > > Jan > > > > -- > 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] Checking Var's passed via URL
Thank you for your reply Believe or not the code today works , without any change. I guess is somethhhing related to browser cache., who probably was holding one old version. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] I'm going to shoot myself
<> UBF. Sorry for the false alarm, guys. I'm gonna go under a rock now. Thanks anyway, Rasmus. Your suggestion helps me for the future, anyway. __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] funtion exporter; static inclusion of external scripts
Does anyone know of any tools for php that will let you include only certain functions from a file. For example if I only wanted a function named "login" from a file named "func_common.php", I could maybe do something like this: my_require('path/to/func_common.php', 'login'); I was thinking of writing a script that would offer an api to let you include only certain parts of a file, or maybe you'd could use "*" in conjunction with a directory name to include all the files in a directory. What I have in mind is building a new static version of the "main" script with the "included" code being a part of the main script. I guess if you're scripts are being cached then the disk reads that including files requires isn't that big of a deal. But it could probably make a big difference on sites where people aren't caching their php scripts. Let me know if anything like this exists. tia, --ed __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] JPgraph: Autoscaling [OT perhaps]
Anybody out there using JpGraph? I directed the following question to the support web site, but as yet... there's been no reply: Could somebody tell me how to disable the autoscaling in JpGraph, and/or how to provide my own scaling? It's perfect for 99% of the graphs and plots I create, but when I plot some data in a linearXlogY scale it's surrounded by way too much white space. Particularly, I've noticed that the logY scale always seems to go from 10,000 to 100,000 for my data sets when the Y range is only from 20k to 10k. E.g. Say I had 2 data points : 1,5 and 5,1 +The graph may show a grid e.g. 10 x 10 + How can I set it so that it only pads a few pixels, or say display 0,0 up to 6,6? Does this make sense? Hope someone can help! While I'm on the topic, does JpGraph support Sub/SuperScript text? Nothing about it in the documentation, but I need to display N^2 (N squared) and stuff like that. Thanks in advance, Lee PS: JpGraph is an awesome little library ;-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] JSP vs. PHP?
You are mixing up some things here. JSP is server-side Java, applets are client-side. The two have very little to do with each other. You can use PHP and still send a Java applet to the browser, for example. But if you are asking if doing client-side graphics with a java applet is faster or slower than doing server-side graphics with PHP, then I'd say the PHP version is likely yo always be faster as there is no applet loading overhead, and additionally one must assume that your web server machine is beefier than the client machines out there. But you are really comparing very different things here. -Rasmus On Fri, 9 Aug 2002, Kondwani Spike Mkandawire wrote: > I'm still into PHP like crazy... But I have been told JSP > is more powerful how true is this? > >From what I've read so far (tutorials and all), the syntax is > 100% similar to Java i.e. it is basically Java with additional > library functions... > > Now here's the story: I am yet to use PHP with a Graphics > library (The GD extensions I believe they are), so I don't > know about their performace... However the last time > I wrote a decently large Java Applet, the browser took > annoyingly long to load the applet... If the same principle > applies of having a JVM or a Java Interpreter embedded > in the browser then I see no advantage to JSP apart from > the point of protability... (Unless the graphic libraries that > support PHP are any slower)... Could someone please > comment... > > Spike... > > > > -- > 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] Sending automatically mail
I would like my php-script to send a mail every day automatically, without anyone opening my site. Is this possible and if yes can anyone tell how to do this? Kind regards, Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] JSP vs. PHP?
I'm not a JSP programmer so don't quote me but... A) The syntax isn't really that similar to Java. In Java, EVERYTHING is an object. You could write PHP like that if you wanted to but most people don't, especially those who are working with MySQL, for example. PHP is really a cross between C and Perl, syntax-wise. B) Yeah, you'd find JSP's to be faster. You misunderstand what they are. JSP stands for "java server pages" and they are processed server-side like PHP. No Java is interpreted by the browser. PHP is better suited for smaller applications and/or inexperienced programmers - not to say that it isn't powerful, but how many huge dot-coms wrote their sites in PHP? -Original Message- From: Kondwani Spike Mkandawire [mailto:[EMAIL PROTECTED]] Sent: Friday, August 09, 2002 1:00 PM To: [EMAIL PROTECTED] Subject: [PHP] JSP vs. PHP? I'm still into PHP like crazy... But I have been told JSP is more powerful how true is this? >From what I've read so far (tutorials and all), the syntax is 100% similar to Java i.e. it is basically Java with additional library functions... Now here's the story: I am yet to use PHP with a Graphics library (The GD extensions I believe they are), so I don't know about their performace... However the last time I wrote a decently large Java Applet, the browser took annoyingly long to load the applet... If the same principle applies of having a JVM or a Java Interpreter embedded in the browser then I see no advantage to JSP apart from the point of protability... (Unless the graphic libraries that support PHP are any slower)... Could someone please comment... Spike... -- 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] Getting information of a client
I would like to get information of a person who is browsing my site. Does anyone know how to get this information? Kind regards, Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] extra calls to pcDataHandler method
Hi, i have a question about how PHP XML support works, in particular how handler methods are called. if i have element-only tag, like: foo usa and i invoke xml parser on this, should my registered pcDataHandler method be called when tag is being parsed, or parser is "smart" enough not too, becasue their is no #PCDATA in the tag? I have smth like that going on, my pcDataHandler function is beeing called 2 times too many, and on every single tag(even the one's with no #PCDATA in them). I have a feeling a have a gross mistake smwhere, but i can't find it. please help. and sorry for longwinded message. this is the snap-shot of my XML data file: General Information Janine Nadia Mohammed [EMAIL PROTECTED] ... and this is the correcponding DTD shiplet: this is the sniplet of debug output (code follows): before assigment currentTag = section_name - after assigment currentTag = host pcdata = pcdata = before assigment currentTag = host - after assigment currentTag = first_name pcdata = Janine end of tag = first_name pcdata = pcdata = before assigment currentTag = first_name - after assigment currentTag = middle_name pcdata = Nadia end of tag = middle_name pcdata = pcdata = before assigment currentTag = middle_name - after assigment currentTag = last_name pcdata = Mohammed end of tag = last_name pcdata = pcdata = before assigment currentTag = last_name - after assigment currentTag = email pcdata = [EMAIL PROTECTED] end of tag = email pcdata = pcdata = end of tag = host pcdata = pcdata = pcdata = ... the parser code: file = $file; $this->parser = xml_parser_create(); //xml_set_object($this->parser, &$this); xml_parser_set_option($this->parser, XML_OPTION_CASE_FOLDING, $fold); xml_set_element_handler($this->parser, "startTagHandler", "endTagHandler"); xml_set_character_data_handler($this->parser, "pcDataHandler"); } function parseNow() { xml_set_object($this->parser, &$this); if ( ! ($fd = fopen($this->file, "r")) ) { die(sprintf("Could not open xml file %s", $this->file)); } while ( ($rawxml = fread($fd, 4096)) ) { if ( !(xml_parse($this->parser, $rawxml, feof($fd))) ) { die(sprintf("XML error in file %s at line%d possition %d", $this->file, xml_get_current_line_number($this->parser), xml_get_current_column_number($this->parser) )); }//eo if }//ei while } function clean() { xml_parser_free($this->parser); } function getTagContent($tag_name) { } function startTagHandler($parser, $name, $attrib) { echo("before assigment currentTag = $this->currentTag - "); $this->currentTag = $name; echo("after assigment currentTag = $this->currentTag "); switch(strtolower($name)) { case "faq" : { $this->ATTRIBS["faq_version"] = $attrib["version"]; $this->ATTRIBS["faq_revised"] = $attrib["revised"]; break; } case "faq_head" : { break; } case "zip" : { $this->ATTRIBS["zip_location"] = $attrib["location"]; break; } case "phone" : { $this->ATTRIBS["fone_area"] = $attrib["area"]; $this->ATTRIBS["fone_ext"] = $attrib["ext"]; break; } case "fax" : { $this->ATTRIBS["fax_area"] = $attrib["area"]; $this->ATTRIBS["fax_ext"] = $attrib["ext"]; break; } }//eo switch } function pcDataHandler($parser, $pcdata) { echo("pcdata = $pcdata "); //echo("inside pcDataHandler: currentTag = $this->currentTag && pcData = $pcdata "); //echo("current errorString value = " . xml_error_string(xml_get_error_code($this->parser)) ."" ); switch(strtolower($this->currentTag)) { case "firm_name" : { $this->FAQ_HEAD["firm_name"] = $pcdata; //echo("pcdata = $pcdata"); break; } case "firm_location" : { $this->FAQ_HEAD["firm_location"] = $pcdata; break; } }//eo switch } function endTagHandler($parser, $name) { echo("end of tag = $name "); } function cleanVars() { } function printFaqHeader() { echo(""); echo($this->FAQ_HEAD["firm_name"]); echo("did u get it?"); echo(""); echo($this->ATTRIBS["faq_version"]); echo(""); echo($this->ATTRIBS["faq_revised"]); echo(""); echo($this->ATTRIBS["zip_location"]); echo(""); echo($this->ATTRIBS["fone_area"]); echo(""); echo($this->ATTRIBS["fone_ext"]); echo(""); echo($this->ATTRIBS["fax_area"]); echo(""); echo($this->ATTRIBS["fax_ext"]); } }//eo class faqHandler ?> the faq.php code which intantiates the parser and calls the print method: parseNow(); // $f
Re: [PHP] Re: Linux PHP editor
I'm sure you can also use vim or jedit or Zend's mentioned earlier. Or, visit this site for more: http://php.weblogs.com/editors - E > >Is there a php editor for Win2k ? > _ $B%&%#%k%9%a!<%k!"LBOG%a!<%kBP:v$J$i(B MSN Hotmail http://www.hotmail.com/JA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Pictures and sound in MySQL and access via PHP
hi, I already posted this message but the time on my computer was wrong (26/07 so i post it again). I am new on MySQL and PHP. I'm making a on-line dictionary. I use PHP and a MySQL Database. Now I want to add audio-streaming (MP3) and pictures (JPG) to the database and retrieve it true PHP. Can sombody help me out with a little example-code? The database is working well (only text). Danny -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Submitting Form in E-mail to Server Fails
Submitting a form that is within the body of an e-mail message fails when I use the 'post' method, although it works if I use 'get'. With the post method, it will open up a web browser, but the receiving form's headers show no data, no array, submitted. I thought at first it was a conflict with submitting it to an https php page, but I've tried switching it to unencrypted with the same result. I've been searching the php archives and google for a day and a half without any positive leads (but I know I've seen forms within e-mail messages and it's one of the few valid reasons for using html in e-mail). It seems as if it should be a simple html encoded page, but nothing seems to work when I switch it to post method. I've set up a simple test form to use within my HTML e-mail message that is output by php to qmail-inject to our members: echo . . . . . "http://www.hronline.com/test.php\";>\n" . "\n" . "\n" ."\n" . . . . ; I've tried specifying various media types with encType but no luck. My test.php form is just a simple effort at seeing anything that comes through (picked up from a past php contributor): Any suggestions appreciated. I'm running PHP4.1.2 as a cgi and as an Apache 1.3.23 module, mod_ssl 2.8.7, OpenSSL0.9.6c on a Debian server with kernel 2.4.17. I'm using the php.ini configuration file unmodified from the distribution, except for some MySQL setting changes. I've tested using Outlook Express and Eudora with IE 6.0 and Netscape 6.1 on a Windows XP machine. I appreciate that this is probably not a real issue with php directly, but I'm using php to output the form and to recieve the results back, so I thought this should be an acceptable question for the list. Thanks for any direction and a really wonderful PHP. I'm amazed at how it's grown over the years. Jeff Hill -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] JSP vs. PHP?
I'm still into PHP like crazy... But I have been told JSP is more powerful how true is this? >From what I've read so far (tutorials and all), the syntax is 100% similar to Java i.e. it is basically Java with additional library functions... Now here's the story: I am yet to use PHP with a Graphics library (The GD extensions I believe they are), so I don't know about their performace... However the last time I wrote a decently large Java Applet, the browser took annoyingly long to load the applet... If the same principle applies of having a JVM or a Java Interpreter embedded in the browser then I see no advantage to JSP apart from the point of protability... (Unless the graphic libraries that support PHP are any slower)... Could someone please comment... Spike... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PHP: problem with patterns
Hi Alia: On Fri, Aug 09, 2002 at 02:50:32PM +0300, Alia Mikati wrote: > > I have to parse an html file and replace > src attribute of an img. I'm using 'preg_match_all' First off, if you're doing a search and replace, use preg_replace(). > having problem with patterns. This is the part of code that should find > the appropriate img src: > > $preg='//si'; The "|" OR operator is not for use in "[]" character range blocks. > where $original contains the value of src that it should find. For expl, > $original can be: ../../MyMCMSSite/images/pic1_abeoway.gif. > > But the problem is it's not catching the right img src. I don't know why it's not working for you. A slightly tweaked version of that works for me... Do note, you weren't escaping the periods in your addcslashes() call. end'; echo htmlspecialchars($document); $original = '../../MyMCMSSite/images/pic1_abeoway.gif'; $original = addcslashes($original, '/.'); $preg = '//si'; echo ''; echo htmlspecialchars($preg); $document = preg_replace($preg, ' REPLACED ', $document); echo ''; echo htmlspecialchars($document); ?> Enjoy, --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] I'm going to shoot my machine
Probably a quote problem, or you are adding a ; at the end. The mysql_error() output after the failed query would tell you exactly. Much easier than asking here. -Rasmus On Fri, 9 Aug 2002, Liam Gibbs wrote: > Is there any reason why a MySQL query won't run > properly in a mysql_query command, but will run > properly when I put the *exact same* statement into a > textbox that inputs into a mysql_query command? > > __ > Do You Yahoo!? > HotJobs - Search Thousands of New Jobs > http://www.hotjobs.com > > -- > 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] Re: Linux PHP editor
Is there a php editor for Win2k ? Negrea Mihai wrote: > try nedit from nedit.org > you can download the patterns from the site to do php syntax highlight.. > > I have combined it with cervisia from kde 3 and made it look smth like an IDE > :) .. and I've been working 4-6 hours per day for about half an year with it > with no problems. > > I also have tried Quanta but it is too huge for nothing... but if you need > syntax completion maybe you should take a look at it. > > Good luck in your open source trip ;) > > -- > Negrea Mihai > web: http://www.negrea.net > > On Friday 09 August 2002 02:11 pm, [EMAIL PROTECTED] wrote: > > JJ Harrison\ writes: > > > I just switched over to Red Hat Linux from Win2k... > > > > > > Only to find my fav editor only works on windows systems... > > > > > > could someone suggest a good replacement? > > > > > > > > > -- > > > JJ Harrison > > > [EMAIL PROTECTED] > > > www.tececo.com > > > > > > > > > > > > -- > > > PHP General Mailing List (http://www.php.net/) > > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > simply vi or vim of pico :) > > -- > 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] I'm going to shoot my machine
Is there any reason why a MySQL query won't run properly in a mysql_query command, but will run properly when I put the *exact same* statement into a textbox that inputs into a mysql_query command? __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] How do i add sound + pictures in a MySQL Database and how do i consult it via PHP
hi, I am new on MySQL en PHP. I'm making a on-line dictionary. I use PHP and a MySQL Database. Now I want to add audio-streaming (MP3) and pictures (JPG) to the database. Can sombody help me out? The database is working well (only text). Danny -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Linux PHP editor
I had problems compiling quanta on my redhat 7.1 box, I had to grab some cvs files to fix it (Don't remember which files.. Probably whichever ones had problems compiling - and the makefile). Quanta is a great program, it's basically a homesite clone for Linux. -Adam -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED]] Sent: Friday, August 09, 2002 5:46 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Linux PHP editor On Friday 09 August 2002 20:34, [EMAIL PROTECTED] wrote: > I use vim most of the time... but how 'bout some bluefish? > > http://bluefish.openoffice.nl/ Last time I tried it (about a month ago) the syntax highlighting was atrocious. I've always favoured quanta over bluefish but Redhat 7.3 seriously broke quanta. That only leaves vim (nedit is good, but has problems integrating with the KDE clipboard which renders it impotent). -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * /* The end of the human race will be that it will eventually die of civilization. -- Ralph Waldo Emerson */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Having an issue with a Directory Listing in the php Scripting
On Fri, Aug 09, 2002 at 08:58:41AM -0500, §§ Duncan MacLeod §§ wrote: > I am only being able to list the first > file in each of the directories. Not the entire directory. ... snip ... > Although, the only files I really need out of the > directory are going to be '.JPG', '.jpg', '.GIF', '.gif', '.JPEG', '.jpeg'. While this doesn't do exactly what your script does, it will point you in the right direction... '; while (list(,$Name) = each($FileList) ) { echo "$Name\n"; } echo ''; ?> -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Problem with output buffering in PHP 4.0.6 and Apache/1.3.20
Hi.. I have found a strange problem. I try to use php output buffering, but I found this problem. Working with small amount of data everything is fine. But If I set example script like this: Everything works fine when $buffer < approx 1.5 Mb, but if the size of the output, that need to be bufered exceeded some strange limit aprox 1593400 bytes, buffer is cut to that length and rest of the output is lost(!). I look in docs and manuals, but found nothing about it. Is it posssible to set large size for the output buffering operations or this strange limit is hard coded and cant be exceeded ??? I try to play with PHP.INI or add swapspace and DIMs memory with no effect. Please help. --- Odchozí zpráva neobsahuje viry. Zkontrolováno antivirovým systémem AVG (http://www.grisoft.cz). Verze: 6.0.381 / Virová báze: 214 - datum vydání: 2.8.2002
Re: [PHP] What the heck is this Zope?
Check this page out: http://www.zope.org/WhatIsZope .. And click the links on that page too. I don't know much about it. But what I gather is that it's sort of like an open source "cold fusion" type application written in python. Not that it necissarily resembles cold fusion in any way, but that it's sort of a framework for building web applications. I don't know a whole lot about python either, but it looks really cool. I think python is probably a better general-purpose scripting language than php, similar to perl in that respect. But as far as building applications that are strictly for the web, is there anything as good as php? I would probably say no, but a lot of it is a matter of taste. hth, --ed - Original Message - From: Deependra B. Tandukar <[EMAIL PROTECTED]> Newsgroups: php.general To: PHP General <[EMAIL PROTECTED]> Sent: Friday, August 09, 2002 6:09 AM Subject: What the heck is this Zope? Dear all: What the heck is this Zope? Which is better PHP or Zope? Any idea ! DT __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] DPHPEdit - FREE PHP IDE, new version available
It is still FREE! Download site: http://www.pleskina.com/dphped In newest version (0.9.3.0): a. Recent projects list (Reopen) added to "File" menu b. File Browser added - you can now add files to project or open projects via double-clicking file name in internal file browser! c. Added Syntax Highlighting for JavaScript and CSS files __ Davor Pleskina - [EMAIL PROTECTED] http://www.pleskina.com ICQ#: 38632789 Programmers don't die; they just GOSUB without RETURN... __ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Having an issue with a Directory Listing in the php Scripting
I was wondering if I could get alittle help in this issue. I have extinguished all other resources, with no avail to help. I am trying to get a directory listing for a dropdown list to choose for connection to a MySQL database for the correct image name to be printed into the database. I have the database part working perfectly as far as the printing the correct name from the directory list, although I am only being able to list the first file in each of the directories. Not the entire directory. This is in a .inc script running with two other scripts a .php script and another .inc script for the reference to the following. I was wondering if someone could give me some insight as to how I could resolve this issue to make the list actually appear like it is supposed to displaying everything in the list that has the extension '.jpg', '.JPG', '.gif', '.GIF', '.bmp', '.BMP', '.jpeg', '.JPEG'. Although, the only files I really need out of the directory are going to be '.JPG', '.jpg', '.GIF', '.gif', '.JPEG', '.jpeg'. some assistance would be greatly appreciated.. the following is the actual script as I have written it. /* The Script segment that is needed to be fixed or working */ if ($dir1 = opendir("../../members_profiles/pics/")) { while(FALSE !== ($file = readdir($dir1))) { if ($file != "." && $file != "..") { $fdd["picture"] = Array( 'name'=>'Picture', 'select'=>'D', 'type'=>'string', 'maxlen'=>130, 'nowrap'=>false, 'values'=>Array($file), 'default'=>'no_image.jpg', 'required'=>true, 'sort'=>true ); } } closedir($dir1); } if ($dir2 = opendir("../../members_profiles/crests/")) { while(FALSE !== ($files = readdir($dir2))) { if ($files != "." && $files != "..") { $fdd["crest"] = Array( 'name'=>'Crest', 'select'=>'D', 'type'=>'string', 'maxlen'=>130, 'nowrap'=>false, 'values'=>Array($files), 'default'=>'no_image.jpg', 'required'=>true, 'sort'=>true ); } } closedir($dir2); } /* the web page that this is running on is http://www.dragonpalace.net/~dfwshinai/members_profiles although, the script is actually resident in the admin pages of this site. */ Thanks in advance §§ Duncan MacLeod §§ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] $http_host use case
David: On Thu, Aug 08, 2002 at 10:30:15PM +0200, David D wrote: > > I make 2 sites with 2 domain names that use same scripts, > Each has got its html templates in a special dir selected judgging from > $HTTP_HOST values. ... snip ... > search engine works, did they affect this var correctly ? If there was an HTTP request, then the HTTP_HOST will be set. The only problem you can run into is if someone hits the site via the IP address, since you said you only have one. In that case, the HTTP_HOST will hold the IP address. So, decide now which scripts you want to use in that case. Even better, set up two options in your logic: if domain name 1, use script set 1 everything else, use script set 2 --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Linux PHP editor
I'll try... Anyway, next time, I'll try using KDE as well... Regards, - E > >hmm, can't answer those questions...I hope you can find such answers >on their web site. > >warmly, >paul > >At 03:40 PM 8/9/2002, you wrote: >>I'd like to use it but I don't use KDE (perhaps the libraries >>needed are not installed). Besides, an earlier post said that it's >>broken (?) in Redhat 7.3... >> >>BTW, can it do search and replace in multiple open files? Does it >>have FTP capabilities? >> >>If yes, well, perhaps it's time to start using it... >> >>- E >> >>PS >>I hope it has good support of Japanese as well... >> >> >>> >>>I am using Quanta 2.0 and loving it. >>> >>>http://quanta.sourceforge.net >>> >>>Oh My Gosh they have a new verison out.. 3.0 Time to upgrade. >>> >>>Paul >>> >>>@ Edwin wrote: >>> >>> > I use vim most of the time... but how 'bout some bluefish? >>> > >>> > http://bluefish.openoffice.nl/ >>> > >>> > Or, try using your fav editor with wine... >>>http://www.winehq.com/ >>> > >>> > (I wouldn't want to do that though...) >>> > >>> > - E >>> > >>> > How 'bout >>> >> >>> >>I just switched over to Red Hat Linux from Win2k... >>> >> >>> >>Only to find my fav editor only works on windows systems... >>> >> >>> >>could someone suggest a good replacement? >>> >> >>> >> >>> >>-- >>> >>JJ Harrison >>> >>[EMAIL PROTECTED] >>> >>www.tececo.com >>> >> >>> >> >>> >> >>> >>-- >>> >>PHP General Mailing List (http://www.php.net/) >>> >>To unsubscribe, visit: http://www.php.net/unsub.php >>> >> >>> > >>> > >>> > >>> > >>> > >>>_ >>> > MSN ??? http://house.msn.co.jp/ >>> >>> >>>-- >>>PHP General Mailing List (http://www.php.net/) >>>To unsubscribe, visit: http://www.php.net/unsub.php >> >> >> >> >>_ >>$B2q0wEPO?$OL5NA!&=<>http://auction.msn.co.jp/ >> _ $B:G?7$N%U%!%$%J%s%9>pJs$H%i%$%U%W%i%s$N%"%I%P%$%9(B MSN $B%^%M!<(B http://money.msn.co.jp/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Is there a standard function to remove multiple spacesfrom a string?
function foo($str,$num) { return preg_replace('/ {'.$num.',}/',str_repeat(' ',$num),$str); } On Fri, 9 Aug 2002, Henry wrote: > Hi All, > > Are there standard functions for removing multiple spaces (or even better > limiting contiguous space to specified lengths)? > > i.e > > foo("Hello peeps, happy times",1) -> "Hello peeps, happy times" > foo("Hello peeps, happy times",0) -> "Hellopeeps,happytimes" > foo("Hello peeps, happy times",2) -> "Hello peeps, happy times" > (notice single space between "," and "h") > > Can I do it with reg exp? > > TIA > > Henry > > > > > -- > 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] Help with multiple select
Untested... $row = mysql_fetch_array($result, MYSQL_ASSOC); # Assuming items are comma separated in the field... $mins = explode(',', $row['mins']); echo "\n"; echo " \n"; for ($i=0; $i<12; $i++) { echo " $i\n" } echo " \n\n"; echo "\n"; echo " \n"; for (; $i<24; $i++) { echo " $i\n" } echo " \n\n"; echo ""; --Dan -- PHP classes that make web design easier SQL Solution | Layout Solution | Form Solution sqlsolution.info | layoutsolution.info | formsolution.info T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y 4015 7 Av #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php