[PHP] how to read the path of the current document's url

2005-01-08 Thread Tim Burgan
Hello, I have a page where the URL is along the lines of http://www.example.com/test.php I've tried using the parse_url() function without success.. I'm trying to just get "test.php" returned as a string. Can someone please point me in the right direction with this. Thank you for your time. Tim

[PHP] Problem with WHILE using MYSQL database

2005-01-08 Thread Labunski
Hi, this script output's data from the database.. $data = mysql_query("SELECT * FROM firt_table WHERE cat='sweaters' ORDER BY `id` ASC ") or die("can't find DB!"); while($line = mysql_fetch_array($data)){ echo' '; } for example, there are 3 records in the "first_table", so script will output only

[PHP] where can i find some tutorials aout sockets ?

2005-01-08 Thread Serban Nicolae
where can i find some tutorials aout sockets ?

RE: [PHP] sending multiple headers (session_start() and setcookie() )

2005-01-08 Thread Hans Zaunere
> In my .php file, I'm using both session_start() and setcookie() before > tag. It gives me following warning message: >=20 > Warning: Cannot modify header information - headers already sent by > (output started at D:\Apache Group\Apache2\htdocs\YC\songs.php:4) in > D:\Apache Group\Apache2\htdocs

[PHP] sending multiple headers (session_start() and setcookie() )

2005-01-08 Thread Ben
Hi all, In my .php file, I'm using both session_start() and setcookie() before tag. It gives me following warning message: Warning: Cannot modify header information - headers already sent by (output started at D:\Apache Group\Apache2\htdocs\YC\songs.php:4) in D:\Apache Group\Apache2\htdocs\YC\yc

[PHP] How do I start at a specific position in an array? Is there a function?

