Re: [PHP] Reverse effect of htmlspecialchars

2001-12-25 Thread Philip Olson


> Anyway to reverse the effect of htmlspecialchars?

See the docs found here:

  http://www.php.net/manual/en/function.get-html-translation-table.php

Shown there is a way to do this.

Regards,
Philip Olson


-- 
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: Re: Re: [PHP] 4.10 New Vars Question

2001-12-25 Thread David

 ok, thanks Phillips!

>The new vars will be listed and described in the manual >eventually (fairly soon). 
>For now, read the above release >notes. 


-- 
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] gd_installation......................... :(

2001-12-25 Thread EMIN CALIKLI


Hi Brian ,
I don't have any file like ph_gd.dll .



   
 
Brian Clark
 
  
werks.com>cc:  
 
  Subject: Re: [PHP] 
gd_installation. :(
25.12.2001 
 
18:45  
 
   
 
   
 




* EMIN CALIKLI ([EMAIL PROTECTED]) [Dec 25. 2001 05:20]:

> Hi Brian ,

Hiya.

> Thanks for your requests . I 'm using php 4.0.6 + IIS 4.0 (Web Server) . I tried 
>many verisons of
GD
> library and failed. Did anyone tried php-4.1.0 verison on IIS 4.0 ? By the way Brian 
>I configured
my
> local workstation with Apache 1.3.22 + php 4.0.6 and it works fine. I can use it GD 
>extension. But
I
> must run GD on IIS don 't ask me why ? This is companies strategy . So I think I 
>must work hard to
> solve it.
> Thanks again.

What happened when you renamed the ph_gd.dll file to php_gd.dll? Did you
try that?

--
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
The beatings will continue until morale improves.


--
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] Hosting advise

2001-12-25 Thread Boaz Yahav

Check out : 

http://www.weberdev.com/index.php3?GoTo=phenominet/prices.htm

This is your one stop shop for hosting. WeberDev.com is hosted there
and I can tell you that their service is amazing. They are fast,
reliable
and more than anything, very professional (specially in PHP / MySQL).

Sincerely

  berber

Visit http://www.weberdev.com Today!!! 
To see where PHP might take you tomorrow.


-Original Message-
From: Indera [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 26, 2001 12:03 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Hosting advise


Hello,

I need to find a new host that is relatively in-expensive and found
these three. I was wondering if
anyone here has used them or thinks that they are a good company.

http://www.aletiahosting.com/

http://www.cobaltconnection.com/

http://www.primemaster.com/index2.html

Thanks
Indera




-- 
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] Reverse effect of htmlspecialchars

2001-12-25 Thread phantom

Anyway to reverse the effect of htmlspecialchars?

Reason: to send an email message where " is shown as " and not 
" LOL

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: Re: [PHP] 4.10 New Vars Question

2001-12-25 Thread Philip Olson

> hmm, now that i\'m trying to program with register_globals=off, what
> is the new $HTTP_SESSION_VARS?

$HTTP_SESSION_VARS works, as will $_SESSION (after 4.1.0).  These
"special" PHP variables are described in the manual:

  http://www.php.net/manual/en/language.variables.predefined.php

Some words specific to $_SESSION are available within here:

  http://www.php.net/release_4_1_0.php

An excerpt:


Another neat trick is that creating new entries in the $_SESSION array
will automatically register them as session variables, as if you called
session_register(). This trick is limited to the session module only - for
example, setting new entries in $_ENV will *not* perform an implicit
putenv().

 
> maybe there should be a page in the online manual describing these new 
> variables for easy reference after all, i can\'t find reference to
> them other than those on the changelog too.

The new vars will be listed and described in the manual eventually (fairly
soon).  For now, read the above release notes.


Regards,
Philip Olson


-- 
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: Re: [PHP] 4.10 New Vars Question

2001-12-25 Thread David

 hmm, now that i\'m trying to program with register_globals=off, what is the new 
$HTTP_SESSION_VARS?

maybe there should be a page in the online manual describing these new variables for 
easy reference after all, i can\'t find reference to them other than those on the 
changelog too.

thanks
David
>
>Two items in the new 4.10 change-log caught my attention: 
>
>* Introduced a new $_REQUEST array, which includes any >GET, POST or 
>COOKIE variables. Like the other new variables, this >variable is also 
>available regardless of the context. (Andi & Zeev) 
>* Introduced $_GET, $_POST, $_COOKIE, $_SERVER and $_ENV >variables, which 
>deprecate the old $HTTP_*_VARS arrays. In addition to be >much shorter to type - 
>these variables are also available >regardless of the scope, and there\'s no need to 
>import >them using the \'global\' statement. (Andi & Zeev) 
>
>However, I can\'t seem to find any documentation regarding >these variables on the 
>php.net site. Any pointers? Am I >missing something obvious? 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] Client side fatal PHP error

2001-12-25 Thread Andrew Brampton

because the way && is evaluated.

if the first part of the && expression is false, then it doesn't even
attempt to look at the second part, meaning you get a fastest evaluation
:)...

I think its called Lazy Logic or something, I know its in the PHP Manual
somewhere :)

Andrew
- Original Message -
From: "jjt" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, December 26, 2001 1:53 AM
Subject: Re: [PHP] Client side fatal PHP error


> Ah yes... that would do it. How embarrassing! But another respondent
brought
> up an interesting question. Why does this error not show up every time? As
> written, it is a basic syntactical error. I tested this thing up and down;
I
> test it in production every day.
>
> Ah it's always something thanks much.
>
>
> Philip Olson wrote in message ...
> >> "Call to unsupported or undefined function srtoupper() in on line
> 82."
> >
> >srt != str (typo).
> >
> >> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
> >> strtoupper(substr($xmbrcode,11,1)) != "P" &&
> >> srtoupper(substr($xmbrcode,11,1)) != "H" &&
> >> srtoupper(substr($xmbrcode,11,1)) != "O") {
> >
> >See above.  Btw, consider something like:
> >
> >  $str = '123456789abcdef';
> >  $bad = array('B','P','H','O');
> >
> >  if (in_array(strtoupper($str{11}),$bad)) {
> >  echo 'boo';
> >  }
> >
> >I can't believe people code on Christmas :)
> >
> >Warm regards,
> >Philip Olson
> >
>
>
>
> --
> 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] 4.10 New Vars Question

2001-12-25 Thread Philip Olson

because they are not documented yet, but, will be.  there really is
nothing else to say besides what you quoted, they act like their
counterparts except these new ones are global.

by counterparts i mean _GET == HTTP_GET_VARS so the manual entries on
those will apply.  see the predefined variables section of manual and
phpinfo().

regards,
Philip Olson


On Tue, 25 Dec 2001, Edward Marczak wrote:

> Hello!
> 
> Two items in the new 4.10 change-log caught my attention:
> 
> *Introduced a new $_REQUEST array, which includes any GET, POST or
> COOKIE variables. Like the other new variables, this variable is also
> available regardless of the context. (Andi & Zeev)
> *Introduced $_GET, $_POST, $_COOKIE, $_SERVER and $_ENV variables, which
> deprecate the old $HTTP_*_VARS arrays. In addition to be much shorter to
> type - these variables are also available regardless of the scope, and
> there's no need to import them using the 'global' statement. (Andi & Zeev)
> 
> However, I can't seem to find any documentation regarding these variables on
> the php.net site.  Any pointers?  Am I missing something obvious?  Thanks!
> 
> -- 
> Ed Marczak
> [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] Client side fatal PHP error

2001-12-25 Thread Ken

At 08:53 PM 12/25/01 -0500, jjt wrote:
>Why does this error not show up every time?

It will show up every time PHP attempts to call the (incorrect) function.  But the 
functions won't be called every time.

For example, due to short-circuit evaluation, if the string is "B" or "P", the error 
will never happen.

Also, if your if statement isn't always reached, then the error will not happen.  
Finally, not all users will report the error when they get it.  But you can deal with 
that by looking at your PHP error log file.

I believe there is a way to call PHP from the command line and do a "syntax check" on 
a given file.  But I have never tried it and I have no idea if it really works.  Check 
the manual.

- Ken
[EMAIL PROTECTED]

