Re: [PHP] echo'ing array contents through reference variable

2002-11-23 Thread Tularis
echo ${$pdag[$n]}; // is also possible in case the [$n] is the index to pdag. Otherwise use this: echo ${$pdag}[$n]; - Tularis PS. This is basicly the same thing as Ernest said, but shorter... Ernest E Vogelsinger wrote: At 16:50 23.11.2002, -<[ Rene Brehmer ]>

[PHP] Re: Keeping script running, but returning control to user?

2002-12-31 Thread Tularis
mited), your script still goes on... While you can follow the other link. The ignore_user_aboort(true), makes sure the server continues till the script finishes. Otherwise it would kill it as soon as you'd press stop on your browser :) Hope that helps, - Tularis Leif K-Brooks wrote: I need

[PHP] Re: loading a db table into a php array from mysql

2002-12-31 Thread Tularis
Usually, using mysql to handle your tables is *way* faster than letting php handle it. That's what it was made for, speed...! In your case, you could just do a complex join I think. That would give all results in one table, and you could just order that on scheduletime, and voila, you'd have

[PHP] Re: Securing areas of a web site with PHP

2003-01-01 Thread Tularis
#x27;t cache it *at all*. This can be done using (one, or more) of the following headers: // HTTP 1.1 compliant: header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", false); // HTTP 1.0 compliant: header("Pragma: n

[PHP] Re: email/time question

2003-01-03 Thread Tularis
also something that is really NOT recommended to do with php. The other possiblity is to set a cron job to fire up a script which will send the email. - Tularis Randy Johnson wrote: Here is what i need to do. I have a form where a user will submit, email address, email text and a time like 11

Re: [PHP] Avoiding Repeat Posts

2003-01-04 Thread Tularis
time of posting is kept. When you post the next thing, the script checks if there was a message posted, by that user in the last X seconds (can be set manually). If so, it will return a message saying not to repost stuff. Otherwise, it just continues... Hope this helps, - Tularis XMB Lead Deve

[PHP] Re: security in guest book and user forums

2003-01-04 Thread Tularis
most forums do this Seraphim wrote: Anders Thoresson wrote: I've seen both guest books and user forums "hacked" by users who enter javascript or other code, and that way redirects vistors to other sites or do other unwelcome things. What expressions should I look for and not allow in my forms

Re: [PHP] No Global Code Fixing

2003-01-04 Thread Tularis
NOTE: this basicly mimics the way register_globals works. I use this code to fix register_globals aswell as the magic_quotes_gpc: $global = @array($_SESSION, $_SERVER, $_COOKIE, $_POST, $_GET, $_FILES, $_ENV); $global_old = @array($HTTP_SESSION_VARS, $HTTP_SERVER_VARS, $HTTP_COOKIE_VARS, $HTTP

[PHP] memory exhausted... memory leak?

2003-01-24 Thread Tularis
I was wondering if this would be a memroy leak? or just some standard notice that I'm taking up too much memory ;) Anyone? - Tularis -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] memory exhausted... memory leak?

2003-01-25 Thread Tularis
RROR', 2=> 'WARNING', 3 => 'MINOR ERROR', 4=> 'NOTICE' ); if($which=='all'){ foreach($this->cache as $cache){ $errors = explode('-|-', $cache); $type=

[PHP] mod_rewrite rules for the php.net rewritten urls

2003-06-07 Thread Tularis
I was wondering where I could get the rewrite urls for the rewriting of urls like here on php.net. - Tularis P.S. I don't think they're in the phpweb on CVS, I checked that already -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] __FILE__ plus variables?

2003-06-28 Thread Tularis
David Nicholson wrote: Hello, This is a reply to an e-mail that you wrote on Sat, 28 Jun 2003 at 13:16, lines prefixed by '>' were originally written by you. I have a password protected site. If you go to an inside page before logging in, it redirects you to the log in page. I would like to grab

[PHP] pspell

2003-06-28 Thread Tularis
does anyone know how to check what Dictionaries for pspell/aspell are present on the system? since I will need to do that dynamically ;) thanks - Tu -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] parsing problem

2003-06-28 Thread Tularis
David Otton wrote: On Sat, 28 Jun 2003 12:33:27 +0200, you wrote: I have problem in including this text in my PHP parsed file for XHTML definition: It works if I remove the first line: So, I am assuming PHP has problems with the symbols, as they are recognised to be PHP code delimiters.

[PHP] Re: session handling works on local server, but not when uploadedto ISP

2003-06-28 Thread Tularis
... and line 5 of reporter_view.php reads what? =/ Anders Thoresson wrote: Hi, I've a login script that works fine on my local server, but when I runs it from my ISP I get the following error: Warning: Cannot send session cookie - headers already sent by (output started at /export/home/thore/pu

