Jump to content

peeper

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Everything posted by peeper

  1. Thanks for that, frost110. The article on search engine-friendly URIs is interesting and goes some way to explain the URI processing rules of Apache + PHP. I have tried a variety of "search engine-friendly" URIs to see how they are processed. However, to ensure I don't miss any tricks, I would really like to see a canonical definition of the rules that PHP (and/or Apache) applies to URIs of the form we're talking about here. Any suggestions or references? Thanks, Peeper.
  2. Your warning message: is issued because you're trying to change HTTP headers after the server has started to deliver the payload (HTML content) of the response. That's usually due to you already having used something like echo() before adding your redirect header. The suggestion to issue a redirect to the browser, to do a GET, after your POST processing, is a well known design pattern that goes by a variety of names. This article might be a good starting point for you: http://en.wikipedia.org/wiki/Post/Redirect/Get Cheers, Peeper.
  3. Hi, Say I have a web application called web-app running on server and it contains an index.php file in the application's root directory. Can anyone explain why PHP passes a URI of the following form http://server/web-app/index.php/extrastuff to the index.php file under the application's root, rather than an index file under the (non-existent) /index.php/extrastuff/ directory? I've looked in the PHP documentation and can't find any PHP URI processing rules that deals with this type of URI. Can anyone point me to resources that explain PHP URI processing behaviour dealing with this stuff, please? Thanks, Peeper.
  4. Thanks for your response, but that doesn't answer my question. The question is primarily one of how to use a member attribute when that attribute is itself a user-defined class. Any further help would be welcome. BTW, the version of PHP is out of my hands. PHP 4 is the only version that is available to me. Thanks, Peeper.
  5. Hi, I'm finding problems using classes in php4 (I'm used to strongly typed languages - C++ and Java). Here's a piece of code that roughly demonstrates what I'm trying to do: [code] class A {   function doItToA($aString)   {     echo($aString);   } } class B {   var $a;   function B(&$a)   {     $this->a = $a;   }   function doItToB($aString)   {     $this->a->doItToB($aString);   } } // ... $a = &new A(); $b = new B($a); $b->doItToB("random text here"); [/code] Now the problem is that the parameter, "random text here", that I pass into the call $b->doItToB("random text here") doesn't appear to make it's way through to doItToA($aString) - the text "random text here" isn't echoed as I would expect it to. I haven't seen any examples of objects (such as the instance of B, above) being used as member attributes within classes. I expect I don't have a full grasp of on way classes work in PHP. Any guidance on what the problem might would be much appreciated. Thanks, Peeper.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.