> >> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
> >> strtoupper(substr($xmbrcode,11,1)) != "P" &&
> >> srtoupper(substr($xmbrcode,11,1)) != "H" &&
> >> srtoupper(substr($xmbrcode,11,1)) != "O") {


-- 
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] 4.10 New Vars Question

2001-12-25 Thread Edward Marczak

Hello!

Two items in the new 4.10 change-log caught my attention:

*Introduced a new $_REQUEST array, which includes any GET, POST or
COOKIE variables. Like the other new variables, this variable is also
available regardless of the context. (Andi & Zeev)
*Introduced $_GET, $_POST, $_COOKIE, $_SERVER and $_ENV variables, which
deprecate the old $HTTP_*_VARS arrays. In addition to be much shorter to
type - these variables are also available regardless of the scope, and
there's no need to import them using the 'global' statement. (Andi & Zeev)

However, I can't seem to find any documentation regarding these variables on
the php.net site.  Any pointers?  Am I missing something obvious?  Thanks!

-- 
Ed Marczak
[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] Suggestion: Adding fmt like linebreak algorithm

2001-12-25 Thread Bogdan Stancescu

You may use these two and not have to bother what version of PHP your
script runs on.

Note that you may have to edit wordwrap if you need to chop exceedingly
long words (this code allows long lines in this case).

Please let me know if you use/optimize this.

HTH

Bogdan

--
  // Function to determine if the current version of PHP is
  // at least the one specified as a string in the parameter.
  // This is needed because string comparison isn't always accurate:
  // "4.0.2">"4.0.12" as strings, although that's not true when
  // speaking of comparing versions.

  // Usage example:
  // if (!isphpver("4.0.2"))
  // {
  //   [do something]
  // }

  // Bogdan Stancescu <[EMAIL PROTECTED]>, November 2001

  function isphpver($minver)
  {
$itis=2; // That is, undecided
$minimum=explode(".",$minver);
$current=explode(".",phpversion());
for ($i=0;(($i$minimum[$i])
  {
$itis=true; // In this case, we have a winner
break;
  }
  if ($current[$i]<$minimum[$i]) // >
  {
$itis=false; // In this case, we have a loser
break;
  }
}
if ($itis==2) // This would only happen if all the common version
  // components are identical. But there are may be
  // differences:
  // Example 1: comparing "4.0.1" with "4.0" would be
  //identical for now, but the condition
  //is satisfied;
  // Example 2: comparing "4.0" with "4.0.1" - identical
  //for now, but the condition is NOT
  //satisfied
{
  if (sizeof($current)>=sizeof($minimum))
  {
$itis=true;
  }
  else
  {
// Ok, only one more chance: if for example the user
// specified "4.0.0" and phpversion returned "4.0".
for ($i=sizeof($current)-1;$i
{
  if ($minimum[$i])
  {
$itis=false;
  }
}
if ($itis==2)
{
  $itis=true;
}
  }
}
return($itis);
  }

  // Bogdan Stancescu <[EMAIL PROTECTED]>, November 2001
  if (!isphpver("4.0.2"))
  {
// Word-wrap $string at $width chars
// Already available in PHP 4.0.2 and later
function wordwrap($string,$width=75)
{
  // So, this is how we're going to go about wrapping the incoming
  // text:
  // We first break the text into natural lines:
  $tm_str=explode("\n",$string);
  for ($i=0;$i$width)
  {
// If it isn't, we'll just chop a piece of the ideal width
// for starters.
$wrapped_st=substr($temp_str,0,$width);

// We'll start looking for a space in order to break the
// line there.

// (searching backwards!)
if ($wrapping_len=strrpos($wrapped_st," "))
{
  // If there is one (it usually is) then we'll retrieve its
  // position and use it
  $line_len=$wrapping_len;
}
else
{
  // Otherwise (i.e. a LOOONG word) then we'll just have to
  // look where it ends and use that.
  $line_len=strpos($temp_str," ");
}
  }
  // Now that we have the proper line ending we'll chop the
  // temporary string and add the chopped
  // part to the final (wrapped) string, along with a line
  // break.
  // Obviously, we'll do that in
  // reversed order than described here.
  $line_st.=substr($temp_str,0,$line_len)."\n";
  $temp_str=substr($temp_str,$line_len);

  // Making sure we don't leave spaces at the beginning of the
  // next line
  if (substr($temp_str,0,1)==" ")
  {
$temp_str=substr($temp_str,1);
  }
} // while
// We need this for incoming empty lines:
if (!strlen($line_st))
{
  $final_st.="\n";
}
else
{
  $final_st.=$line_st;
}
  } // for
  return($final_st);
} // function
  } // if phpver
--

Dominik Roettsches wrote:

> Hi there,
>
> I've been searching for a PHP implementation of the GNU textformatting tool
> fmt (http://www.gnu.org/software/textutils/textutils.html) which provides an
> almost optimal linebreak for your text.
>
> I'm not skilled in enough in C programming to implement such a feature for
> PHP but I'd really appreciate having this algorithm available in a simple
> PHP function.
>
> My question is, if there's anyone who is interested in implementing this for
> PHP, so that we can see it in one of the next releases?
>
> I think, the function would be very useful to do some pretty reformatting of
> text when for example sending mail or in general doing text formatted
> output.
>
> Thanks for your replies in advance,
>

Re: [PHP] Client side fatal PHP error

2001-12-25 Thread Philip Olson

> Ah yes... that would do it. How embarrassing! But another respondent brought
> up an interesting question. Why does this error not show up every time? As
> written, it is a basic syntactical error. I tested this thing up and down; I
> test it in production every day.

This error will happen every time.  Check your error_reporting setting
*shrugs* See the email I just posted.

> Ah it's always something thanks much.

Yep :)

Regards,
Philip Olson


-- 
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] Client side fatal PHP error

2001-12-25 Thread Philip Olson

> Is there a utility out there that checks for typos, like a spell check but
> for code? They are the most annoying things ever and probably the hardest of
> errors to find in scrips.
> Something simple, even command line would be handy.

It's good to program with error_reporting turned all the way up, E_ALL,
which is configured with the error_reporting directive (see php.ini) or by
the error_reporting function:

  error_reporting(E_ALL);

Undefined variables, misspelled function names, and various typos will
most likely turn up an error (unless you find a undocumented feature :).
When an error says "undefined function" then it's either:

  a) Built-in PHP functions
- A typo
- PHP was not compiled with the given extension.  For example, 
  if mysql_connect is undefined, mysql wasn't compiled into PHP.
  b) User defined
- A typo
- Undefined, as in a function library wasn't includ()ed, etc.

If a variable is undefined, it could be a typo because all good little
programs make sure their variables are defined before use :)  Anyway this
rambling rant basically says turn up error_reporting and use Common Sense.
And, to keep in mind that error reporting isn't perfect.

If an error stumps someone, searching the archives (or google) for the
error can be helpful.  For example:

  http://marc.theaimsgroup.com/?l=php-general&s=headers+already+sent
  http://www.google.com/search?q=php+%22headers+already+sent%22

Anyway, what was the question again? :)

Regards,
Philip Olson



-- 
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] Client side fatal PHP error

2001-12-25 Thread jjt

Ah yes... that would do it. How embarrassing! But another respondent brought
up an interesting question. Why does this error not show up every time? As
written, it is a basic syntactical error. I tested this thing up and down; I
test it in production every day.

Ah it's always something thanks much.


Philip Olson wrote in message ...
>> "Call to unsupported or undefined function srtoupper() in on line
82."
>
>srt != str (typo).
>
>> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
>> strtoupper(substr($xmbrcode,11,1)) != "P" &&
>> srtoupper(substr($xmbrcode,11,1)) != "H" &&
>> srtoupper(substr($xmbrcode,11,1)) != "O") {
>
>See above.  Btw, consider something like:
>
>  $str = '123456789abcdef';
>  $bad = array('B','P','H','O');
>
>  if (in_array(strtoupper($str{11}),$bad)) {
>  echo 'boo';
>  }
>
>I can't believe people code on Christmas :)
>
>Warm regards,
>Philip Olson
>



-- 
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 html-style tags to define a variable

2001-12-25 Thread Kevin Keeler

I recall seeing a thread along these lines previously, but the search
functionality at lists.php.net is currently  offline, and try as I might
to save messages that may prove useful to me in the future, I cannot get
them all.

So I apologize that this may be found elsewhere, or may be rehash for most
of you.

That given, I'm looking for the ability (using regex, i'm sure) to put
something like booger into a database (via a form), and have it
translate to $foo="booger" when php sucks it back out.

