Re: [PHP] seg fault with snmp
* kancha ([EMAIL PROTECTED]) [Dec 15. 2001 02:59]: I did not get a core dump. I got following in my apache error log file [...] On Saturday 15 December 2001 13:01, Brian Clark wrote: (Be sure to take note of all the little comments on that page) No time to read all the little comments, eh? :-) Go back here: http://bugs.php.net/bugs-generating-backtrace.php And read If you can't get a core file I'm not a great speed reader either. g -- -Brian Clark -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] seg fault with snmp
i had also compiled php as cgi without the --with-apxs parameter. then i executed php and core was dumped. the out is as follows. [root@ispms html]# gdb /usr/local/bin/php /var/www/html/core GNU gdb Red Hat Linux 7.x (5.0rh-15) (MI_OUT) Copyright 2001 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type show copying to see the conditions. There is absolutely no warranty for GDB. Type show warranty for details. This GDB was configured as i386-redhat-linux... Core was generated by `php snmp.php'. Program terminated with signal 11, Segmentation fault. Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /lib/libcrypt.so.1...done. Loaded symbols for /lib/libcrypt.so.1 Reading symbols from /lib/libssl.so.2...done. Loaded symbols for /lib/libssl.so.2 Reading symbols from /lib/libcrypto.so.2...done. Loaded symbols for /lib/libcrypto.so.2 Reading symbols from /lib/libresolv.so.2...done. Loaded symbols for /lib/libresolv.so.2 Reading symbols from /lib/libpam.so.0...done. Loaded symbols for /lib/libpam.so.0 Reading symbols from /usr/lib/libsnmp-0.4.2.1.so...done. Loaded symbols for /usr/lib/libsnmp-0.4.2.1.so Reading symbols from /usr/lib/libpq.so.2...done. Loaded symbols for /usr/lib/libpq.so.2 Reading symbols from /usr/lib/libgd.so.1.8...done. Loaded symbols for /usr/lib/libgd.so.1.8 Reading symbols from /lib/i686/libm.so.6...done. Loaded symbols for /lib/i686/libm.so.6 Reading symbols from /lib/libnsl.so.1...done. Loaded symbols for /lib/libnsl.so.1 Reading symbols from /lib/i686/libc.so.6...done. Loaded symbols for /lib/i686/libc.so.6 Reading symbols from /usr/kerberos/lib/libkrb5.so.3...done. Loaded symbols for /usr/kerberos/lib/libkrb5.so.3 Reading symbols from /usr/kerberos/lib/libk5crypto.so.3...done. Loaded symbols for /usr/kerberos/lib/libk5crypto.so.3 ---Type return to continue, or q return to quit--- Reading symbols from /usr/kerberos/lib/libcom_err.so.3...done. Loaded symbols for /usr/kerberos/lib/libcom_err.so.3 Reading symbols from /usr/lib/libfreetype.so.6...done. Loaded symbols for /usr/lib/libfreetype.so.6 Reading symbols from /usr/lib/libjpeg.so.62...done. Loaded symbols for /usr/lib/libjpeg.so.62 Reading symbols from /usr/lib/libpng.so.2...done. Loaded symbols for /usr/lib/libpng.so.2 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib/libz.so.1 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 #0 0x402c8c71 in strlen () from /lib/i686/libc.so.6 (gdb) bt #0 0x402c8c71 in strlen () from /lib/i686/libc.so.6 #1 0x4017969f in bprintf () from /usr/lib/libsnmp-0.4.2.1.so #2 0x4017a453 in sprint_object_identifier () from /usr/lib/libsnmp-0.4.2.1.so #3 0x4017ce3a in sprint_value () from /usr/lib/libsnmp-0.4.2.1.so #4 0x080a1ab5 in php_snmp (ht=3, return_value=0x81e358c, this_ptr=0x0, return_value_used=1, st=2) at snmp.c:318 #5 0x080a1dbb in zif_snmpwalk (ht=3, return_value=0x81e358c, this_ptr=0x0, return_value_used=1) at snmp.c:397 #6 0x08134376 in execute (op_array=0x81e368c) at ./zend_execute.c:1590 #7 0x08111788 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at zend.c:814 #8 0x08067255 in php_execute_script (primary_file=0xb980) at main.c:1309 #9 0x08064e38 in main (argc=2, argv=0xba24) at cgi_main.c:738 #10 0x4025e507 in __libc_start_main (main=0x8064648 main, argc=2, ubp_av=0xba24, init=0x8062760 _init, fini=0x813c500 _fini, rtld_fini=0x4000dc14 _dl_fini, stack_end=0xba1c) at ../sysdeps/generic/libc-start.c:129 (gdb) On Saturday 15 December 2001 12:59, Yasuo Ohgaki wrote: Kancha . wrote: i had compiled php with following configure parameters. ./configure --with-apxs=/usr/sbin/apxs --enable-calendar --with-pgsql --with-snmp --enable-ucd-snmp-hack --enable-wddx --enable-sysvsem --with-sysvshm --enable-inline-optimization --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl Rasmus is asking backtrace. Read following link to get one ;) http://bugs.php.net/bugs-generating-backtrace.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 15 Dec 2001 08:18:40 -0000 Issue 1053
php-general Digest 15 Dec 2001 08:18:40 - Issue 1053 Topics (messages 2 through 77814): Re: Sending out mass mail without having timeout problems .. 2 by: Paul Roberts Re: Filenames with spaces in them 3 by: Mike Eheler 5 by: Mike Eheler Re: PHPhish Logo 4 by: Andrew Chase Re: PHP command for issuing UNIX command??? 6 by: Scott Fletcher 77812 by: J.F.Kishor Function to parse the data from Integer to String 7 by: Scott Fletcher file upload problem - Warning: Max file size of 8 bytes exceeded 8 by: Lee Philip Reilly Opening a new window. 9 by: Brandon Orther 77780 by: Mehmet Kamil ERISEN 77782 by: Mark Charette 77786 by: Brandon Orther 77787 by: Mehmet Kamil ERISEN 77788 by: Richard S. Crawford 77789 by: Richard S. Crawford 77790 by: Mark Charette 77791 by: Richard S. Crawford 77796 by: Michael J. Seely Re: Logo proposal - first thought 77781 by: Brian Clark Miscount 77783 by: Daniel Alsén 77785 by: Kevin Stone 77793 by: Daniel Alsén Re: echo vs. print() performance? 77784 by: Jim Lucas MySQL date and NULL problems 77792 by: sgibbs.vt.globalhealth.org Is PHP up to task? 77794 by: René Fournier preg match question 77795 by: phantom Re: Session storage and the --with-mm option 77797 by: John Lim What is the best way to reorder table columns...temp tables? 77798 by: J. Roberts php4apache.dll please 77799 by: rick 77801 by: Gaylen Fraley DOM XML? 77800 by: Daniele Baroncelli 77807 by: Yasuo Ohgaki Unable to return object references from functions 77802 by: Manuel Lemos 77806 by: Yasuo Ohgaki seg fault with snmp 77803 by: Kancha . 77804 by: Rasmus Lerdorf 77805 by: Kancha . 77808 by: Yasuo Ohgaki 77809 by: Brian Clark 77811 by: Kancha . 77813 by: Brian Clark 77814 by: Kancha . Logout problem - help me out! 77810 by: J.F.Kishor Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- ---BeginMessage--- how do I do that on a virtual server? (Linux+apache, I'm just a user not admin) the con is that I can't afford the phone bill, I'm on a dial up (56K). Paul Roberts [EMAIL PROTECTED] - Original Message - From: jimtronic [EMAIL PROTECTED] To: Paul Roberts [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Thursday, December 13, 2001 9:13 PM Subject: Re: [PHP] Sending out mass mail without having timeout problems .. Wouldn't it be easier (better) to create a sendmail alias include file that has all the addresses in it and let sendmail or majordomo or qmail or whatever handle it? I'm not knocking your method as much as I'm looking for the pros and cons of the different methods. jim the way I handle this is to send a response to the browser before sending any mail you can then close the browser window and the script will carry on while you do something else. I get the script to send me an email when its finished 2-3 hours later. (I have around 6000 newsletters that are sent out) Paul Roberts [EMAIL PROTECTED] - Original Message - To: bain [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Tuesday, December 11, 2001 8:39 AM Subject: [PHP] Sending out mass mail without having timeout problems .. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- Jim Musil - Multimedia Programmer Nettmedia - 212-629-0004 [EMAIL PROTECTED] ---End Message--- ---BeginMessage--- I'll note that the erroneous command is the is_dir($file).. this causes the problem. Mike Mike Eheler wrote: Consider this code for traversing through a directory structure: ?php function traverse($path='.') { $path = realpath($path); $dir = opendir($path); echo \nDirectory : $path\n; echo str_pad('',76,'-').\n; while (false !== ($file = readdir($dir))) { if (is_dir($file) $file != '.' $file != '..') { traverse($path/$file); echo $file; } } closedir($dir); } echo 'pre'; traverse(); echo '/pre'; ? Now when I run it in a directory that has a file with spaces in it's name.. for examples purposes, the file willbe called file name with spaces. Directory : /home/mike/php/test Warning: stat failed for
Re: [PHP] Is PHP up to task?
- Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 1:27 AM Subject: [PHP] Is PHP up to task? (Now that I have your attention... :-) Here's the situation: All the navigational buttons in the site I'm working on have three different states (for mousovers--normal, mouseover, onClick). What I don't like: When I mouse over one button, it takes a second or two for the page to fetch the mouseover state of the button from the server. Now, normally, I would just write a preloadimages() function in JavaScript and preload all the button states when the pages load. BUT, this is a little harder, since this is a fairly big site (or will be) and it's not always the same buttons that need to be loaded; they can change from page to page (say, between sections, with subnav bars). That being said, I've kept one thing simple: All the buttons (and their states) are stored in the same directory, and in fact only button images are in that directory (/nav). So here's what I would like to know: Is it possible for PHP to read the contents of a directory--all the files--and then take that array and generate some javascript preload() statements? (Of course, I'm sure it IS possible, but I would appreciate any pointers you might have before I undertake it. Maybe there's even a better way than what I can see!) What I was thinking was to preload all the nav buttons and their states in the header.inc. Thanks. ...Rene Rene, Of course this is possible. However, I doubt if it is desirable. The more visitors to your site the larger the load if you load all the graphics, because each session would have it's own copy of all the graphics. It would be better if you checked the page being loaded and passed a list of the needed graphics needed to a function that would load ONLY those graphics needed for said page. This is not too very difficult and if run on a PHP caching server then the overhead is not so bad. The hard part is getting the JS to work correctly (at least for me. hehe. I suck at JS). For example. http://clans.acnsnet.com is a package I'm working on that uses templates to control the layout. Each menu item is stored in an SQL backend as well as the Template info (location, menu type, state, etc). I already have a function to determine what page is active. So finding out what menu items are visible is simply a matter of comparing the active page to the array of menu items. I can then determin which images I would need to load (depending on the template in use). This way I only load the images that are needed, which saves on load time and memory. Anyway, have fun. chuck -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] how to reinitialise an MySQL_fetch_array
Hello, I would like to reinitialise an MySQL_fetch_array. That is, once it has gone through I would like to be able to go back to the start again. for eg while ($myrow=MySQL_fetch_array($result2)) { $befid=$myrow[beforeid]; while($myrow5=MySQL_fetch_array($result5)) { $aftid=$myrow[afteridid]; if ( $befid == aftid) { do something; } } //while($myrow5=MySQL_fetch_array($result5)) //now that the inner loop has finished I would like to be able to restart the inner loop by reinitailsing the MySQL_fetch_array } //while ($myrow=MySQL_fetch_array($result2)) Regards, Ivan
[PHP] Re: What do admins put in their open_basedir
Ehm ... I tried to do open_basedir within the .htaccess and own this file by root, so the user couldn´t change the settings. But yeah, that wasn´t the best solution, now I do within the Apache config file. A entry for a vhost looks like this: VirtualHost IPADRESS ServerAdmin [EMAIL PROTECTED] ServerName www.domain.com ServerAlias domain.com DocumentRoot /home/domain/public_html php_admin_value open_basedir /home/domain /VirtualHost Hope it helps ! Cya ! Daniel Marc Delisle [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi, I would like to know if sysadmins usually put . in their php.ini, open_basedir variable, or if they put some other directory, or both. The reason is that phpMyAdmin's dump uploads don't work well currently on a server with open_basedir, and I would try to code around the problem, if practical. Thanks. Marc Delisle phpMyAdmin dev. team -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: Online editor that edits all pages
IT IS NOT POSSIBLE!!! Php does not permit editing of files on the file system of a remote host. If you want to edit your php scripts on some free host...then place a dirty code editor on that system...It may be slow but it is the only solution... It MIGHT be possible to use the fopen() command and make an editor like that(your imagination) but you need to set the CHMOD of the files each time you edit itBut it is a BAD ideaIt is going to be slow..You may get several errors If it works...make it a public domain for the advantages of others.. R. Lindeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... sorry fo. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: Unable to return object references from functions
Hi Yasuo, I seem to remember having similar problems understanding objects and references also and you guided me here. Manuel is a good programmer and if he also has problems, I'm a bit worried for novices. Objects and references are not intuitive :( Regards, John Yasuo Ohgaki [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Manuel Lemos wrote: Hello, I am trying to return a reference from an object created inside a function and at the same time have the object stored in a global variable. It seems that when I try doing it by assigning the object reference to a function argument that is passed by reference, nothing is returned in that variable despite inside the function the argument variable seems to have the right value. Is this a PHP bug or this is not the right way to do it? No this is not a bug, but issue. Please ask this kind of question only to php-general. Thank you. PS: Read manaul sections (Object and Reference. It's explained ;) -- Yasuo Ohgaki Try the example below. Manuel Lemos ? class test_class { var $dummy=nothing; }; Function not_assigning($not_returned,$copy) { global $object; $object=new test_class; $object-dummy=original; $success=1; $not_returned= $object; $copy=$object; $copy-dummy=copy; var_dump(In the function,$success,$not_returned,$copy,$object); return $success; } $success=not_assigning($not_returned,$copy); var_dump(Out the function,$success,$not_returned,$copy,$object); ? -- Yasuo Ohgaki -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Online editor that edits all pages
You may want to take a look at the midgard project's cms API using php4. http://www.midgard-project.org/ That combined with a web base interface created by hklc.com called nadmin studio enables you write your entire web site from a browser. here is a demo of it on hhlc's site. http://cmsdemo.hklc.com/ user : demo pass : demo R. Lindeman wrote: sorry for the inconvieniance but i have to restate my question i'm looking for a online editor that is able to edit pages that are not on the same host as the editor is. thanx -- Vincent Stoessel [EMAIL PROTECTED] Java Linux Apache Mysql Php (JLAMP) Engineer (301) 362-1750 Mobile (410) 419-8588 AIM, MSN: xaymaca2020 , Yahoo Messenger: vks_jamaica -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] [PHP/Apache] Transparent Subdomains ?
If there are no other virtual hosts on your box, you could leave Apache as is (unrecognised hostnames will go to the default site), and do the dynamic processing in PHP using the $REQUEST_URI variable... as for the crazy-page.php thing, you could set up a custom error handler page that points at your dynamic page... Hope that helps... -- Shane On Thursday 13 Dec 2001 7:56 pm, Jon Shoberg wrote: Any ideas on how to pull this off. I would like to have http://mydomain.com and http://www.mydomain.com resolve to my /index.html page. When a user types in http://crazy.mydomain.com or http://crazy.mydomain.com/crazy-page.php, I would like to have it resolve to /home/mydomain/public_html/handler.php where I can trap for the subdomain/URI and perform dynamic processing on those values. I presume it would have to be a process though mod_rewrite and .htaccess? Is this able to be done. I've gone though quite a bit yet unable to get it working as described. Any ideas? Jon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Logout problem - help me out....!
HTTP authentication (which is what you're using) is controlled by the browser. Some browsers even keep the login/password after the window is closed until the user logs out (Konqueror on Linux for one...) If you want more control over logins and the ability to do a logout, you should make your own login scheme using an HTML form for username/password and setting a cookie to flag that the user is 'logged in'. Then, when the user wants to log out, clear the cookie and job done :) -- Shane On Saturday 15 Dec 2001 5:37 am, J.F.Kishor wrote: hello all, I have already posted this mail, Is there anyone to help me out?, it's urgent plz.! I have designed a web page using php, as a security measure I have kept it password protected. I have used Apache authentication, using htpasswd file. Now I want to keep a logout in this web page, I tried to send a header request http/1.0 401 Unauthorized to force it to reauthenticate when the logout link is clicked in the form, but this dose not work. I tried using session_destroy() even that does not work. To get the authenticated users name I have used GetEnv(REMOTE_USER) in all the form and with that username I'am handling mysql and other requests. I don't know where exactly the REMOTE_USER gets stored. So please help me out in this problem. I want to remove the window's authentication cache. Please give me some ideas and suggestion to remove the user name and make the page fresh for the other user to log in. If possible please send me a sample script. Thanks for sparing time on this mail. with hope's, - JFK kishor Nilgiri Networks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Is PHP up to task?
What you're saying makes sense--that loading ALL the nav button images for the whole site at once is overkill. In this case, however, it really isn't, since there are just to 'sets' of nav buttons--the top-level set, which needs to be preloaded no matter what page the user is on; and the products subsection set, which SHOULD be preloaded, because every visit will inevitably visit that section (it is the reason why any visits the site). I agree that if there were numerous sub-level 'sets' of nav button images, that loading all of them would be inefficient. ...Rene On Saturday, December 15, 2001, at 02:08 AM, Charles Williams wrote: - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 1:27 AM Subject: [PHP] Is PHP up to task? (Now that I have your attention... :-) Here's the situation: All the navigational buttons in the site I'm working on have three different states (for mousovers--normal, mouseover, onClick). What I don't like: When I mouse over one button, it takes a second or two for the page to fetch the mouseover state of the button from the server. Now, normally, I would just write a preloadimages() function in JavaScript and preload all the button states when the pages load. BUT, this is a little harder, since this is a fairly big site (or will be) and it's not always the same buttons that need to be loaded; they can change from page to page (say, between sections, with subnav bars). That being said, I've kept one thing simple: All the buttons (and their states) are stored in the same directory, and in fact only button images are in that directory (/nav). So here's what I would like to know: Is it possible for PHP to read the contents of a directory--all the files--and then take that array and generate some javascript preload() statements? (Of course, I'm sure it IS possible, but I would appreciate any pointers you might have before I undertake it. Maybe there's even a better way than what I can see!) What I was thinking was to preload all the nav buttons and their states in the header.inc. Thanks. ...Rene Rene, Of course this is possible. However, I doubt if it is desirable. The more visitors to your site the larger the load if you load all the graphics, because each session would have it's own copy of all the graphics. It would be better if you checked the page being loaded and passed a list of the needed graphics needed to a function that would load ONLY those graphics needed for said page. This is not too very difficult and if run on a PHP caching server then the overhead is not so bad. The hard part is getting the JS to work correctly (at least for me. hehe. I suck at JS). For example. http://clans.acnsnet.com is a package I'm working on that uses templates to control the layout. Each menu item is stored in an SQL backend as well as the Template info (location, menu type, state, etc). I already have a function to determine what page is active. So finding out what menu items are visible is simply a matter of comparing the active page to the array of menu items. I can then determin which images I would need to load (depending on the template in use). This way I only load the images that are needed, which saves on load time and memory. Anyway, have fun. chuck -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- René Fournier [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] thanks
been using php for a few months now, just wanted to say a big THANK YOU to all the developers for such a wonderful language, thanks guys! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] thanks
At 07:56 PM 12/15/2001 +, [EMAIL PROTECTED] wrote: been using php for a few months now, just wanted to say a big THANK YOU to all the developers for such a wonderful language, thanks guys! Well, I have to second that. If it weren't for PHP I probably would have never gotten into web development at all. I've said it before and I'll say it again...if Microsoft solutions were the only ones available I would have switched careers long ago. Thank God (and the PHP developers) for PHP! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: file upload problem - Warning: Max file size of 8 bytes exceeded
I'm not sure if you've read this or not but it may help: http://www.php.net/manual/en/features.file-upload.php -David Serrano ([EMAIL PROTECTED]) Lee Philip Reilly [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi, I have an HTML form containing a file upload form object called 'file'. When I submit the form (either holiding a path to a 1kb file or a 7MB file) I get the following error: - Warning: Max file size of 8 bytes exceeded - file [file] not saved in Unknown on line 0 - I had hoped that by changing the upload_max_filesize value in the php.ini this problem would be resolved, but it hasn't. I expect some people have had similar problems in the past; can anyone suggest what the problem is? Some additional info at the foot of this message. Thanks in advance! - Best regards, Lee Windows 2000; PHP4; Apache V1.3 PHP.INI reads: -=-=-==-=-=-=-= ; Maximum allowed size for uploaded files. upload_max_filesize = 8M -=-=-==-=-=-=-= Simplified PHP script reads: -=-=-==-=-=-=-= if ($file!=){ @copy($file, c:\Program Files\Apache Group\Apache\htdocs\sasdap\v4 or die (Could not copy the file.); } else { die(No input file specified); } -=-=-==-=-=-=-= .HTML's file upload name = file -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 15 Dec 2001 20:24:02 -0000 Issue 1054
php-general Digest 15 Dec 2001 20:24:02 - Issue 1054 Topics (messages 77815 through 77826): Re: Is PHP up to task? 77815 by: Charles Williams 77823 by: René Fournier how to reinitialise an MySQL_fetch_array 77816 by: Ivan Carey Re: Online editor that edits all pages 77817 by: Bharath Bhushan Lohray 77820 by: Vincent Stoessel Re: What do admins put in their open_basedir 77818 by: Daniel Urstöger Re: Unable to return object references from functions 77819 by: John Lim Re: [PHP/Apache] Transparent Subdomains ? 77821 by: Shane Wright Re: Logout problem - help me out! 77822 by: Shane Wright thanks 77824 by: david.postboy.net 77825 by: Michael Sims Re: file upload problem - Warning: Max file size of 8 bytes exceeded 77826 by: David Serrano Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- ---BeginMessage--- - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 1:27 AM Subject: [PHP] Is PHP up to task? (Now that I have your attention... :-) Here's the situation: All the navigational buttons in the site I'm working on have three different states (for mousovers--normal, mouseover, onClick). What I don't like: When I mouse over one button, it takes a second or two for the page to fetch the mouseover state of the button from the server. Now, normally, I would just write a preloadimages() function in JavaScript and preload all the button states when the pages load. BUT, this is a little harder, since this is a fairly big site (or will be) and it's not always the same buttons that need to be loaded; they can change from page to page (say, between sections, with subnav bars). That being said, I've kept one thing simple: All the buttons (and their states) are stored in the same directory, and in fact only button images are in that directory (/nav). So here's what I would like to know: Is it possible for PHP to read the contents of a directory--all the files--and then take that array and generate some javascript preload() statements? (Of course, I'm sure it IS possible, but I would appreciate any pointers you might have before I undertake it. Maybe there's even a better way than what I can see!) What I was thinking was to preload all the nav buttons and their states in the header.inc. Thanks. ...Rene Rene, Of course this is possible. However, I doubt if it is desirable. The more visitors to your site the larger the load if you load all the graphics, because each session would have it's own copy of all the graphics. It would be better if you checked the page being loaded and passed a list of the needed graphics needed to a function that would load ONLY those graphics needed for said page. This is not too very difficult and if run on a PHP caching server then the overhead is not so bad. The hard part is getting the JS to work correctly (at least for me. hehe. I suck at JS). For example. http://clans.acnsnet.com is a package I'm working on that uses templates to control the layout. Each menu item is stored in an SQL backend as well as the Template info (location, menu type, state, etc). I already have a function to determine what page is active. So finding out what menu items are visible is simply a matter of comparing the active page to the array of menu items. I can then determin which images I would need to load (depending on the template in use). This way I only load the images that are needed, which saves on load time and memory. Anyway, have fun. chuck ---End Message--- ---BeginMessage--- What you're saying makes sense--that loading ALL the nav button images for the whole site at once is overkill. In this case, however, it really isn't, since there are just to 'sets' of nav buttons--the top-level set, which needs to be preloaded no matter what page the user is on; and the products subsection set, which SHOULD be preloaded, because every visit will inevitably visit that section (it is the reason why any visits the site). I agree that if there were numerous sub-level 'sets' of nav button images, that loading all of them would be inefficient. ...Rene On Saturday, December 15, 2001, at 02:08 AM, Charles Williams wrote: - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 1:27 AM Subject: [PHP] Is PHP up to task? (Now that I have your attention... :-) Here's the situation: All the navigational buttons in the site I'm working on have three different states (for mousovers--normal, mouseover, onClick). What I don't like: When I mouse over one button, it takes a second or two
[PHP] PHP4.1.0 Apache1.3.22 under WinXP
Hi everyone, I'm having troubles getting Apache to recognize .php files, and thus parse them. I followed the instructions included with the PHP4.1.0 distribution, and have PHP loaded as an Apache module, checking my services confirms this as its description reads Apache/1.3.22 (Win32) PHP/4.1.0. But when I attempt to load a .php file, I will get the entire file, unparsed. I added the following two lines to my httpd.conf file: LoadModule php4_module C:\Apache.MySQL.PHP\PHP\sapi\php4apache.dll AddType application/x-httpd-php .php Am I missing something? Thanks, Christian -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Brain dead - need help!
use a phpinfo() in one of your pages...that'll show you various places to get your data... btw, php does have the $HTTP_GET_VARS that'll have what you want... jack Gaylen Fraley wrote: I know that I know the answer - it's just buried in the recesses of my mind .. PHP has the various $HTTP_*_VARS arrays. Is there one to get the formliteral pairs from the hyperlinks, as in a href=somepage.php?var1=test? I want to extract the $var1 value pair. I know I can do this through javascript, but I want somepage.php to parse and use the variable/value. If there is not an array, then what is the simplest way? Thanks! -- Gaylen [EMAIL PROTECTED] Home http://www.gaylenandmargie.com/ PHP KISGB v2.6 Guest Book http://www.gaylenandmargie.com/phpwebsite/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] i get a warning after upgrading to 4.1.0 (repost)
does anyone know what Warning: Unknown persistent list entry type in module shutdown (11) in Unknown means? what do i have to do to solve the problem php seems to have? environment: Win2k, IIS5.0, MySQL just upgraded from PHP 4.0.6 to 4.1.0 now i get the warning msg. any help would be appreciated. kind regards, phil! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: Email class
Hello, Gerard Samuel wrote: Could someone recommend a good php email class. Im trying out class.phpmailer.php, but its not jiving right with me... You may find here plenty of them: http://phpclasses.upperdesign.com/browse.html/class/2 Regards, Manuel Lemos -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Brain dead - need help!
DUH! I had tried that and it didn't work, so I panicked and posted! Come to find out, I had a typo. I am so red thanks! BTW, to the others who answered privately that it's automatically there - Not if register_globals is set to OFF, which is what I am using. But thanks for responding! -- Gaylen [EMAIL PROTECTED] Home http://www.gaylenandmargie.com/ PHP KISGB v2.6 Guest Book http://www.gaylenandmargie.com/phpwebsite/ Jack Dempsey [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... use a phpinfo() in one of your pages...that'll show you various places to get your data... btw, php does have the $HTTP_GET_VARS that'll have what you want... jack Gaylen Fraley wrote: I know that I know the answer - it's just buried in the recesses of my mind .. PHP has the various $HTTP_*_VARS arrays. Is there one to get the formliteral pairs from the hyperlinks, as in a href=somepage.php?var1=test? I want to extract the $var1 value pair. I know I can do this through javascript, but I want somepage.php to parse and use the variable/value. If there is not an array, then what is the simplest way? Thanks! -- Gaylen [EMAIL PROTECTED] Home http://www.gaylenandmargie.com/ PHP KISGB v2.6 Guest Book http://www.gaylenandmargie.com/phpwebsite/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Need high bandwidth provider for my Asian community site
Hello All If one creates a file outside the web space on a server. How doe's one connect to this from a HTML or PHP page? As I understand it. It is not as simple as normal html link. --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: Webleycity [EMAIL PROTECTED] Date: Sat, 15 Dec 2001 21:44:22 + To: James Stewart [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site What bandwidth would you like? | Website design and hosting. | | Your free website trial including design and webspace, contact: | [EMAIL PROTECTED] Visit: http://www.webleycity.co.uk/offers --- WEBLEYCITY CAN DESIGN YOUR WEBSITE TO YOUR EXISTING CORPORATE IDENTITY OR CREATE ONE FOR YOU --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: James Stewart [EMAIL PROTECTED] Date: Thu, 13 Dec 2001 18:34:31 + To: [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site On Thursday, December 13, 2001, at 06:14 PM, l0t3k wrote: Sunny, AFAICR, br / is for Netscrape, which apparently cant understand br/ for some reason.. It's not a browser thing... br / is the correct syntax for a line break in XHTML. All tags must be closed, hence the / and the white space is necessary to separate the element name from its closure. All major browsers will recognise br but if you want to be XHTML compliant, br / should be used. James. -- James Stewart http://www.britlinks.co.uk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] connect to a file outside the web space.
Hello All If one creates a file outside the web space on a server. How doe's one connect to this from a HTML or PHP page? As I understand it. It is not as simple as normal html link. --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: Webleycity [EMAIL PROTECTED] Date: Sat, 15 Dec 2001 21:44:22 + To: James Stewart [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site What bandwidth would you like? | Website design and hosting. | | Your free website trial including design and webspace, contact: | [EMAIL PROTECTED] Visit: http://www.webleycity.co.uk/offers --- WEBLEYCITY CAN DESIGN YOUR WEBSITE TO YOUR EXISTING CORPORATE IDENTITY OR CREATE ONE FOR YOU --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: James Stewart [EMAIL PROTECTED] Date: Thu, 13 Dec 2001 18:34:31 + To: [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site On Thursday, December 13, 2001, at 06:14 PM, l0t3k wrote: Sunny, AFAICR, br / is for Netscrape, which apparently cant understand br/ for some reason.. It's not a browser thing... br / is the correct syntax for a line break in XHTML. All tags must be closed, hence the / and the white space is necessary to separate the element name from its closure. All major browsers will recognise br but if you want to be XHTML compliant, br / should be used. James. -- James Stewart http://www.britlinks.co.uk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] A primary practicall for the pros- the easiest way to sort files in a directory by name or date.?
Hello friends, Here's the question that's bugging me, explanations are under the - line. How do you 1)Sort files in a directory by date and print/echo into an html format (and the latest article is.) 2)Fastest way to list files by titlePage name/title -- Say you have a directory that you want to sort by date/size/whatever/ What do you think would be the best way to do it? arrays? MYSQL/or other DB? string comparison? other ideas? -- My sysadmin insists on database implementation- however, i have a variety of clients that are scared of databases , or are simply content with the provider they have, that doesn't offer DB (yes, there are those still!) What do you think would be the fastest and easiest way to This is close to the famous resource grabber script, but not quite- we are talking about the basic principles of {parsing a document for certain info and echo/printing it out into html. To keep the long question short- - I, must confess that i have little experience with PHP-programming- the wonderful implementation of php-MySQL and ZEND makes it too easy for me to put everything into a database and forget the whole thing. I believe that this matter is paramount because what we're dealing with is the most fundamental and practicall execution of a site engine/ content management system- i.e . the best and fastest code for sorting a directory by titlesort by html name /title or sort by date It is easily executed by XML or (RDF, etc)but, the question remains -what do you think is the best way to execute the sorting by PHP's sorting abilities? As far as i know, there is no title sorting in php, as opposed to perl/ Am i wrong? -- Best regards, php mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Unable to return object references from functions
Hi Is this doing what you want, seems you have to use an array to create the ref (just getting a handle on objects :) ? class test_class { var $dummy=nothing; }; Function assigning($returned,$copy,$object) { global $success; $object-dummy=original; $success=1; $copy=$object; $copy-dummy=copy; $returned[] = $object; var_dump(In the function,$success,$returned[0],$copy,$object); return $object; } $object = assigning($returned,$copy,new test_class); echo brbr; var_dump(Out the function,$success,$returned[0],$copy,$object); ? At 03:06 PM 15/12/01, you wrote: Hello, I am trying to return a reference from an object created inside a function and at the same time have the object stored in a global variable. It seems that when I try doing it by assigning the object reference to a function argument that is passed by reference, nothing is returned in that variable despite inside the function the argument variable seems to have the right value. Is this a PHP bug or this is not the right way to do it? Try the example below. Manuel Lemos ? class test_class { var $dummy=nothing; }; Function not_assigning($not_returned,$copy) { global $object; $object=new test_class; $object-dummy=original; $success=1; $not_returned= $object; $copy=$object; $copy-dummy=copy; var_dump(In the function,$success,$not_returned,$copy,$object); return $success; } $success=not_assigning($not_returned,$copy); var_dump(Out the function,$success,$not_returned,$copy,$object); ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: PHP list posting confirmation for jtjohnston@courrier.usherb.ca
I have to subscribe to the mailing list now, in order to use the news group? Somebody has some work to do :) Sorry for the hassle, but the volume of unsolicited commercial email sent to PHP mailing lists has made this step necessary. Yeah but it's supposed to be a news server??!! Here's my question: »:) I have a mess of variables I HTML from a couple of different scripts, so I combined them into fields_to_include.inc So now, I do this: $news = mysql_query('select * from ccl where ... order by AU asc'); while ($personne = mysql_fetch_object($news)) { include fields_to_include.inc; } Of course my variables I now call in *.inc do not work. ... So how do I make $personne-AU find it's original value using that *.inc? ---This is my fields_to_include.inc file: -- ? php /* content of fields_to_include.inc global $personne-AU; #dedfinitely does not work I have read the FAQ. */ if($personne-AU != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#AU');\ AU/agt;/b/tdtd.$personne-AU./td/tr\n;} if($personne-ST != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#ST');\ ST/agt;/b/tdtd.$personne-ST./td/tr\n;} if($personne-SD != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SD');\ SD/agt;/b/tdtd.$personne-SD./td/tr\n;} if($personne-SC != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SC');\ SC/agt;/b/tdtd.$personne-SC./td/tr\n;} ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] include help
I have a mess of variables I HTML from a couple of different scripts, so I combined them into an include.inc. But now, when I do this: $news = mysql_query('select * from ccl where ... order by AU asc'); while ($personne = mysql_fetch_object($news)) { include fields_to_include.inc; } of course my variables I now call in *.inc do not work. ... So how do I make $personne-AU find it's original value using that *.inc? ? php /* content of fields_to_include.inc global $personne-AU; #dedfinitely does not work I have read the FAQ. */ if($personne-AU != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#AU');\ AU/agt;/b/tdtd.$personne-AU./td/tr\n;} if($personne-ST != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#ST');\ ST/agt;/b/tdtd.$personne-ST./td/tr\n;} if($personne-SD != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SD');\ SD/agt;/b/tdtd.$personne-SD./td/tr\n;} if($personne-SC != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SC');\ SC/agt;/b/tdtd.$personne-SC./td/tr\n;} ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] connect to a file outside the web space.
how exactly do you want to connect to it? if you want to link to it in html, then it must be under the html doc root...if you're including, then you can specifiy the path... Webleycity wrote: Hello All If one creates a file outside the web space on a server. How doe's one connect to this from a HTML or PHP page? As I understand it. It is not as simple as normal html link. --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: Webleycity [EMAIL PROTECTED] Date: Sat, 15 Dec 2001 21:44:22 + To: James Stewart [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site What bandwidth would you like? | Website design and hosting. | | Your free website trial including design and webspace, contact: | [EMAIL PROTECTED] Visit: http://www.webleycity.co.uk/offers --- WEBLEYCITY CAN DESIGN YOUR WEBSITE TO YOUR EXISTING CORPORATE IDENTITY OR CREATE ONE FOR YOU --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: James Stewart [EMAIL PROTECTED] Date: Thu, 13 Dec 2001 18:34:31 + To: [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site On Thursday, December 13, 2001, at 06:14 PM, l0t3k wrote: Sunny, AFAICR, br / is for Netscrape, which apparently cant understand br/ for some reason.. It's not a browser thing... br / is the correct syntax for a line break in XHTML. All tags must be closed, hence the / and the white space is necessary to separate the element name from its closure. All major browsers will recognise br but if you want to be XHTML compliant, br / should be used. James. -- James Stewart http://www.britlinks.co.uk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Web Based Control Panel for Hosting
I want to implement a web based control panel for updating email accounts, checking account usage for all my hosted clients. Does anybody have any experience? Are there PHP freeware packages out there that do this? Licensed packages? Any recommendations. THanks! JJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] A primary practicall for the pros- the easiest way to sort files in a directory by name or date.?
depends on how elegant you want: passthru(ls -l | awk '{print $9}' );//sort by name ascending passthru(ls -lt | awk '{print $9}' ); //sort by modification time descending add -r to the ls command to reverse the order of either sort instead of using passthru, you could use exec and pipe the information to arrays. - Original Message - From: php [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 5:24 PM Subject: [PHP] A primary practicall for the pros- the easiest way to sort files in a directory by name or date.? Hello friends, Here's the question that's bugging me, explanations are under the - line. How do you 1)Sort files in a directory by date and print/echo into an html format (and the latest article is.) 2)Fastest way to list files by titlePage name/title -- Say you have a directory that you want to sort by date/size/whatever/ What do you think would be the best way to do it? arrays? MYSQL/or other DB? string comparison? other ideas? -- My sysadmin insists on database implementation- however, i have a variety of clients that are scared of databases , or are simply content with the provider they have, that doesn't offer DB (yes, there are those still!) What do you think would be the fastest and easiest way to This is close to the famous resource grabber script, but not quite- we are talking about the basic principles of {parsing a document for certain info and echo/printing it out into html. To keep the long question short- - I, must confess that i have little experience with PHP-programming- the wonderful implementation of php-MySQL and ZEND makes it too easy for me to put everything into a database and forget the whole thing. I believe that this matter is paramount because what we're dealing with is the most fundamental and practicall execution of a site engine/ content management system- i.e . the best and fastest code for sorting a directory by titlesort by html name /title or sort by date It is easily executed by XML or (RDF, etc)but, the question remains -what do you think is the best way to execute the sorting by PHP's sorting abilities? As far as i know, there is no title sorting in php, as opposed to perl/ Am i wrong? -- Best regards, php mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Unable to return object references from functions
Hi again Got a bit sidetracked ... here is your original code :) class test_class2 { var $dummy=nothing; }; Function not_assigning($not_returned,$copy) { global $object; $object = new test_class; $object-dummy=original; $success=1; $not_returned[] = $object; $copy=$object; $copy-dummy=copy; var_dump(In the function,$success,$not_returned[0],$copy,$object); return $success; } $success = not_assigning($not_returned,$copy); echo brbr; var_dump(Out the function,$success,$not_returned[0],$copy,$object); ? At 02:15 PM 16/12/01, Tom Rogers wrote: Hi Is this doing what you want, seems you have to use an array to create the ref (just getting a handle on objects :) ? class test_class { var $dummy=nothing; }; Function assigning($returned,$copy,$object) { global $success; $object-dummy=original; $success=1; $copy=$object; $copy-dummy=copy; $returned[] = $object; var_dump(In the function,$success,$returned[0],$copy,$object); return $object; } $object = assigning($returned,$copy,new test_class); echo brbr; var_dump(Out the function,$success,$returned[0],$copy,$object); ? At 03:06 PM 15/12/01, you wrote: Hello, I am trying to return a reference from an object created inside a function and at the same time have the object stored in a global variable. It seems that when I try doing it by assigning the object reference to a function argument that is passed by reference, nothing is returned in that variable despite inside the function the argument variable seems to have the right value. Is this a PHP bug or this is not the right way to do it? Try the example below. Manuel Lemos ? class test_class { var $dummy=nothing; }; Function not_assigning($not_returned,$copy) { global $object; $object=new test_class; $object-dummy=original; $success=1; $not_returned= $object; $copy=$object; $copy-dummy=copy; var_dump(In the function,$success,$not_returned,$copy,$object); return $success; } $success=not_assigning($not_returned,$copy); var_dump(Out the function,$success,$not_returned,$copy,$object); ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: connect to a file outside the web space.
Are you trying to let the user download the file? if so, can try something like this ? /*Do your login checks here*/ define(\'FILEDIR\', \'/yourdirectory/filesfordownloads/\'); $path = FILEDIR . $file; if(!is_file($path)) { print \File does not exist!\; //header(\Location: error.php\); exit(); } //force download dialog header(\Content-type: application/octet-stream\\n\); header(\Content-disposition: attachment; filename=\\\$file\n\); header(\Content-transfer-encoding: binary\\n\); header(\Content-length: \ . filesize($path) . \\\n\); //send file contents $fp=fopen($path, \r\); fpassthru($fp); ? If one creates a file outside the web space on a server. How doe\'s one connect to this from a HTML or PHP page? As I understand it. It is not as simple as normal html link. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] include
I have a mess of variables I HTML from a couple of different scripts, so I combined them into an include.inc. But now, when I do this: $news = mysql_query('select * from ccl where ... order by AU asc'); while ($personne = mysql_fetch_object($news)) { include fields_to_include.inc; } of course my variables I now call in *.inc do not work. ... So how do I make $personne-AU find it's original value using that *.inc? ? php /* content of fields_to_include.inc global $personne-AU; #dedfinitely does not work I have read the FAQ. */ if($personne-AU != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#AU');\ AU/agt;/b/tdtd.$personne-AU./td/tr\n;} if($personne-ST != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#ST');\ ST/agt;/b/tdtd.$personne-ST./td/tr\n;} if($personne-SD != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SD');\ SD/agt;/b/tdtd.$personne-SD./td/tr\n;} if($personne-SC != ){echotrtdblt;a href=\javascript:displayHelp('codes.htm#SC');\ SC/agt;/b/tdtd.$personne-SC./td/tr\n;} ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Opinions, please
A security question, concerning PHP and overall best practice. I have an application that is used by users that have no control over what version of PHP is on their server. Some versions do not support sessions. So, I am attempting to modify the code to accommodate this and minimize, if not eliminate, the risk of a break-in. Basically, index.php (pageA) can call admin.php (pageB). pageB accepts a userid and password ($user/$pass). At this point, these are form variables that will be passed, via $HTTP_POST_VARS. pageB calls pageC, which verifies the user/pass against a security file. If validated, then pageC is accessed. If not, user is kicked out. No problem so far and no variables have been exposed. But, from pageC, you can go down several paths. Now to the question/opinion. How do I validate, w/o sessions, that pageD or pageE has been entered from pageC and not forged? I can pass the user/pass via a hidden field on the form of pageC, but that exposes it. Philosophically, this may not be a problem, since the user has to go through pageC to get to the other ones anyway. Use referer? That seems like that could easily be forged. Your thoughts? -- Gaylen [EMAIL PROTECTED] Home http://www.gaylenandmargie.com/ PHP KISGB v2.6 Guest Book http://www.gaylenandmargie.com/phpwebsite/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Email class
Could someone recommend a good php email class. Im trying out class.phpmailer.php, but its not jiving right with me... Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Is PHP up to task?
Or... what you can do though it 'post-load' them. Same idea, but stick images that are on other pages in some JS at the _end_ of the HTML and they'll load after the images on that page are complete. That way, the browser is essentially preloading images for the next page the users is likely to visit (while the user is sitting there reading the page...) It isnt appropriate in all situations, but it can be a useful trick... :) -- Shane On Saturday 15 Dec 2001 7:39 pm, René Fournier wrote: What you're saying makes sense--that loading ALL the nav button images for the whole site at once is overkill. In this case, however, it really isn't, since there are just to 'sets' of nav buttons--the top-level set, which needs to be preloaded no matter what page the user is on; and the products subsection set, which SHOULD be preloaded, because every visit will inevitably visit that section (it is the reason why any visits the site). I agree that if there were numerous sub-level 'sets' of nav button images, that loading all of them would be inefficient. ...Rene On Saturday, December 15, 2001, at 02:08 AM, Charles Williams wrote: - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, December 15, 2001 1:27 AM Subject: [PHP] Is PHP up to task? (Now that I have your attention... :-) Here's the situation: All the navigational buttons in the site I'm working on have three different states (for mousovers--normal, mouseover, onClick). What I don't like: When I mouse over one button, it takes a second or two for the page to fetch the mouseover state of the button from the server. Now, normally, I would just write a preloadimages() function in JavaScript and preload all the button states when the pages load. BUT, this is a little harder, since this is a fairly big site (or will be) and it's not always the same buttons that need to be loaded; they can change from page to page (say, between sections, with subnav bars). That being said, I've kept one thing simple: All the buttons (and their states) are stored in the same directory, and in fact only button images are in that directory (/nav). So here's what I would like to know: Is it possible for PHP to read the contents of a directory--all the files--and then take that array and generate some javascript preload() statements? (Of course, I'm sure it IS possible, but I would appreciate any pointers you might have before I undertake it. Maybe there's even a better way than what I can see!) What I was thinking was to preload all the nav buttons and their states in the header.inc. Thanks. ...Rene Rene, Of course this is possible. However, I doubt if it is desirable. The more visitors to your site the larger the load if you load all the graphics, because each session would have it's own copy of all the graphics. It would be better if you checked the page being loaded and passed a list of the needed graphics needed to a function that would load ONLY those graphics needed for said page. This is not too very difficult and if run on a PHP caching server then the overhead is not so bad. The hard part is getting the JS to work correctly (at least for me. hehe. I suck at JS). For example. http://clans.acnsnet.com is a package I'm working on that uses templates to control the layout. Each menu item is stored in an SQL backend as well as the Template info (location, menu type, state, etc). I already have a function to determine what page is active. So finding out what menu items are visible is simply a matter of comparing the active page to the array of menu items. I can then determin which images I would need to load (depending on the template in use). This way I only load the images that are needed, which saves on load time and memory. Anyway, have fun. chuck -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- René Fournier [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Brain dead - need help!
I know that I know the answer - it's just buried in the recesses of my mind .. PHP has the various $HTTP_*_VARS arrays. Is there one to get the formliteral pairs from the hyperlinks, as in a href=somepage.php?var1=test? I want to extract the $var1 value pair. I know I can do this through javascript, but I want somepage.php to parse and use the variable/value. If there is not an array, then what is the simplest way? Thanks! -- Gaylen [EMAIL PROTECTED] Home http://www.gaylenandmargie.com/ PHP KISGB v2.6 Guest Book http://www.gaylenandmargie.com/phpwebsite/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Re: i get a warning after upgrading to 4.1.0 (repost)
This is a known bug with persistent database connections. Switching to non-persistent connections or ISAPI avoids this problem. Phillip Oertel [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... does anyone know what Warning: Unknown persistent list entry type in module shutdown (11) in Unknown means? what do i have to do to solve the problem php seems to have? environment: Win2k, IIS5.0, MySQL just upgraded from PHP 4.0.6 to 4.1.0 now i get the warning msg. any help would be appreciated. kind regards, phil! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Re: Script like this for PHP
Hello, I know less Flash than I do javascript, which is pretty bad. But thanks Indera Dasmeet Singh Arora wrote: You may also try using flash. It looks good and files are small too Peter wrote: The pop outs are done using JavaScript. Its something to do with setting the STYLE=visibility: hidden property of the HTML element. I'm not sure exactly how its done though. If you can get your hands on a copy of IE 4 (or maybe it was IE 3!), this kind of thing was done on the 'friendly error messages'. The code was very simple there and easy to follow through. Indera [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, I came across this FAQ and I really would like to create my FAQ like this one. I was wondering if someone would take a look at this link and let me know how it's created. I looked at the code, but can't figure out how it's done. http://www.installshield.com/ds/info/generalqa.asp Thanks Indera -- http://www.fedoXpress.com Looking for a new email address? http://www.fedoXpress.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Searching for a new provider
Hello, This may sound like a weird question, but since I've seen two posts on it, I have to ask, what is a stingray server? Indera R'Twick Niceorgaw wrote: cool.. I'm also on stingray:) - Original Message - From: Nuitari [EMAIL PROTECTED] To: PHP LIST [EMAIL PROTECTED] Sent: Thursday, December 13, 2001 2:19 PM Subject: RE: [PHP] Searching for a new provider I switched to Aletia in April I believe, and have been pleased. I asked for pdflib to be compiled on the server my site is on (stingray), and they did. It took about 3 days. My server has been up for 52 days 15 minutes, so that is good...however, 2 times in the last 6 months I have been denied access because the server had run out of harddrive space...It seemed like the matter was taken care of relatively promptly though. All in all, Aletia is good bang for the buck. I'm going to stick with them. -Jamison. -Original Message- From: R'twick Niceorgaw [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 12:35 AM To: 'Indera'; [EMAIL PROTECTED] Subject: RE: [PHP] Searching for a new provider Welcome abroad Indrea. But, their support is not the very best in industry. Lately I have seen some detoriation but usually my emails are answered in 1-2 days. Earlier I used to find them almost 24x7 on ICQ and AIM but haven't seen them on line for almost a month now. But all my emails are answered in a day or two. One more thing, I'm very happy with their server up time though. My server has been up for more than 51 days now :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Need high bandwidth provider for my Asian community site
What bandwidth would you like? | Website design and hosting. | | Your free website trial including design and webspace, contact: | [EMAIL PROTECTED] Visit: http://www.webleycity.co.uk/offers --- WEBLEYCITY CAN DESIGN YOUR WEBSITE TO YOUR EXISTING CORPORATE IDENTITY OR CREATE ONE FOR YOU --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: James Stewart [EMAIL PROTECTED] Date: Thu, 13 Dec 2001 18:34:31 + To: [EMAIL PROTECTED] Subject: Re: [PHP] Need high bandwidth provider for my Asian community site On Thursday, December 13, 2001, at 06:14 PM, l0t3k wrote: Sunny, AFAICR, br / is for Netscrape, which apparently cant understand br/ for some reason.. It's not a browser thing... br / is the correct syntax for a line break in XHTML. All tags must be closed, hence the / and the white space is necessary to separate the element name from its closure. All major browsers will recognise br but if you want to be XHTML compliant, br / should be used. James. -- James Stewart http://www.britlinks.co.uk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] __
hello, Testing? Other's message post. Mine are not. NNTP probwlem? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Newbie-student Database PHP Question
SQl Refers to the generic database. Like PostSQl, Oracal etc. mysql 1) Belongs to a group of people that create that database, specific vender that distribute that database that runs on a specific form only. 2) Yes --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: Webleycity [EMAIL PROTECTED] Date: Fri, 14 Dec 2001 07:26:19 + To: [EMAIL PROTECTED] Subject: Re: [PHP] Newbie-student Database PHP Question PLAY A GAME HERE ON http://www.webleycity.co.uk/theblitz.html | Website design and hosting. | | Your free website trial including design and webspace, contact: | [EMAIL PROTECTED] Visit: http://www.webleycity.co.uk/offers --- WEBLEYCITY CAN DESIGN YOUR WEBSITE TO YOUR EXISTING CORPORATE IDENTITY OR CREATE ONE FOR YOU A treat for Powermac users click below to download my screensaver http://www.webleycity.co.uk/mac.zip --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: [EMAIL PROTECTED] Date: Wed, 12 Dec 2001 05:43:30 EST To: [EMAIL PROTECTED] Subject: [PHP] Newbie-student Database PHP Question I have downloaded Mysql to check out. 1) Mysql vs SQL: What is the difference? 2} Would a web-based Access database suffice with PHP? As I already know Access. Appreciate clarification for my newbie questions, thank you. Robin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Webcam on websites? Ugh!!!
Hello All A client wants a webcam on his site. Does any body know what script is used and how it works. Is there anyone out there with experience of this. --- Mark Webley Multimedia design and development WebleyCity Limited London United Kingdom [EMAIL PROTECTED] [EMAIL PROTECTED] Mobile: 07980 213 627 Fax/Tel: 0208 678 1721 Pager 07654 581816 http://www.webleycity.co.uk --- From: Stephen VanDyke [EMAIL PROTECTED] Date: Thu, 13 Dec 2001 12:07:38 -0500 To: [EMAIL PROTECTED] Cc: Stephen VanDyke [NN] [EMAIL PROTECTED] Subject: [PHP] streaming media via php Hello PHP people :) I have a tough one here, I wrote a content script that plays media files, but I can't seem to get things to actually buffer and stream as they should. Here's the conundrum: http://server/media/file.asf - Media player will buffer and start playing before download completes http://server/content.php?f=media/file.asf - Media player has to download entire file before it starts trying to play Here's the source of content.php, anyone see anything obvious that I'm missing? I've been all over the HTTP/1.1 spec and media RFCs trying to figure out what the heck I'm missing. Windows Media Player interprets the media name as content if that's any help. Alse, the mime types are all correct so that's not the issue, I'm just trying to figure out how to make the players buffer+play instead of download+play. ?php $mime_type = strtolower(strrchr($f,'.')); $mime_type_array = array( '.asf' = 'application/vnd.ms-asf', '.avi' = 'video/x-msvideo', '.gif' = 'image/gif', '.jpg' = 'image/jpeg', '.mov' = 'video/quicktime', '.mpe' = 'video/mpeg', '.mpeg' = 'video/mpeg', '.mpg' = 'video/mpeg', '.ra' = 'audio/x-pn-realaudio', '.ram' = 'audio/x-pn-realaudio', '.rm' = 'audio/x-pn-realaudio', '.wmv' = 'audio/x-ms-wmv' ); // this is our security, bleh if(!in_array($mime_type,array_keys($mime_type_array))) { header(Location: /error.php); } $filename = '/path/to/'.$f; $dlname = substr(strrchr($filename,'/'),1); $offset = (isset($nocache)?0:(86400 * 3)); header(Accept-Ranges: bytes); header(Expires: .gmdate(D, d M Y H:i:s \G\M\T, time() + $offset)); header(Cache-Control: max-age=.$offset); header(Last-modified : .gmdate(D, d M Y H:i:s \G\M\T, filemtime($filename))); header(Content-Length: .filesize($filename)); header(Content-Disposition: filename=$dlname); if($debugx==1) { phpinfo(); } else { header(Content-Type: .$mime_type_array[$mime_type]); @readfile($filename); } ? Thanks in advance for any help, Please cc me on any replies since I am not on this mailing list. Stephen VanDyke -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Searching for a new provider
Just name of one of Aletia's servers --- R'twick Niceorgaw 98C Cedar Lane Highland Park, NJ 08904 USA 732-246-1434 (R) 732-801-3826 (M) -- Original Message -- From: Indera [EMAIL PROTECTED] Date: Sat, 15 Dec 2001 23:33:39 -0500 Hello, This may sound like a weird question, but since I've seen two posts on it, I have to ask, what is a stingray server? Indera R'Twick Niceorgaw wrote: cool.. I'm also on stingray:) - Original Message - From: Nuitari [EMAIL PROTECTED] To: PHP LIST [EMAIL PROTECTED] Sent: Thursday, December 13, 2001 2:19 PM Subject: RE: [PHP] Searching for a new provider I switched to Aletia in April I believe, and have been pleased. I asked for pdflib to be compiled on the server my site is on (stingray), and they did. It took about 3 days. My server has been up for 52 days 15 minutes, so that is good...however, 2 times in the last 6 months I have been denied access because the server had run out of harddrive space...It seemed like the matter was taken care of relatively promptly though. All in all, Aletia is good bang for the buck. I'm going to stick with them. -Jamison. -Original Message- From: R'twick Niceorgaw [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 12:35 AM To: 'Indera'; [EMAIL PROTECTED] Subject: RE: [PHP] Searching for a new provider Welcome abroad Indrea. But, their support is not the very best in industry. Lately I have seen some detoriation but usually my emails are answered in 1-2 days. Earlier I used to find them almost 24x7 on ICQ and AIM but haven't seen them on line for almost a month now. But all my emails are answered in a day or two. One more thing, I'm very happy with their server up time though. My server has been up for more than 51 days now :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] using variables
I'm trying to determing why this won't work. I wish to assign graphics to variables then call them within the HTML on my .php pages. --test.php-- ? $ulo = /images/ulo.gif; ? html body img src=?$ulo? /body /html ---end test.php- The resulting output viewing the html source from the browser is: html output-- html body img src= /body /html ---end html output- there is obviously a programming error here, but after hours of trying things I'm just missing what it is. the img src tag should read img src=/images/ulo.gif What am I missing? David. __ Do You Yahoo!? Check out Yahoo! Shopping and Yahoo! Auctions for all of your unique holiday gifts! Buy at http://shopping.yahoo.com or bid at http://auctions.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]