[PHP] Re: differences in session handling between 4.1.1 and 4.3.1

2003-06-28 Thread Tularis
I would also advise to check for register_globals, since I have the faint feeling it was OFF on your old version and ON in your new (though most logcial would be viceversa :P) Bobby Patel wrote: maybe compare the php settings for both servers (using phpinfo()). Also check the register globals s

[PHP] Re: Else If/Elseif

2003-06-30 Thread Tularis
Stevie Peele wrote: What is the difference between "else if" and "elseif"? Thanks _ STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail else if shouldn't be used, use elseif, and th

[PHP] Re: passing multiple variables in a url

2002-11-14 Thread Tularis
with all the url parts in it, numbered from 0->n the htmlentities() makes sure that all html compatible chars get transformed in to others, which look the same but don't work as html (eg » and such). Hope this helps, - Tularis XMB Lead Developer Cj wrote: I have a "contact us&qu

[PHP] OOP-related question

2002-11-14 Thread Tularis
alues of the vars to a specific one, without calling for something weird... anyway, it doesn't work, and it doesn't spit out an error either. Any ideas? - Tularis -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] OOP-related question

2002-11-14 Thread Tularis
lass; HTH, Danny. - Original Message ----- From: "Tularis" To: Sent: Thursday, November 14, 2002 8:18 PM Subject: [PHP] OOP-related question >Hey, >I have the following script: >class overall { > >function overall(){ >$this->loaded['overall'] =1; > >function

[PHP] Re: PROBLEMS

2002-11-14 Thread Tularis
all header-modifying functions should be BEFORE any echoing is done, so: session_start(); if(!session_is_registered("camion")) DIE("error"); should be BEFORE: Ysrael guzmán wrote: THIS IS MY SCRIPT: AND THE ERROR IS Warning: Cannot send session cache limiter - headers already sen

[PHP] OOP-classes in PHP

2002-11-17 Thread Tularis
the object is loaded, because the constructor is run, and puts out a 1 onscreen... I wish to know how to make this work... any help plz? thanx - Tularis class overall { var $loaded; function load($class){ eval("\$$class = new $class;"); return true; } } class foo { var $

[PHP] OOP - transfering object-pointer

2002-11-19 Thread Tularis
l->foo->bar() to $foo->bar(); as all the things I've tried, don't work, they don't give any errors, except for Fatal error: Call to a member function on a non-object in d:\apache\htdocs\classes.php on line 42... Could anyone help me with this? thanx - Tularis -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: OOP - transfering object-pointer

2002-11-19 Thread Tularis
actually, the foreach should read: foreach($overall->loaded as $key=>$val){ $val =& $overall->$val; } still doens't work though Tularis wrote: Currently, I have the following code: loaded[] = $class; eval("\$this->$class = new $class;");

[PHP] Re: problem with code (almost fixed)

2002-11-19 Thread Tularis
Yan Grossman wrote: Hi, I fixed my code to handle forms using $_REQUEST. Just having problem with the fields with multiple contents... the one you have to call like field[0], field[1],etc... How do I use the brackets inside brackets? my case is this: Thanks. I have fixed everything with $_REQUE

[PHP] Re: What is the best site for PHP news, articles, resources etc....

2002-11-19 Thread Tularis
Phil Schwarzmann wrote: Let's say you had one site and one site only to get the latest PHP/MySQL news, articles, reviews, resources, tutorials, advanced stuff etc. What would it be?!? zend.com :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/

[PHP] Re: Display character 'x' times

2002-11-19 Thread Tularis
Tjoumaidis Tasos wrote: Hello to everybody, I just want to display a character like D x times like DDD where x is a $variable i get from the database i cannot make it work like it is on perl (i don't even know if it is working the same way) and i can't find a reference in the manual on php.net,

[PHP] this oop-script still doesn't work

2002-11-19 Thread Tularis
ok, I have gotten great help here already, but it still doesn't work, it returns a object not found error (on the $foo->bar() line). I want to change $overall->foo->bar() to $foo->bar... any tips? or help?? thanx! - Tularis class overall { var $loaded; function loa

[PHP] show mysql- processing time

2002-11-21 Thread Tularis
I was wondering if anyone knew of a way to return the processing time of a mysql query via php. And NOT using the $starttime = time(); mysql_query($whatever); $endtime = time(); $processingtime = $endtime - $starttime; Does anyone please? -- PHP General Mailing List (http://www.php.net/)

[PHP] Re: HTML page and php

2002-11-21 Thread Tularis
ey => $val){ echo "$val\r\n"; } /* $file will be an array where each index corresponds with a line from the file. so: 1 => 2 => 3 => blah etc. Hope that helps - Tularis -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] show mysql- processing time

2002-11-21 Thread Tularis
to do this in PHP. :-) I would recommend Jeremy Zawodny's mytop: http://jeremy.zawodny.com/mysql/mytop/ Chris --- Tularis wrote: >I was wondering if anyone knew of a way to return the processing >time of a mysql query via php. > >And NOT using the > >$starttime = time();

[PHP] Re: php programming style

2002-11-21 Thread Tularis
why wouldn't it be?? it's clean code as long as you can read it without having to do much trouble, and you have written it the shortest way possible with still enough extra stuff around to make other ppl understand it... so, I would say -> yeah, it's clean :) - Tularis Bea

[PHP] Re: If...Or...Else

2004-07-24 Thread Tularis
if(a OR b) { do something } else { do something else } or if(a || b) { do something } else { do something else } is enough :) Robb Kerr wrote: From time to time I need an If statement that includes an Or condition... What's the correct syntax for the If line? Thanx -- PHP General Mailing List

[PHP] Re: HTML Table display based upon field contents

2004-07-24 Thread Tularis
Robb Kerr wrote: I have a complicated table that needs to be altered depending upon the contents of a field in one of my recordsets. I've tried several approaches and need to know what you recommend. I've created three totally different tables and put the HTML code for each into a database. Then I

[PHP] Re: HTML Table display based upon field contents

2004-07-24 Thread Tularis
Robb Kerr wrote: On Sat, 24 Jul 2004 23:23:49 +0200, Tularis wrote: Robb Kerr wrote: I have a complicated table that needs to be altered depending upon the contents of a field in one of my recordsets. I've tried several approaches and need to know what you recommend. I've created thr

Re: [PHP] PHP5 exception handling

2004-07-30 Thread Tularis
Matthew Weier O'Phinney wrote: * Curt Zirzow <[EMAIL PROTECTED]>: * Thus wrote Matthew Weier O'Phinney: The problem I'm running into: what do I pass as arguments to catch()? The articles on ZE2 use something like: catch (Exception $e) {}, or something like catch(MyException $e) (where MyException i

Re: [PHP] db transactions across multiple pages...

2004-07-31 Thread Tularis
you could write such a thing, in php, yourself aswell... wouldn't be that hard :) - Tul Bruce wrote: yeah... i saw that write up. i've also inquired with bugs.mysql as to if/whether this might be reinserted.. we'll see. that said, it appears that there would need to be an approach similar to the

[PHP] Re: Mail() not working

2004-07-31 Thread Tularis
Robin Wilson wrote: Hi I get the following error message: Fatal error: Call to undefined function: mail() in /srv/www/htdocs/blog/serendipity_functions.inc.php on line 1394 I have changed my php.ini file to find the correct path to sendmail and to put an option on the end (-f [EMAIL PROTECTED]) to

Re: [PHP] custom tags

2004-07-13 Thread Tularis
Eric Emminger wrote: Hi George, How about this? parse the html as xml and replace the component tags with whatever php/html code output that result to a file include the file from previous step Eric On Tue, 6 Jul 2004 15:56:26 -0500, George Lantz <[EMAIL PROTECTED]> wrote: I am looking for a way to

[PHP] Re: convert degrees to heading

2004-07-16 Thread Tularis
Here's a quick script I wrote for it: $deg = $_GET['deg']; // get from URL, for testing atm $deg %= 360; // make sure it doesn't break on eg 560 degrees $deg = ((ceil(($deg-22.5)/45))*45+22.5); // break it up into parts we know, there might be an easier way though, just too tired to see it. swit

[PHP] Re: How can I tell if a path is absolute?

2004-07-17 Thread Tularis
Trejkaz Xaoza wrote: Michael Ochs wrote: Hi, maybe you could try it with regular expressions! "[A-Z]:\\" or better "[C-Z]:\\" because A and B is used just for floppy drives... Take a look at www.php.net/preg_match/ I'm not sure if you noticed, but I said I wanted it to be portable. Sure, "([A-Za-z

[PHP] Re: Book Required

2004-07-17 Thread Tularis
Programming PHP by O`Reilly :) Lester Caine wrote: Harlequin wrote: There's loads and loads of books available on the subject of PHP & MySQL. It would be nice to find one's that DON'T rely on MySQL ;) Does anyone have any recommendations...? Anybody seen a good NON MySQL one. -- PHP General Maili

[PHP] Re: Using and Echoing Session Variables

2004-07-18 Thread Tularis
you need to call session_start() on every page, yes. Also, if you're bored with assigning values like that, and you're sure you're not overwriting anything, you could try: $_SESSION = array('UserId'=>'userid', 'Authorised'=>'yes','etc'=>'blah'); However, remember that you don't need to REassign v