the eventual use of this will allow me to type  something like:

that's very tenacious of you ...

and have the end output be ereg_replaced (or such) to:

that's very http://www.m-w.com/cgi-bin/dictionary?va=tenacious>tenacious of
you ...

so i need to take whatever is within the  tag, define that as
$word, and then replace the whole string (tags and word) with:

http://www.m-w.com/cgi-bin/dictionary?va=$word>$word

follow me?

a simple answer will do, or a point towards an appropriate turorial may
serve me better in the long run

thanks in advance


--kevin


-- 
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] Basic PHP PROGRAMMER needed

2001-12-25 Thread Peter Reck


Dear Listmembers,

I just started to structure WEBPRESENCE SERVICES in a way of generating
income for those participating in the venture. We're still building a
portfolio and just finished this site:
http://www.150plusidea.com/

On the "registration" link you see a contact information collection form,
which is connected to a MySQL db on the server via a PHP4 script.

Our GOAL is to develop that CONTACT INFORMATION/REGISTRATION FORM and its
management into a "COOKIE CUTTER" feature for our future clients. The
person which has handled the php scripting is no longer working with us,
hence we're looking for a new programmer who would like to play with us!

Please direct your response to:

mailto:[EMAIL PROTECTED]

Mele Kalikimaka [Merry Xmas],

Peter
Aloha Web Presence


-- 
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] Client side fatal PHP error

2001-12-25 Thread James Cox

Yeah,

I know it's executed client side, but if the buffer fills up because you
have a lot to send to the client (and the network connection is saturated),
then it might fail, since it cannot do the test. it is unlikely, but
possible. Also, that code you quoted is (out of context) inefficient, so
that might prove why.

Also, it's worth noting that only 1 in 10 people complain about something.
Thus, your one client reporting this error may mean there are 10 out there
:)

Best bet is to get his headers etc (set up a seperate log site? get him to
dump the page for you as you echo variables and debug info? -- you certainly
won't know which strtoupper it fails on if they are all on the same line :))
Also, get him to give you his cookies -- chances are there could be a
datatype incompatibility.

The bottom line i am getting across here is that there are so many
possibilities here for potential errors, (like in many things) that it is
hard to pinpoint what might be wrong.

If it helps, i am more than happy to look at your code and see if i can
break it.

Regards, and now christmas day is drawing to a close, merry new year :)

James Cox
--
[EMAIL PROTECTED]
Please always Cc to me when replying to me on the lists.


-- 
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: Suggestion: Adding fmt like linebreak algorithm

2001-12-25 Thread Brian Clark

* Manuel Lemos ([EMAIL PROTECTED]) [Dec 25. 2001 17:37]:

> > I think, the function would be very useful to do some pretty reformatting of
> > text when for example sending mail or in general doing text formatted
> > output.

> I have implemented exactly what you need in this class to compose and
> send MIME messages as it is important that messages to not have more
> than 75 characters per line.

> http://phpclasses.UpperDesign.com/browse.html/package/9

For 4.0.2 or greater, there's also:



-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
It's been lovely, but I have to scream 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] Re: phpbb and ikonboard forum scripts

2001-12-25 Thread Indera

Hello,

Thank you. I think I want to stick with the php/mysql combo, so will take ikonboard 
off the list.

Indera



Laserjetter wrote:

> Ikonboard has a very nice interface and I know that its very popular but, as
> you thought, it is CGI based.
> I've never managed to get it working - maybe because I couldnt get Active
> Perl working properly (well, it was a 25MHz 486 with 8Mb RAM!!).
> If you're more into PHP I'd go with phpbb as you'd find it easier to tinker
> around with to get it looking how you wanted.
>
> "Indera" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > Hello,
> >
> > I am trying to decide between these two scripts and was wondering if
> anyone has either of them
> > installed. The one thing I need that I can't figure out if either of them
> have is whether or not, I
> > can hide categories (that contain the forums and topics) on the category
> page and based on a users
> > log-in have them enabled. If that is not possible is it possible to create
> 2 category pages and
> > store them in one database, (hosting company only allows one instance of a
> forum script to be
> > installed) one for the forums that everyone that comes to my site can see
> and another category page
> > that will actually only be available in the restricted members only page.
> >
> > If it helps, here are the links
> > http://www.phpbb.com and http://www.ikonboard.com
> >
> > I think I prefer the phpbb forum because ikonboard uses cgi scripts, or it
> least that's what it
> > looks like.
> >
> > Any help would be greatly appreciated.
> >
> > Thanks
> > Indera
> >
> >
> >


-- 
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] phpbb and ikonboard forum scripts

2001-12-25 Thread Indera

Hi Jeff,

Thank you for the link to another script. I had never heard of that one and will 
definitely check it
out.

Indera



Jeff Lewis wrote:

> Never thought I'd see this pop on here :)  As mentined before, Ikonboard is
> in fact Perl and up until recently was only flatfile.  Another you may want
> to try is http://www.yabb.info (PHP/mySQL combo)
>
> Jeff
> - Original Message -
> From: "Indera" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, December 25, 2001 4:49 PM
> Subject: [PHP] phpbb and ikonboard forum scripts
>
> > Hello,
> >
> > I am trying to decide between these two scripts and was wondering if
> anyone has either of them
> > installed. The one thing I need that I can't figure out if either of them
> have is whether or not, I
> > can hide categories (that contain the forums and topics) on the category
> page and based on a users
> > log-in have them enabled. If that is not possible is it possible to create
> 2 category pages and
> > store them in one database, (hosting company only allows one instance of a
> forum script to be
> > installed) one for the forums that everyone that comes to my site can see
> and another category page
> > that will actually only be available in the restricted members only page.
> >
> > If it helps, here are the links
> > http://www.phpbb.com and http://www.ikonboard.com
> >
> > I think I prefer the phpbb forum because ikonboard uses cgi scripts, or it
> least that's what it
> > looks like.
> >
> > Any help would be greatly appreciated.
> >
> > Thanks
> > Indera


-- 
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] File Upload Question...

2001-12-25 Thread Anthony Ritter

Merry Christmas everybody.

I am using MS Windows 98 with Apache and following an example in Julie
Meloni's "PHP - Fast and Easy" (Chapter 10) in which she describes file
uploading using PHP on page 168-174.

She has two files:
1) an html form to receive the input from the user for the file to be
uploaded
2) a .php script to accept the variable and use the copy() function.
.

The scripts are as follows:
(html form)



Upload a File



Upload a File



File to Upload:









(.php script)





Successful File Upload



Success!

You sent: , a 
byte file with a mime type of .



..

My questions:
I am able to upload a file from My Documents  to the Apache server however
in her book, she describes that the user can verify that the file was
uploaded to the server by going to:

File/ Open Page / in ones web browser to navigate through their filesystem
to
find the file that was uploaded.  There is a screenshot in the book that
shows the .jpeg file on the screen with the browser at:
file:///C/Apache/htdocs/blahblah.jpg

I can't seem to verify that the file exists using this method.

The only way I can verify that the file was indeed uploaded is to go into
the folder within Apache that was specified in the path and check there.

*How can I check by going through the browser window?*

Next question:

When I check that the file was uploaded, the file is saved in:
C:/Program Files/Apache Group/Apache/htdocs/$img1_name

as the *regular *.jpeg name I originally gave it - not the variable - $img1.

Is this correct? Or, should the file be saved as:
img1?

And the last question:
This is the line I received upon sending the file:

You sent: KewpieSmall.jpeg, a 3127 byte file with a mime type of
image/pjpeg.

In her book, it says:
image/jpeg.

What is:
image/pjpeg.?

Many thanks and best wishes to all for a happy and healthy new year.
Tony Ritter






-- 
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: Prev ... Next

2001-12-25 Thread Manuel Lemos

Hello,

Rambo Amadeus wrote:
> 
> Hi,
> I have about 100 names in mysql. How can i display them in groups of 10, and
> have next and previous links.