2005-01-08 Thread Brent Clements
I know this is a simple question because I could easily write a loop to move to the specific position in the array, but I want to know is there a function to move the array pointer position to a specific position in the array? Thanks, Brent -- PHP General Mailing List (http://www.php.net/) To un

Re: [PHP] On large application organization [long and possibly boring]

2005-01-08 Thread Josh Whiting
> Josh, I am interested in what you mean by "but there may be a better > overall approach." (which was in reference to my original question which was: why are you using a big switch?) The reason I say that is because, though I'm no expert on application design, in my own code I've found that whe

[PHP] "*** glibc detected *** double free or corruption:" error

2005-01-08 Thread Alex Greg
Hi, Recently I migrated the front-end of our bulletin board (running phpBB, patched against the recently highlight vulnerability) to a pair of servers running Fedora Core 3. I compiled Apache 1.3.33 and PHP 4.3.10 from source. The MySQL database is running on a separate machine. This morning, the

[PHP] Re: Problem with MySQL

2005-01-08 Thread JHollis
Try running mysqld without the -opt. Check out this site www.apachefriends.org it has a great all in one package that can be installed on Windows and Linux. If you install it on Windows it has the option to setup mysql and apache to run as services. This XAMPP package is a no brainer!! Hop

[PHP] Problem with MySQL

2005-01-08 Thread Andrew Maxwell
Hello, Im fairly new to PHP and I am running an Apache web server on my computer, set up as localhost, and i recently installed MySQL 4.1 . I am having trouble making a DB and a table in the DB. when i try to create it from a command prompt it tells me this: C:\mysql\bin>mysqld-opt C:\mysql\bin>

Re: [PHP] Persistent PHP web application?

2005-01-08 Thread Rasmus Lerdorf
Xuefer Tinys wrote: even apc/eAcc have to copy from shm to php-memory(alloc by emalloc), because $array might be modified anytime i'd guess this is almost same as serialize/unserialize You greatly underestimate how slow unserialize is. -Rasmus -- PHP General Mailing List (http://www.php.net/) To un

Re: [PHP] Which script runs first?

2005-01-08 Thread Curt Zirzow
* Thus wrote [EMAIL PROTECTED]: > Hi there! > > I have two frames, one with left.php in the left frame and one with > main.php in the right frame. > > I refresh the contents of main.hp at the end of left.php. (With help of > Javascript actually, maybe could be done with HEADER(...)) > > My Ques

Re: [PHP] PHP 5 confusion

2005-01-08 Thread Curt Zirzow
* Thus wrote Don: > Hi, > > Reading the PHP 5 documentation at: HYPERLINK > "http://www.php.net/manual/en/language.oop5.basic.php"http://www.php.net/man > ual/en/language.oop5.basic.php, I am confused. After looking at the example output, it is not correct, the real output should be: object(S

Re: [PHP] Writing mulitple output lines to single line

2005-01-08 Thread Jason Wong
On Sunday 09 January 2005 01:01, Robert M. Pufky wrote: >I current have a php script that processes many files (6000+). When > it is processing a file, it prints out what is going on with each file > to a seperate line. What I want to do is OVERWRITE the output line for > each file, and keep

Re: [PHP] Which script runs first?

2005-01-08 Thread Rory Browne
I don't know much about frames(I hate the things), but the only thing I'd count on would be that the main frame will be loaded first. would it be possible to load your session variables in this? Another possibility would be to have the left frame do the loading of variables, and have the frame on

Re: [PHP] Re: Pagination Optimization

2005-01-08 Thread Curt Zirzow
* Thus wrote Bruno B B Magalhes: > Thanks for your help, in fact helped a lot... Now my function only > performs 2 queries, here it is: > > === > function fetch_paginated($query='',$page=1,$itens=20) > { > $this->query($query); This h

Re: [PHP] Persistent PHP web application?

2005-01-08 Thread Xuefer Tinys
even apc/eAcc have to copy from shm to php-memory(alloc by emalloc), because $array might be modified anytime i'd guess this is almost same as serialize/unserialize i doubt if there's anyway to have 1 memcpy $array<-from/to->shm, php will release 1 element of $array when the element is unset(refcou

[PHP] Re: Multiple POP accounts on Webmail Front

2005-01-08 Thread JHollis
James Nunnerley wrote: Hi All, Bit of a side question, but it's still php related. Does anyone know of a Webmail client, preferably open-source, that is able to support single login, to allow users to collect and use multiple POP3 or IMAP accounts? I'm currently using Ilohamail, and have u

[PHP] Writing mulitple output lines to single line

2005-01-08 Thread Robert M. Pufky
Hello all, I have tried looking through the previous messages, but I have yet to find anything that involves my specific problem. Maybe I am not searching for the correct terminology. I current have a php script that processes many files (6000+). When it is processing a file, it prints ou

RE: [PHP] Persistent PHP web application?

2005-01-08 Thread Lance Lovette
I wrote a PHP extension a while ago that implements "executor" persistence for scalar variables and constants. I never looked much into persisting objects, arrays or resources but it would be a useful addition to the extension if someone wants to contribute. I haven't updated the Web site with the

[PHP] Re: PHP any Mysql connection- new b

2005-01-08 Thread M. Sokolewicz
php 3.0???! man, you seriously need to think about upgrading :| PHP 3 is seriously outdated - tul Babu wrote: Hi all, I am using php 3.0 and mysql and win xp. i want to add users to database through php page. adduser.php Real Name: Username: Password: when i enter the fileds

Re: [PHP] Re: Pagination Optimization

2005-01-08 Thread M. Sokolewicz
and now a few small comments to your code ;) Bruno B B Magalhães wrote: Thanks for your help, in fact helped a lot... Now my function only performs 2 queries, here it is: === function fetch_paginated($query='',$page=1,$itens=20) { $this->query($

Re: [PHP] PHP Help

2005-01-08 Thread tr
TonyC wrote / napísal (a): I have used Dreamweaver 4.0 for editing my html files and love its 'design view; so I know exactly what the file looks like before I upload to the server. We currently now are incorporating a shopping cart into our site and the files are in 'php' format. When I open a

[PHP] PHP any Mysql connection- new b

2005-01-08 Thread babu
Hi all, I am using php 3.0 and mysql and win xp. i want to add users to database through php page. adduser.php Real Name: Username: Password: when i enter the fileds and submit ,the action is not performed, instead add.php file is opened. add.php User not added: ", mysql_e

Re: [PHP] Persistent PHP web application?

2005-01-08 Thread Josh Whiting
On Thu, Jan 06, 2005 at 08:41:57PM -0500, Jason Barnett wrote: > >Does "not up to date" mean the code isn't working with current releases > >of php 4 or 5? I'd be interested in giving it a try. > > I believe this is the case. AFAIK the APC library doesn't support PHP5 > or at least it didn't when

[PHP] PHP Help

2005-01-08 Thread TonyC
I have used Dreamweaver 4.0 for editing my html files and love its 'design view; so I know exactly what the file looks like before I upload to the server. We currently now are incorporating a shopping cart into our site and the files are in 'php' format. When I open a 'php' file in Dreamweaver

Re: [PHP] Re: Pagination Optimization

2005-01-08 Thread Bruno B B Magalhães
Thanks for your help, in fact helped a lot... Now my function only performs 2 queries, here it is: === function fetch_paginated($query='',$page=1,$itens=20) { $this->query($query); $total_rows = $this->num_rows();

[PHP] Not about PHP, more about this list...

2005-01-08 Thread gustav
Hi there! I'm wondering. Why don't I see my own posts in the list? I have to guess that the mail has arrived correctly to the list. I only see them when someone has posted and replied on my questions... /G @varupiraten.se -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Using the OR operator in an IF statement

2005-01-08 Thread Jason Wong
On Saturday 08 January 2005 19:02, Tim Burgan wrote: > Can someone please correct me on my efforts below. > If I have a condition where I want to test if a variable is not equal to > "student", "staff", or "admin".. what's the simplest was to achieve that? > > Here's what I tried.. that didn't wor

[PHP] Re: Using the OR operator in an IF statement

2005-01-08 Thread Greg Beaver
Tim Burgan wrote: Hello, Can someone please correct me on my efforts below. If I have a condition where I want to test if a variable is not equal to "student", "staff", or "admin".. what's the simplest was to achieve that? Here's what I tried.. that didn't work: if ( ($_POST['usertype'] != "st

Re: [PHP] Which script runs first?

2005-01-08 Thread Rens Admiraal
The way frames are loaded is actually dependent of many things I think (size and browser e.g.), so, most secure is to use javascript, or, let PHP check if the var is set, and if not, reload... you can do this like this: javascript: left.php: // can be a little different, but I think it is corr

[PHP] Using the OR operator in an IF statement

2005-01-08 Thread Tim Burgan
Hello, Can someone please correct me on my efforts below. If I have a condition where I want to test if a variable is not equal to "student", "staff", or "admin".. what's the simplest was to achieve that? Here's what I tried.. that didn't work: if ( ($_POST['usertype'] != "student") || ($_POST

[PHP] Which script runs first?

2005-01-08 Thread gustav
Hi there! I have two frames, one with left.php in the left frame and one with main.php in the right frame. I refresh the contents of main.hp at the end of left.php. (With help of Javascript actually, maybe could be done with HEADER(...)) My Question: Is it ALWAYS so that left.php must be execut