You may want to try this PHP Class that displays HTML tables with query
results that may be limited per page. In that case it display links to
go to the next, previous, last, first and some intermediate pages that
you may configure. See the HTML example page. This class works with
MySQL and many other databases:

http://phpclasses.UpperDesign.com/browse.html/package/130

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]




[PHP] Re: Suggestion: Adding fmt like linebreak algorithm

2001-12-25 Thread Manuel Lemos

Hello,

Dominik Roettsches wrote:
> 
> Hi there,
> 
> I've been searching for a PHP implementation of the GNU textformatting tool
> fmt (http://www.gnu.org/software/textutils/textutils.html) which provides an
> almost optimal linebreak for your text.
> 
> I'm not skilled in enough in C programming to implement such a feature for
> PHP but I'd really appreciate having this algorithm available in a simple
> PHP function.
> 
> My question is, if there's anyone who is interested in implementing this for
> PHP, so that we can see it in one of the next releases?
> 
> I think, the function would be very useful to do some pretty reformatting of
> text when for example sending mail or in general doing text formatted
> output.

I have implemented exactly what you need in this class to compose and
send MIME messages as it is important that messages to not have more
than 75 characters per line.

http://phpclasses.UpperDesign.com/browse.html/package/9

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] phpbb and ikonboard forum scripts

2001-12-25 Thread Jeff Lewis

Never thought I'd see this pop on here :)  As mentined before, Ikonboard is
in fact Perl and up until recently was only flatfile.  Another you may want
to try is http://www.yabb.info (PHP/mySQL combo)

Jeff
- Original Message -
From: "Indera" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 25, 2001 4:49 PM
Subject: [PHP] phpbb and ikonboard forum scripts


> Hello,
>
> I am trying to decide between these two scripts and was wondering if
anyone has either of them
> installed. The one thing I need that I can't figure out if either of them
have is whether or not, I
> can hide categories (that contain the forums and topics) on the category
page and based on a users
> log-in have them enabled. If that is not possible is it possible to create
2 category pages and
> store them in one database, (hosting company only allows one instance of a
forum script to be
> installed) one for the forums that everyone that comes to my site can see
and another category page
> that will actually only be available in the restricted members only page.
>
> If it helps, here are the links
> http://www.phpbb.com and http://www.ikonboard.com
>
> I think I prefer the phpbb forum because ikonboard uses cgi scripts, or it
least that's what it
> looks like.
>
> Any help would be greatly appreciated.
>
> Thanks
> Indera




-- 
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] Suggestion: Adding fmt like linebreak algorithm

2001-12-25 Thread Dominik Roettsches

Hi there,

I've been searching for a PHP implementation of the GNU textformatting tool 
fmt (http://www.gnu.org/software/textutils/textutils.html) which provides an 
almost optimal linebreak for your text.

I'm not skilled in enough in C programming to implement such a feature for 
PHP but I'd really appreciate having this algorithm available in a simple 
PHP function.

My question is, if there's anyone who is interested in implementing this for 
PHP, so that we can see it in one of the next releases?

I think, the function would be very useful to do some pretty reformatting of 
text when for example sending mail or in general doing text formatted 
output.

Thanks for your replies in advance,

Dominik

-- 
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] Client side fatal PHP error

2001-12-25 Thread LaserJetter

Is there a utility out there that checks for typos, like a spell check but
for code? They are the most annoying things ever and probably the hardest of
errors to find in scrips.
Something simple, even command line would be handy.

Also, its interesting that only one user of the script got the error. What
about all the others? Are they not as considerate as this one guy who
actually reported the problem?


"Philip Olson" <[EMAIL PROTECTED]> wrote in message
Pine.BSF.4.10.10112252053030.8996-10@localhost">news:Pine.BSF.4.10.10112252053030.8996-10@localhost...
> > "Call to unsupported or undefined function srtoupper() in on line
82."
>
> srt != str (typo).
>
> > if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
> > strtoupper(substr($xmbrcode,11,1)) != "P" &&
> > srtoupper(substr($xmbrcode,11,1)) != "H" &&
> > srtoupper(substr($xmbrcode,11,1)) != "O") {
>
> See above.  Btw, consider something like:
>
>   $str = '123456789abcdef';
>   $bad = array('B','P','H','O');
>
>   if (in_array(strtoupper($str{11}),$bad)) {
>   echo 'boo';
>   }
>
> I can't believe people code on Christmas :)
>
> Warm regards,
> Philip Olson
>





-- 
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: phpbb and ikonboard forum scripts

2001-12-25 Thread LaserJetter

Ikonboard has a very nice interface and I know that its very popular but, as
you thought, it is CGI based.
I've never managed to get it working - maybe because I couldnt get Active
Perl working properly (well, it was a 25MHz 486 with 8Mb RAM!!).
If you're more into PHP I'd go with phpbb as you'd find it easier to tinker
around with to get it looking how you wanted.



"Indera" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hello,
>
> I am trying to decide between these two scripts and was wondering if
anyone has either of them
> installed. The one thing I need that I can't figure out if either of them
have is whether or not, I
> can hide categories (that contain the forums and topics) on the category
page and based on a users
> log-in have them enabled. If that is not possible is it possible to create
2 category pages and
> store them in one database, (hosting company only allows one instance of a
forum script to be
> installed) one for the forums that everyone that comes to my site can see
and another category page
> that will actually only be available in the restricted members only page.
>
> If it helps, here are the links
> http://www.phpbb.com and http://www.ikonboard.com
>
> I think I prefer the phpbb forum because ikonboard uses cgi scripts, or it
least that's what it
> looks like.
>
> Any help would be greatly appreciated.
>
> Thanks
> Indera
>
>
>



-- 
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] Hosting advise

2001-12-25 Thread Indera

Hello,

I need to find a new host that is relatively in-expensive and found these three. I was 
wondering if
anyone here has used them or thinks that they are a good company.

http://www.aletiahosting.com/

http://www.cobaltconnection.com/

http://www.primemaster.com/index2.html

Thanks
Indera




-- 
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-WIN] Site running from MySQL

2001-12-25 Thread Svensson, B.A.T. (HKG)

From: LaserJetter

>Out of interest, would it be possible to load a webpage as a record in a
>MySQL database, having another field as say a number or a unique name so
>that a whole site could be placed in a database with a couple of php files?
>Is there a limit on the size of a field in MySQL which would stop you doing
>this though and would it be noticeably slower that html / php files?
>I was only wondering as it would make full text searches an awful lot
>simpler

Of course it is possible. (Why would it not be?)

I've don it my self (stored ptrocedures that builds HTML pages),
and especially the full text search you were talking about.

-- 
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] phpbb and ikonboard forum scripts

2001-12-25 Thread Indera

Hello,

I am trying to decide between these two scripts and was wondering if anyone has either 
of them
installed. The one thing I need that I can't figure out if either of them have is 
whether or not, I
can hide categories (that contain the forums and topics) on the category page and 
based on a users
log-in have them enabled. If that is not possible is it possible to create 2 category 
pages and
store them in one database, (hosting company only allows one instance of a forum 
script to be
installed) one for the forums that everyone that comes to my site can see and another 
category page
that will actually only be available in the restricted members only page.

If it helps, here are the links
http://www.phpbb.com and http://www.ikonboard.com

I think I prefer the phpbb forum because ikonboard uses cgi scripts, or it least 
that's what it
looks like.

Any help would be greatly appreciated.

Thanks
Indera




-- 
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 25 Dec 2001 21:02:03 -0000 Issue 1073

2001-12-25 Thread php-general-digest-help


php-general Digest 25 Dec 2001 21:02:03 - Issue 1073

Topics (messages 78711 through 78730):

Re: PHP/MYSQL ..what the hell is wrong here...
78711 by: Brian Clark

Re: gd_installation. :(
78712 by: EMIN CALIKLI
78718 by: Brian Clark

PHP and NIS+
78713 by: Irwan Hadi

PDF
78714 by: Chamarty Prasanna Kumar

call stack access
78715 by: akul.otamedia.com

Sessions php and flash5, cookies disabled
78716 by: Jan Grafström
78719 by: Brian Clark
78725 by: Jan Grafström

Re: Site running from MySQL
78717 by: David Bouw

Merry Christmas Everyone
78720 by: Dan McCullough

Generate Alphabet
78721 by: Daniel Harik
78723 by: Fred
78724 by: Daniel Harik

custmoer management
78722 by: M.E. Suliman

Fatal PHP error on client computer
78726 by: jjt

Client side fatal PHP error
78727 by: jjt
78728 by: James Cox
78729 by: jjt
78730 by: Philip Olson

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]


--

--- Begin Message ---

* Chris Cocuzzo ([EMAIL PROTECTED]) [Dec 25. 2001 03:16]:

> here's the submit.php page ..which is the one that I suspect is giving me problems:

> case 'gigs':
>  print "$date";
>  $date = strtotime($date);
>  print "$date";
>  $query = "INSERT INTO gigs VALUES('0','$date','$location','$venue','$info')";
>  break;

[...]

> +--+---+--+-+-++
> | Field| Type  | Null | Key | Default | Extra  |
> +--+---+--+-+-++
> | showid   | mediumint(5)  |  | PRI | NULL| auto_increment |
> | date | timestamp(10) | YES  | | NULL||

Realize that, according to the mysql docs, timestamp(10) expects
its input to be in the format, YYMMDDHHMM.

> | location | varchar(40)   |  | | ||
> | venue| varchar(40)   |  | | ||
> | info | mediumtext|  | | ||
> +--+---+--+-+-++

> and when i query it i get this:
> +++-+--+---+
> | showid | date   | location| venue| info  |
> +++-+--+---+
> |  1 | 00 | Framingham, Ma. | Denison Hall | -TBA- |
> +++-+--+---+

And strtotime() is creating a different format. It's the the number of
non-leap seconds since epoch. I guess MySQL doesn't understand that, in
that situation.


> the date field is empty, but it should be filled. When i enter in the value for the 
>date field in the form, I enter it as such: Jan 11, 2002  . I tested this beforehand 
>and it worked. What the hell is wrong??

$date = strftime("%y%m%d%H%M", strtotime($date));

And that should produce, using your example:



See if that works..

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
SIGFUN -- signature too funny (core dumped)


--- End Message ---
--- Begin Message ---


Hi Brian ,
Thanks for your requests . I 'm using php 4.0.6 + IIS 4.0 (Web Server) . I tried many 
verisons of GD
library and failed. Did anyone tried php-4.1.0 verison on IIS 4.0 ? By the way Brian I 
configured my
local workstation with Apache 1.3.22 + php 4.0.6 and it works fine. I can use it GD 
extension. But I
must run GD on IIS don 't ask me why ? This is companies strategy . So I think I must 
work hard to
solve it.
Thanks again.




   
 
Brian Clark
 
  
werks.com>cc:  
 
  Subject: Re: [PHP] gd_installation   
 
25.12.2001 
 
09:59  
 
   
 
   
 




* EMIN CALIKLI ([EMAIL PROTECTED]) [Dec 25. 2001 01:47]:

> ---

Re: [PHP] Client side fatal PHP error

2001-12-25 Thread Philip Olson

> "Call to unsupported or undefined function srtoupper() in on line 82."

srt != str (typo).  

> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
> strtoupper(substr($xmbrcode,11,1)) != "P" &&
> srtoupper(substr($xmbrcode,11,1)) != "H" &&
> srtoupper(substr($xmbrcode,11,1)) != "O") {

See above.  Btw, consider something like:

  $str = '123456789abcdef';
  $bad = array('B','P','H','O');

  if (in_array(strtoupper($str{11}),$bad)) {
  echo 'boo';
  }

I can't believe people code on Christmas :)

Warm regards,
Philip Olson


-- 
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] Client side fatal PHP error

2001-12-25 Thread jjt

Thanks for your help. I do not have any more info on the error; that is all
the visitor to my site provided. But I am not sure what more useful detail
there could be; it was a fatal error as I described; the script aborted on
line 82, the IF statement.

However, it might be useful to know that my host computer is running version
3.0.12 of PHP3 on a Unix server.

As for the code, I am not sure what more context would be helpful; the error
message indicated a failure on the function strtoupper() in that statement.
The statement is within a validation routine. I am running a series of tests
on $xmbrcode, a cookie variable; each test is independent.

You are correct in that creating a new variable instead of substringing it 3
times would be more efficient. However I cannot see how this would make a
significant difference.

I am baffled as to why PHP would fail on a valid statement, and fail only
for that user. Since the code is executed on the host computer, I do not see
how a slow connection would have any effect on it. I can see why extremely
heavy traffic on my host computer might cause a timeout, but not for one
user only, and not always on the same statement. By the time the HTML code
is sent to the user, I thought that the execution of PHP was done. In any
event, today, when this error was reported to me, has been one of the
slowest days of the year at my site.

Maybe I just baffle easily

Thanks for your help.

- hmc


James Cox wrote in message ...
>Well, what you have said here isn't that clear, however consider the
>following revised code:
>
>$teststr = strtoupper(substr($xmbrcode,11,1));
>if(($teststr != "B") && ($teststr != "P") && ($teststr != "H") && ($teststr
>!= "O")){
> do..
>}
>
>What you are doing is executing the substr and strtoupper many times,
which,
>on a slow connection which may have backlog (thus slower time for the html
>stream buffer to be delivered), it could timeout.
>
>More detail on a: the error, and b: the code *in context* would help.
>
>Regards,
>
>James Cox
>
>> -Original Message-
>> From: jjt [mailto:[EMAIL PROTECTED]]
>> Sent: Tuesday, December 25, 2001 6:36 PM
>> To: [EMAIL PROTECTED]
>> Subject: [PHP] Client side fatal PHP error
>>
>>
>> A visitor to my site repeatedly receives a fatal error in one of
>> my scripts.
>>
>> He is using a Compaq PC with IE 6; Windows 98. He gets this error
message:
>> "Call to unsupported or undefined function srtoupper() in on line
82."
>>
>> Line 82 is a compound IF statement which uses strtoupper(). As best I can
>> tell, the syntax of the statement is fine:
>>
>> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
>> strtoupper(substr($xmbrcode,11,1)) != "P" &&
>> srtoupper(substr($xmbrcode,11,1)) != "H" &&
>> srtoupper(substr($xmbrcode,11,1)) != "O") {
>>
>> And more significantly, no one else is reporting this error; I cannot
>> reproduce it. The script is executed thousands of times each day. By the
>> time he gets to line 82, he has successfully passed another simple
>> strtoupper() statement. Every user running this script must get past line
>> 82.
>>
>> I am very confused here.  Why does this error occur only on his computer?
>> How could it be machine or browser dependent? Isn't all PHP processing
>> done on my host (server) computer? And if so, why does the error not
>> occur every time the script is executed?
>>
>> I am totally baffled by this. Can anyone help?
>>
>> Thanks,
>>
>> Hershel M. Chicowitz
>> [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] Client side fatal PHP error

2001-12-25 Thread James Cox

Well, what you have said here isn't that clear, however consider the
following revised code:

$teststr = strtoupper(substr($xmbrcode,11,1));
if(($teststr != "B") && ($teststr != "P") && ($teststr != "H") && ($teststr
!= "O")){
do..
}

What you are doing is executing the substr and strtoupper many times, which,
on a slow connection which may have backlog (thus slower time for the html
stream buffer to be delivered), it could timeout.

More detail on a: the error, and b: the code *in context* would help.

Regards,

James Cox

> -Original Message-
> From: jjt [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 25, 2001 6:36 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Client side fatal PHP error
>
>
> A visitor to my site repeatedly receives a fatal error in one of
> my scripts.
>
> He is using a Compaq PC with IE 6; Windows 98. He gets this error message:
> "Call to unsupported or undefined function srtoupper() in on line 82."
>
> Line 82 is a compound IF statement which uses strtoupper(). As best I can
> tell, the syntax of the statement is fine:
>
> if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
> strtoupper(substr($xmbrcode,11,1)) != "P" &&
> srtoupper(substr($xmbrcode,11,1)) != "H" &&
> srtoupper(substr($xmbrcode,11,1)) != "O") {
>
> And more significantly, no one else is reporting this error; I cannot
> reproduce it. The script is executed thousands of times each day. By the
> time he gets to line 82, he has successfully passed another simple
> strtoupper() statement. Every user running this script must get past line
> 82.
>
> I am very confused here.  Why does this error occur only on his computer?
> How could it be machine or browser dependent? Isn't all PHP processing
> done on my host (server) computer? And if so, why does the error not
> occur every time the script is executed?
>
> I am totally baffled by this. Can anyone help?
>
> Thanks,
>
> Hershel M. Chicowitz
> [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] Client side fatal PHP error

2001-12-25 Thread jjt

A visitor to my site repeatedly receives a fatal error in one of my scripts.

He is using a Compaq PC with IE 6; Windows 98. He gets this error message:
"Call to unsupported or undefined function srtoupper() in on line 82."

Line 82 is a compound IF statement which uses strtoupper(). As best I can
tell, the syntax of the statement is fine:

if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
strtoupper(substr($xmbrcode,11,1)) != "P" &&
srtoupper(substr($xmbrcode,11,1)) != "H" &&
srtoupper(substr($xmbrcode,11,1)) != "O") {

And more significantly, no one else is reporting this error; I cannot
reproduce it. The script is executed thousands of times each day. By the
time he gets to line 82, he has successfully passed another simple
strtoupper() statement. Every user running this script must get past line
82.

I am very confused here.  Why does this error occur only on his computer?
How could it be machine or browser dependent? Isn't all PHP processing
done on my host (server) computer? And if so, why does the error not
occur every time the script is executed?

I am totally baffled by this. Can anyone help?

Thanks,

Hershel M. Chicowitz
[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] Fatal PHP error on client computer

2001-12-25 Thread jjt

A visitor to my site repeatedly receives a fatal error in one of my scripts.

He is using a Compaq PC with IE 6; Windows 98. He gets this error message:
"Call to unsupported or undefined function srtoupper() in on line 82."

Line 82 is a compound IF statement which uses strtoupper(). As best I can
tell, the syntax of the statement is fine:

if (strtoupper(substr($xmbrcode,11,1)) != "B" &&
strtoupper(substr($xmbrcode,11,1)) != "P" &&
srtoupper(substr($xmbrcode,11,1)) != "H" &&
srtoupper(substr($xmbrcode,11,1)) != "O") {

And more significantly, no one else is reporting this error; I cannot
reproduce it. The script is executed thousands of times each day. By the
time he gets to line 82, he has successfully passed another simple
strtoupper() statement. Every user running this script must get past line
82.

I am very confused here.  Why does this error occur only on his computer?
How could it be machine or browser dependent? Isn't all PHP processing done
on my host (client) computer? And if so, why does the error not occur every
time the script is executed?

I am totally baffled by this. Can anyone help?

Thanks,

Hershel M. Chicowitz
[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] Sessions php and flash5, cookies disabled

2001-12-25 Thread Jan Grafström

Thanks Brian!
There is no differens using only ".SID." or ".$SID."
and this line :
automatically givs this responsestring in the urlfield of your browser
(IE6):
second.php3?SID=PHPSESSID%3D193a33f9b7421c17302d1bd58478b20b&var3=1

I will try to manipulate the string

Regards,
Jan

"Brian Clark" <[EMAIL PROTECTED]> skrev i meddelandet
20011225165631.GF8638@ganymede">news:20011225165631.GF8638@ganymede...
* Jan Grafström ([EMAIL PROTECTED]) [Dec 25. 2001 10:41]:

> The url string looks like this on php-page (sent from flash5):
> mypage.php3?SID=PHPSESSID=193a33f9b7421c17302d1bd58478b20b?.
> >From mypage.php3 I pass sid using ".SID." than on second page the string
is
> changed to:
> second.php3?SID=PHPSESSID%3D193a33f9b7421c17302d1bd58478b20b&var3=1.

> "=" has changed to "%3D". and php does not recognice the session.

> part of code on mypage.php3:
> http://myserver.com/second.php3?\"; method=\"get\">
> 

I'm sure you meant for that line to be:



Right? (note the $) Eventhough I don't think that has anything to do
with your problem.

> Thanks for any help.

Why are you using SID=PHPSESSID= instead of just SID=? If you
absolutely have to leave it the way you have it, you could always
explode('%3D',$SID); to get the correct session ID.

--
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
If your life is a hard drive, Christ can be your backup.



-- 
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: Generate Alphabet

2001-12-25 Thread Daniel Harik

Hello Fred,

Tuesday, December 25, 2001, 7:55:16 PM, you wrote:

F> for ($Character = 65; $Character < 91; $Character++)
F> {
F> echo chr($Character);
F> }

F> Fred

F> Daniel Harik <[EMAIL PROTECTED]> wrote in message
F> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>> Hello Guys,
>>
>> Just a stupid question how can i make php show from a-z with a for
>> loop, don't want to make 26 hard coded links
>>
>> Thank You very much
>>
>> --
>> Best regards,
>>  Daniel  mailto:[EMAIL PROTECTED]
>>




Thank you

-- 
Best regards,
 Danielmailto:[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: Generate Alphabet

2001-12-25 Thread Fred

for ($Character = 65; $Character < 91; $Character++)
{
echo chr($Character);
}

Fred

Daniel Harik <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hello Guys,
>
> Just a stupid question how can i make php show from a-z with a for
> loop, don't want to make 26 hard coded links
>
> Thank You very much
>
> --
> Best regards,
>  Daniel  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] custmoer management

2001-12-25 Thread M.E. Suliman

Hi

Is there a script or current projects that involve the following.  What we
require is the management of client base (contact details etc.) account
blancing with suppliers and monthly billing and invoicing.

If there aren't any scripts in php already, to perfrom this is there
anywhere I could look at for ideas and begin one from the start.

Thanks

Mohamed



-- 
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] Generate Alphabet

2001-12-25 Thread Daniel Harik

Hello Guys,

Just a stupid question how can i make php show from a-z with a for
loop, don't want to make 26 hard coded links

Thank You very much

-- 
Best regards,
 Daniel  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] Merry Christmas Everyone

2001-12-25 Thread Dan McCullough

Merry Christmas Everyone ...


__
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.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]




Re: [PHP] Sessions php and flash5, cookies disabled

2001-12-25 Thread Brian Clark

* Jan Grafström ([EMAIL PROTECTED]) [Dec 25. 2001 10:41]:

> The url string looks like this on php-page (sent from flash5):
> mypage.php3?SID=PHPSESSID=193a33f9b7421c17302d1bd58478b20b?.
> >From mypage.php3 I pass sid using ".SID." than on second page the string is
> changed to:
> second.php3?SID=PHPSESSID%3D193a33f9b7421c17302d1bd58478b20b&var3=1.

> "=" has changed to "%3D". and php does not recognice the session.

> part of code on mypage.php3:
> http://myserver.com/second.php3?\"; method=\"get\">
> 

I'm sure you meant for that line to be:



Right? (note the $) Eventhough I don't think that has anything to do
with your problem.

> Thanks for any help.

Why are you using SID=PHPSESSID= instead of just SID=? If you
absolutely have to leave it the way you have it, you could always
explode('%3D',$SID); to get the correct session ID.

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
If your life is a hard drive, Christ can be your backup.


--
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] gd_installation......................... :(

2001-12-25 Thread Brian Clark

* EMIN CALIKLI ([EMAIL PROTECTED]) [Dec 25. 2001 05:20]:

> Hi Brian ,

Hiya.

> Thanks for your requests . I 'm using php 4.0.6 + IIS 4.0 (Web Server) . I tried 
>many verisons of GD
> library and failed. Did anyone tried php-4.1.0 verison on IIS 4.0 ? By the way Brian 
>I configured my
> local workstation with Apache 1.3.22 + php 4.0.6 and it works fine. I can use it GD 
>extension. But I
> must run GD on IIS don 't ask me why ? This is companies strategy . So I think I 
>must work hard to
> solve it.
> Thanks again.

What happened when you renamed the ph_gd.dll file to php_gd.dll? Did you
try that?

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
The beatings will continue until morale improves.


-- 
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] Site running from MySQL

2001-12-25 Thread David Bouw

Maybe this will be a surprise, but I think that more than 90% of the webpages that use
MySQL, use it do exactly what you are wondering about..

Not only are the searches a lot easier, but if you do it right you can make a website
which won't contain any dead links...  (By generating links to other pages from the
database.)

The basic idea is though to make some kind of template in PHP which contains all the 
HTML
code
and that you store all text data in the database.. This text-data is then fitted 
between
te HTML tags
when you call the page..  (If you do it right (in my opinion) you will have a database
which only
consists of data, and PHP pages which only contains PHP code echoing HTML code with 
record
information from the database..

When using BLOBs etc I can't see that you will ever run into limitations unless you
are doing something silly..

Try it...!

> Out of interest, would it be possible to load a webpage as a record in a
> MySQL database, having another field as say a number or a unique name so
> that a whole site could be placed in a database with a couple of php files?
> Is there a limit on the size of a field in MySQL which would stop you doing
> this though and would it be noticeably slower that html / php files?
> I was only wondering as it would make full text searches an awful lot
> simpler
>
>
>
> --
> 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] Sessions php and flash5, cookies disabled

2001-12-25 Thread Jan Grafström

Hi!

I am trying to get my php-scripts to work using flash 5 and with cookies
disabled in the users browser.

At first I pass SID to flash and than I can call my php-scripts by passing
the SID back to PHP using loadvariables and get method, this works fine.

The problem is when I pass it to a php-page and than pass it to a second
php-script.

The url string looks like this on php-page (sent from flash5):
mypage.php3?SID=PHPSESSID=193a33f9b7421c17302d1bd58478b20b?.
>From mypage.php3 I pass sid using ".SID." than on second page the string is
changed to:
second.php3?SID=PHPSESSID%3D193a33f9b7421c17302d1bd58478b20b&var3=1.

"=" has changed to "%3D". and php does not recognice the session.

part of code on mypage.php3:
http://myserver.com/second.php3?\"; method=\"get\">


Thanks for any help.


--
Jan Grafström
Lillemans Hus AB
Sweden
46 (0)611-60920
46 (0)70-6409073


-- 
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] call stack access

2001-12-25 Thread akul

Hello php-general,

  I want to make good error messages for my libraries, but can't
  because there is no way to get __FILE__ and __LINE__ for calling
  point. I can print only unusable point inside my library where
  trigger_error() is called. Is here any way to do this? May be I miss
  something? Or may be such function (like a get_call_stack()) planned
  for future? 

-- 
Best regards,
 akul  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] PDF

2001-12-25 Thread Chamarty Prasanna Kumar



Hi All,

   Want to create PDF files using PHP 

from file formats,

.eps

.ps

.doc

.ppt

.xls

.html


  Can you please suggest a way to do it.

Thanks in Advance.

Regards,

Kumar.


 


--
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] PHP and NIS+

2001-12-25 Thread Irwan Hadi

Dear All,

I just curious does PHP has the capability to access the NIS+ table in
Solaris based environment such as Perl ?
I'm asking this because the only NIS+ support in perl seems already
outdated (it works with perl 5.003 but not perl 5.6.1), so if PHP does
support accessing the Solaris NIS+ table, I'm planning to change the
script from perl to PHP (this is must be accessed from the web for users
account creation webpage).

If PHP doesn't support NIS+ does anyone has any idea how to implement
this with PHP then ?
I'm thinking to use MySQL and some shell scripts to interact between PHP
and NIS+ table (using nistbladm, nisaddent, etc.)

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] gd_installation......................... :(

2001-12-25 Thread EMIN CALIKLI


Hi Brian ,
Thanks for your requests . I 'm using php 4.0.6 + IIS 4.0 (Web Server) . I tried many 
verisons of GD
library and failed. Did anyone tried php-4.1.0 verison on IIS 4.0 ? By the way Brian I 
configured my
local workstation with Apache 1.3.22 + php 4.0.6 and it works fine. I can use it GD 
extension. But I
must run GD on IIS don 't ask me why ? This is companies strategy . So I think I must 
work hard to
solve it.
Thanks again.




   
 
Brian Clark
 
  
werks.com>cc:  
 
  Subject: Re: [PHP] gd_installation   
 
25.12.2001 
 
09:59  
 
   
 
   
 




* EMIN CALIKLI ([EMAIL PROTECTED]) [Dec 25. 2001 01:47]:

> ---
> A system error has occurred.

> System error 1067 has occurred.

> The process terminated unexpectedly.
> 

Oh my goodness, you gotta love Microsoft. You crash your car and the
policeman asks, "How did this happen?" You then tell the policeman,
"I drove the car. I hit mailbox 1067." Full of detail, right?

Unless someone else in this forum is using ISS and knows where to look
for a more detailed error (like an error.log?), my guess is that the gd
library needs something else and can't find it.

gd requires libpng, zlib and jpeg-6b. Now whether or not that DLL
already has that information built-in, I don't know.

Is there a tool for Windows that will let you see a specific DLL's
dependencies?

How did you install all of this? Did you use this package?



Or are you using an older build?

Another thing I just noticed is the name of the file. Are you positive
the file isn't supposed to be named php_gd.dll instead of ph_gd.dll? Try
making a copy of it and renaming it php_gd.dll and try to load that
version.

If that doesn't work, try this DLL instead:



--
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
How much deeper would the ocean be without sponges?


--
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] PHP/MYSQL ..what the hell is wrong here...

2001-12-25 Thread Brian Clark

* Chris Cocuzzo ([EMAIL PROTECTED]) [Dec 25. 2001 03:16]:

> here's the submit.php page ..which is the one that I suspect is giving me problems:

> case 'gigs':
>  print "$date";
>  $date = strtotime($date);
>  print "$date";
>  $query = "INSERT INTO gigs VALUES('0','$date','$location','$venue','$info')";
>  break;

[...]

> +--+---+--+-+-++
> | Field| Type  | Null | Key | Default | Extra  |
> +--+---+--+-+-++
> | showid   | mediumint(5)  |  | PRI | NULL| auto_increment |
> | date | timestamp(10) | YES  | | NULL||

Realize that, according to the mysql docs, timestamp(10) expects
its input to be in the format, YYMMDDHHMM.

> | location | varchar(40)   |  | | ||
> | venue| varchar(40)   |  | | ||
> | info | mediumtext|  | | ||
> +--+---+--+-+-++

> and when i query it i get this:
> +++-+--+---+
> | showid | date   | location| venue| info  |
> +++-+--+---+
> |  1 | 00 | Framingham, Ma. | Denison Hall | -TBA- |
> +++-+--+---+

And strtotime() is creating a different format. It's the the number of
non-leap seconds since epoch. I guess MySQL doesn't understand that, in
that situation.


> the date field is empty, but it should be filled. When i enter in the value for the 
>date field in the form, I enter it as such: Jan 11, 2002  . I tested this beforehand 
>and it worked. What the hell is wrong??

$date = strftime("%y%m%d%H%M", strtotime($date));

And that should produce, using your example:



See if that works..

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
SIGFUN -- signature too funny (core dumped)


-- 
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 25 Dec 2001 08:47:14 -0000 Issue 1072

2001-12-25 Thread php-general-digest-help


php-general Digest 25 Dec 2001 08:47:14 - Issue 1072

Topics (messages 78683 through 78710):

SNMP with 4.1.0
78683 by: Peter Hicks
78692 by: Brian Clark
78694 by: Peter Hicks
78700 by: Brian Clark
78701 by: Brian Clark
78706 by: Brian Clark

Re: faxing in PHP
78684 by: Jim Lucas [php]
78685 by: Bas van Rooijen
78702 by: Steve Maroney

Re: Prev ... Next
78686 by: Arcadius A.

Re: Fulltext-Search
78687 by: Miles Thompson
78697 by: Lauri Vain
78698 by: Miles Thompson

Strings Question
78688 by: Phillip B. Bruce
78689 by: Matt McClanahan

Re: How to compile Apache/PHP
78690 by: Brian Clark

Re: gd_installation
78691 by: Brian Clark
78704 by: EMIN CALIKLI
78705 by: Brian Clark

Site running from MySQL
78693 by: LaserJetter

relative path vs. INCLUDE()  !
78695 by: Arcadius A.
78699 by: Bogdan Stancescu
78703 by: Justin Garrett

Supplied argument is not a valid PostgreSQL result resource
78696 by: James Arthur

Re: PHP4 and IB SS 6.01
78707 by: Brian Clark

PHP/MYSQL ..what the hell is wrong here...
78708 by: Chris Cocuzzo

Warning: mysql_db_query is deprecated; use mysql_select_db() and mysql_query() instead 
in 
78709 by: Boaz Yahav

Re: PHP & ssi
78710 by: Joel Boonstra

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]


--

--- Begin Message ---

All,

I am having terrible difficulty trying to build 4.1.0 as an Apache shared
module. Without SNMP support, all is well. However, as soon as I add
--with-snmp=..., I get the following at compile time:

gcc: /usr/local/snmp/lib/.libs/libsnmp.so: No such file or directory
make[3]: *** [snmp.la] Error 1
make[3]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext/snmp'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext/snmp'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext'
make: *** [all-recursive] Error 1


This only happens when PHP is being compiled as a shared module, and only
happens when SNMP support is compiled in.

Anyone got any ideas?

Festive wishes,


Peter.


--- End Message ---
--- Begin Message ---

* Peter Hicks ([EMAIL PROTECTED]) [Dec 24. 2001 15:26]:

> I am having terrible difficulty trying to build 4.1.0 as an Apache shared
> module. Without SNMP support, all is well. However, as soon as I add
> --with-snmp=..., I get the following at compile time:

> gcc: /usr/local/snmp/lib/.libs/libsnmp.so: No such file or directory

Does libsnmp.so actually exist in /usr/local/snmp/lib?

> make[3]: *** [snmp.la] Error 1
> make[3]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext/snmp'
> make[2]: *** [all-recursive] Error 1
> make[2]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext/snmp'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/usr/local/src/web/ssl2/php-4.1.0/ext'

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
Enter any 11 digit prime number to continue.


--- End Message ---
--- Begin Message ---

Hi Brian

On Mon, 24 Dec 2001, Brian Clark wrote:

> > gcc: /usr/local/snmp/lib/.libs/libsnmp.so: No such file or directory
>
> Does libsnmp.so actually exist in /usr/local/snmp/lib?

Yes (a symlink to another file, which exists), and SNMP is detected fine
through 'configure'.

I have two theories. The first is that libsnmp.so is the name of the Apache
module that is being compiled and it is being referenced incorrectly; the
second is that a spurious .libs/ has appeared from somewhere.

As I said in the first e-mail, it works fine when PHP is to be statically
compiled in to Apache, which leads me to believe my first theory more than the
second



Peter.


--- End Message ---
--- Begin Message ---

* Peter Hicks ([EMAIL PROTECTED]) [Dec 24. 2001 17:39]:

> > Does libsnmp.so actually exist in /usr/local/snmp/lib?

> Yes (a symlink to another file, which exists), and SNMP is detected fine
> through 'configure'.

> I have two theories. The first is that libsnmp.so is the name of the Apache
> module that is being compiled and it is being referenced incorrectly; the
> second is that a spurious .libs/ has appeared from somewhere.

OK, how about building the DSO via apxs manually and see if you get any
errors? IIRC, you can then place it in the correct directory in the
apache source and use --enable-shared=snmp in apache's configure 
*I think*. Why, let me ask Santa.. 

Yes, Santa says he believes that should work.

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE

Re: [PHP] PHP & ssi

2001-12-25 Thread Joel Boonstra

> No, this isnt possible - but the constructs in PHP should allow you to
> do anything you can do with SSI just as easily.

This may be possible with Apache 2.0 and greater, once it's in stable
release (perhaps it is already).  It would allow the server to perform
multiple passes on documents, thus allowing your PHP script to execute and
output SSI, which would then get parsed by the server and be executed,
again.

Why you would need this, I don't know.  As people already mentioned, SSI's
very limited capabilities should all be available in PHP.

Joel

-- 
[ joel boonstra | [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] Warning: mysql_db_query is deprecated; use mysql_select_db() and mysql_query() instead in ....

2001-12-25 Thread Boaz Yahav

Any easy way around this?
 
Warning: mysql_db_query is deprecated; use mysql_select_db() and
mysql_query() instead in /home/WWW/weberdev/phpAds/acl.inc.php3 on line
7
 
 
thanks berber



[PHP] PHP/MYSQL ..what the hell is wrong here...

2001-12-25 Thread Chris Cocuzzo

hey-

Ok so my plan with this stuff is to enter in a few fields for a gig into the database.

Here's the code for the page where i enter the info in:


  Date: 
  Location: 
  Venue: 
  Info:
  
  
  
 

here's the submit.php page ..which is the one that I suspect is giving me problems:

case 'gigs':
 print "$date";
 $date = strtotime($date);
 print "$date";
 $query = "INSERT INTO gigs VALUES('0','$date','$location','$venue','$info')";
 break;

I'm almost positive it has nothing to do with the quotes, because it never ran into a 
problem before with the quotes in the SQL statement. is there something wrong with 
that line that has the strtotime() function in it? ...Both of the print statements 
there are printing the correct values. 

here's the database description of that table:
+--+---+--+-+-++
| Field| Type  | Null | Key | Default | Extra  |
+--+---+--+-+-++
| showid   | mediumint(5)  |  | PRI | NULL| auto_increment |
| date | timestamp(10) | YES  | | NULL||
| location | varchar(40)   |  | | ||
| venue| varchar(40)   |  | | ||
| info | mediumtext|  | | ||
+--+---+--+-+-++

and when i query it i get this:
+++-+--+---+
| showid | date   | location| venue| info  |
+++-+--+---+
|  1 | 00 | Framingham, Ma. | Denison Hall | -TBA- |
+++-+--+---+

the date field is empty, but it should be filled. When i enter in the value for the 
date field in the form, I enter it as such: Jan 11, 2002  . I tested this beforehand 
and it worked. What the hell is wrong??

-chris





Re: [PHP] PHP4 and IB SS 6.01

2001-12-25 Thread Brian Clark

* Todd Cary ([EMAIL PROTECTED]) [Dec 24. 2001 13:46]:

> Currently, the IB SS rpm puts Interbase into /opt/interbase.  Here are
> the instructions in the HowTo

OK, what you need to find are the includes for interbase. If you
installed from RPMs, you need to get the interbase "-dev" or "-devel"
equivalent also and isntall it.

> +++
> 4.Change to the PHP directory, configure PHP with PostgreSQL support
> where the PostgreSQL
> header files directory is /usr/include/pgsql, install directory
> is /usr/local/php4, build and install
> PHP:

> $ cd php-4.0.4pl1
> $ ./configure --with-pgsql=/usr/include/pgsql
> --prefix=/usr/local/php4

Just so you know, this will build PHP as a CGI, but you didn't say
whether or not you wanted this as an apache module instead. If you're
doing web-work with this, which I'd think you are, then you'll need
either --with-apxs or --with-apache=[apache's-source-dir] to build PHP
as an Apache module. 


> $ make
> $ make install
> +++

> Using

> $./configure --with-interbase=/opt/interbase
> --prefix=/usr/local/php4

> produces an error: "Cannot find httpd.h" or something close to that.

Install the interbase "-devel" package, then try one of these:

$./configure \
--with-interbase=/opt \
--with-apxs 

or..

$./configure \
--with-interbase=/usr \
--with-apxs

or..

$./configure \
--with-interbase=/usr/local \
--with-apxs

or..

If you don't want an apache module built, leave off --with-apxs and
it'll create a standalone PHP executable (probably in 
/usr/local/bin/php unless you use --prefix=/usr in your configure line)

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
5 out of 4 people have trouble with fractions.


-- 
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] SNMP with 4.1.0

2001-12-25 Thread Brian Clark

* Peter Hicks ([EMAIL PROTECTED]) [Dec 24. 2001 17:39]:

> > > gcc: /usr/local/snmp/lib/.libs/libsnmp.so: No such file or directory

> > Does libsnmp.so actually exist in /usr/local/snmp/lib?

> Yes (a symlink to another file, which exists), and SNMP is detected fine
> through 'configure'.

OK, another try. You say the file exists, but does it exist in
/usr/local/snmp/lib/.libs? If not, you could always try a symlink to get
them acquainted. Chances are, you've already tried that, correct?

-- 
Brian Clark | Avoiding the general public since 1805!
Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8
UNIX: measuring in inconvenient units since 57,974,400!


-- 
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]