Re: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread kranthi
> @Andera May be you should consider using application/json as the
> content type instead of text/plain.
> The Response text given by  Formaldehyde cannot be understood manually
> (for example if I use jQuery.load()).
> Had the content type been application/json firebug parses it by default

my mistake.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread Andrea Giammarchi

my english is not perfect, right ... but let me unsderline something.

The subject:

 [Formaldehyde] The Most Basic Ajax --> - <  *PHP* *Error* 
*Debugger*

It's a PHP Error Debugger specially suited for Ajax interactions.

Secondly,
The set_error_handler is not enough, write it even upside down and most crucial 
error like these will not be managed:

E_ERROR, E_PARSE, E_CORE_ERROR, E_CORE_WARNING, E_COMPILE_ERROR, 
E_COMPILE_WARNING, E_STRICT
Finally, this is the first code example in Formaldehyde page:


And the first result image:

http://www.3site.eu/formaldehyde/no-formaldehyde.gif

Which clearly *is* about an unmanaged Fatal Error

Ajax responses are usually different, even if the called page is the same, and 
the reason could be an X-Request-With: XMLHttpHeader header, usually set by 
default with every library and for each Ajax interation.

I like to reply about a subject, after I understand what is the subject is 
about ... but you are right, my English is not perfect, but PHP developers 
should be more careful about what PHP debug is, what is possible to do with 
set_error_handler, and how Formaldehyde manage *any* *kind* of *php* *error*, 
something I cannot find in any other library or framework.

Regards


> Date: Sat, 12 Sep 2009 00:20:58 -0400
> From: pa...@quillandmouse.com
> To: php-general@lists.php.net
> Subject: Re: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger
> 
> On Sat, Sep 12, 2009 at 12:23:44AM +0200, Andrea Giammarchi wrote:
> 
> > 
> > Exactly Ben, except when PHP fails, even with a Fatal Error, the page has 
> > status 200, we need to understand which call failed between hundreds of 
> > potential calls in the debugger, and errors could pass silently.
> > 
> > With Formaldehyde, accordingly with your predefined error_reporting level, 
> > above situation will never happen, and the entire process, without changing 
> > anything, will be much simpler, as Ben already described.
> > 
> > So yes Tedd, you did not even read what is Formaldehyde about ... please 
> > try to understand it before other comments, maybe you'll discover it's 
> > extremely simple, and hopefully useful.
> > 
> 
> I suspect your English is getting in the way. You're calling this an
> AJAX debugger. Debugging in PHP is relatively straightforward, if you
> set the error level properly and build your own error handler, etc. So
> people on this list would probably think of a PHP debugger as an
> unimportant piece of software. Debugging in Javascript is more complex
> and difficult, and the responses you're getting on the list sound like
> people think Formaldehyde is for debugging Javascript (which PHP
> programmers often aren't very interested in). On the Google code page
> for Formaldehyde, you only emphasize PHP debugging, as that's the only
> type of error example you give.
> 
> If the point of Formaldehyde is to debug PHP code, then you should call
> it a "PHP code debugger", not an "AJAX code debugger". Tedd's right--
> basic AJAX transactions are incredibly simple, and once the code is
> written (it can be copied from any number of books), it needs no further
> work. General Javascript is a different matter-- it can be quite complex
> and quite hard to debug. But AJAX is a very narrow application of
> Javascript.
> 
> If Formaldehyde is really a debugger for AJAX code, then you should
> change the examples and text of your Google code page.
> 
> If Formaldehyde is really a debugger for Javascript code, then you
> should change the examples on your Google code page to show Javascript
> errors, and call it a "Javascript debugger".
> 
> If Formaldehyde is really a debugger for PHP code, then call it a "PHP
> code debugger". The examples on your Google code page fit this.
> 
> Paul
> 
> -- 
> Paul M. Foster
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 

_
Drag n’ drop—Get easy photo sharing with Windows Live™ Photos.

http://www.microsoft.com/windows/windowslive/products/photos.aspx

RE: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread Andrea Giammarchi

Ajax interactions usually produces different results, 'cause an Ajax 
interaction that returns an entire document does not make much sense.
Formaldehyde is for Ajax interaction, which "in my case" I always catch via 
headers checks or special parameters.

Formaldehyde is client agnostic, FireBUG or FirePHP could or could not be 
there, but providing both server and client code, we do not have to worry about 
anything.

Finally, even if called manually, the page will have a status 500 and the error 
will be still readable, being it the first JSON encoded key but obviously, for 
manual interactions it is extremely simple to spot the error, if any, since PHP 
clearly shows it in the page, if there are no other debuggers.

The stuff about application/json does not make much sense to me, and FireBUG 
shows automatically things passed via eval, it is not about the response type 
(also because it could simply be a security problem)

Again, Formaldehyde, is client side agnostic, so if we have IE, rather than 
Firefox, or Safari, Chrome, Opera, Formaldehyde will work, helping with 
unmanaged PHP errors (or managed one, if we manually throw an exception or 
trigger an error)

Regards

> From: kranthi...@gmail.com
> Date: Sat, 12 Sep 2009 11:39:43 +0530
> To: pa...@quillandmouse.com
> CC: php-general@lists.php.net
> Subject: Re: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger
> 
> I dont think I understood you completely..
> 
> Javascript debugger: Something you use to debug javascript. but
> Formaldehyde dosent make any seance if xhr object is not used.
> PHP Debugger: We cant use Formaldehyde to debug errors in every single
> PHP script. I am talking about pages called directly via the browsers
> URL bar. FirePHP on the other hand can be used with all PHP scripts.
> AJAX Debugger: I think the example given in Formaldehyde Google code
> page fits this category. If not may be you can give an example ?
> 
> @Andera May be you should consider using application/json as the
> content type instead of text/plain.
> The Response text given by  Formaldehyde cannot be understood manually
> (for example if I use jQuery.load()).
> Had the content type been application/json firebug parses it by default
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 

_
More than messages–check out the rest of the Windows Live™.
http://www.microsoft.com/windows/windowslive/

RE: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread Andrea Giammarchi

as margin note, the project page changed name, hopefully less ambiguous:

Formandehyde - Zero Config Ajax Based PHP Error Debugger

Regards

_
Drag n’ drop—Get easy photo sharing with Windows Live™ Photos.

http://www.microsoft.com/windows/windowslive/products/photos.aspx

Re: [PHP] get an object property

2009-09-12 Thread Tom Worster
On 9/12/09 12:31 AM, "Paul M Foster"  wrote:

> On Fri, Sep 11, 2009 at 07:31:01PM -0400, Tom Worster wrote:
> 
>> if i have an expression that evaluates to an object, the return value from a
>> function, say, and i only want the value of one of the objects properties,
>> is there a tidy way to get it without setting another variable?
>> 
>> to illustrate, here's something that doesn't work, but it would be
>> convenient if it did:
>> 
>> $o = array( (object) array('a'=>1), (object) array('a'=>2) );
>> 
>> if ( end($o)->a > 1 ) {  // can't use -> like this!
>> ...
>> }
>> 
> 
> You should use print_r() or var_dump() to investigate what happens when
> you try to cast an array into an object. I myself don't know what would
> happen. Also, what's allowed and what effects are produced could depend
> heavily on the version of PHP you're running. Version 4 != 5 != 5.3 in
> this respect.

i did that long ago when i was looking for php's object literal syntax. i
didn't find one. we discussed it here more recently and consensus appeared
to be that casting an array was the most convenient workaround.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread tedd

At 12:20 AM +0200 9/12/09, Andrea Giammarchi wrote:

 > Date: Fri, 11 Sep 2009 12:37:30 -0400

 To: an_...@hotmail.com; php-general@lists.php.net
 From: tedd.sperl...@gmail.com
 Subject: RE: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP 
Error Debugger

 The only
 things that may go wrong are in the data I am sending to the ajax
 routine AND/OR the way my php scripts deal with the data when they
 receive it.


Formaldehyde tells you in the client debugger what was wrong in the 
php code indeed.

Did you actually read the page before you replied?


No, I didn't read the page before I replied. YOU asked a question and 
I replied (read the thread) -- I'm sorry that I did. I'll refrain 
from doing it again.


tedd

--
---
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Creating alphanumeric id for a table

2009-09-12 Thread tedd

At 9:19 PM -0700 9/11/09, aveev wrote:

The reason why I used incremental value from the db is that I need a sequence
number generator that can be used as an argument to my function. If I can
generate sequence number myself, I don't need this incremental value from
db.
What I want is that the sequential alphanumeric id that increments it's
numeric value by one everytime a new record is inserted while the alphabet
part remains the same..(like I've shown before):
AAA0001
AAA0002
...
AAA0009
AAA0010
This id will be used as the application number that will be printed as a
barcode on the user's application form. The requirement says that the app
number is prefixed with the letters (actually it's not 'AAA' but 'FIN' which
stands for File Identification Number)



Things to consider.

First, if all your application-numbers start with FIN, then my advice 
would be to do this after you pull the ID from the database. Why 
store an additional three characters for each ID? And why make your 
code more complicated than it should be?


Second, considering that you want sequential numbering, are you 
prepared for what what happens when you delete an item?  You either 
live with gaps in your sequence (recommended) or you renumber.


Third, your example limits the number of applications to  (i.e., 
AAA (seven characters)), is that correct OR is the next number 
AAA1000 (eight characters)? If the next number is eight characters, 
then why not use "AAA1" as the start of the sequence? Why the extra 
zeros?


Fourth, if you are going to use the index of the table for creating 
the application-number and require the addition of the alpha prefix, 
then I would create another field in the table and store the 
application-numbers there.


For example, I would use (not tested):

// code to create a record (i.e., INSERT INTO your_table (whatever) 
VALUES ('$whatever') )


$id = LAST_INSERT_ID();

The above statement finds the last record added to the database (the 
index of the record) and then I would create my application-number 
and store it in that record -- like so:


// code to create the application-number (i.e., $application-number = 
'AAA' . $id; )


$query = "UPDATE your_table SET application_number = 
'$application_number' WHERE id = '$id' ";

$result  = mysql_query($query) or die('Error, query failed');

That way you should not have any duplications and you have 
application-numbers (as you want )that are tied to the auto-numbering 
of the table's index.


HTH's

tedd
--
---
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] get an object property

2009-09-12 Thread Tom Worster
On 9/12/09 1:32 AM, "Lars Torben Wilson"  wrote:

> Tom Worster wrote:
>> if i have an expression that evaluates to an object, the return value from a
>> function, say, and i only want the value of one of the objects properties,
>> is there a tidy way to get it without setting another variable?
>> 
>> to illustrate, here's something that doesn't work, but it would be
>> convenient if it did:
>> 
>> $o = array( (object) array('a'=>1), (object) array('a'=>2) );
>> 
>> if ( end($o)->a > 1 ) {  // can't use -> like this!
>> ...
>> }
> 
> What version of PHP are you using? Your example should work.
> 
> Torben

5.2.9.

what version does it work in?



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Reading files in PHP 5.3.0

2009-09-12 Thread tedd

At 6:02 PM -0400 9/11/09, Paul M Foster wrote:


I typically use us2.php.net, which is hosted by Hurricane Electric.

Paul


Paul:

I wouldn't use Hurricane Electric if their accounts were provided for free!

The following is an experience I had with Hurricane Electric and 
support for my opinion as to their "service".


You see, many years ago Hurricane Electric hosted (IMO with 
complicity) a porn site that sent out over 2000 porn spams to AOL 
using MY email address as the person to contact. That incident caused 
me a great deal of trouble.


In an attempt to understand and resolve the problem, I sent several 
emails to Hurricane Electric; I called them numerous times via 
telephone; and I even sent them letters via the US mail. But 
unfortunately they refused to answer ANY of my correspondence. Their 
lack of communication provided support for my opinion of their 
complicity with what had happened.


A few years back they contacted me (again more spam) soliciting my 
interest in hosting with them. Normally, I would have just reported 
such spam to spamcop, but because of the incident I replied and told 
them what had happened.


Later I was contacted by one of their technicians who looked thorough 
their records and confirmed/admitted the incident. However, he told 
me that they could not be held responsible for they clients they 
host. Furthermore, they have no intention of screening their clients. 
He said that they will provide hosting to whomever they want, 
including porn and spam sites. If their clients do anything wrong per 
"their standards", then they will deal with it internally. Otherwise 
they don't care about any harm done to anyone by them hosting such 
sites. In short, they want the money but not the responsibility.


Now, maybe Hurricane Electric has changed its ways, but they can't 
change their past.


In my opinion, there are more than enough hosting companies who care 
about the damage they might cause and take steps to reduce the about 
spam and porn on the net. My advice, seek hosts other than Hurricane 
Electric.


Cheers,

tedd

--
---
http://sperling.com  http://ancientstones.com  http://earthstones.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] get an object property

2009-09-12 Thread Tom Worster
On 9/12/09 9:50 AM, "Tom Worster"  wrote:

> On 9/12/09 1:32 AM, "Lars Torben Wilson"  wrote:
> 
>> Tom Worster wrote:
>>> if i have an expression that evaluates to an object, the return value from a
>>> function, say, and i only want the value of one of the objects properties,
>>> is there a tidy way to get it without setting another variable?
>>> 
>>> to illustrate, here's something that doesn't work, but it would be
>>> convenient if it did:
>>> 
>>> $o = array( (object) array('a'=>1), (object) array('a'=>2) );
>>> 
>>> if ( end($o)->a > 1 ) {  // can't use -> like this!
>>> ...
>>> }
>> 
>> What version of PHP are you using? Your example should work.
>> 
>> Torben
> 
> 5.2.9.
> 
> what version does it work in?

i shamefully beg your pardon, lars. i was sure i tested the example but it's
clear to me now i either didn't or i made a mistake. end($o)->a IS php
syntax! so -> may follow a function (or method, i guess) call.

but let me give you a more different example:

$a and $b are normally both objects, each with various members including a
prop q, but sometimes $a is false. i want the q of $a if $a isn't false,
otherwise that of $b.

($a ? $a : $b)->q   // is not php, afaik

before you suggest one, i know there are simple workarounds.

but mine is a theoretical question about syntax, not a practical one. i'm
exploring php's syntactic constraints on the -> operator in contrast to,
say, the + or . operators. and in contrast to other languages.

for example, the . in js seems more generally allowed than -> (or, for that
matter, []) in php. programmers (especially using jquery) are familiar with
using . after an expression that evaluates to an object, e.g.


My x class number is



document.getElementById('num').innerText =
  ( ( document.getElementById('optional')
  || document.getElementById('mandatory')
).appendChild(document.getElementById('thepara'))
.className.match(/x(\d+)/) || [0,'absent']
  )[1]



which shows . after objects, method calls and expressions (as well as the []
operator applied to an expression).

do we just live without in phpville or am i missing something?


and while i'm at it, and using my original error, how come...

function o() { return (object) array('q'=>7); }
echo o()->q;  // is ok syntax, but

function a() { return array('q'=>5); }
echo a()['q'];  // isn't?




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] get an object property

2009-09-12 Thread Ralph Deffke
> echo a()['q'];  // isn't?

because this is simply not valid syntax for the INTERPRETER PHP

while this
> echo o()->q;
can be interpreted because of the design of the interpreter.

I can live with that.

ralph_def...@yahoo.de

"Tom Worster"  wrote in message
news:c6d13522.12422%...@thefsb.org...
> On 9/12/09 9:50 AM, "Tom Worster"  wrote:
>
> > On 9/12/09 1:32 AM, "Lars Torben Wilson"  wrote:
> >
> >> Tom Worster wrote:
> >>> if i have an expression that evaluates to an object, the return value
from a
> >>> function, say, and i only want the value of one of the objects
properties,
> >>> is there a tidy way to get it without setting another variable?
> >>>
> >>> to illustrate, here's something that doesn't work, but it would be
> >>> convenient if it did:
> >>>
> >>> $o = array( (object) array('a'=>1), (object) array('a'=>2) );
> >>>
> >>> if ( end($o)->a > 1 ) {  // can't use -> like this!
> >>> ...
> >>> }
> >>
> >> What version of PHP are you using? Your example should work.
> >>
> >> Torben
> >
> > 5.2.9.
> >
> > what version does it work in?
>
> i shamefully beg your pardon, lars. i was sure i tested the example but
it's
> clear to me now i either didn't or i made a mistake. end($o)->a IS php
> syntax! so -> may follow a function (or method, i guess) call.
>
> but let me give you a more different example:
>
> $a and $b are normally both objects, each with various members including a
> prop q, but sometimes $a is false. i want the q of $a if $a isn't false,
> otherwise that of $b.
>
> ($a ? $a : $b)->q   // is not php, afaik
>
> before you suggest one, i know there are simple workarounds.
>
> but mine is a theoretical question about syntax, not a practical one. i'm
> exploring php's syntactic constraints on the -> operator in contrast to,
> say, the + or . operators. and in contrast to other languages.
>
> for example, the . in js seems more generally allowed than -> (or, for
that
> matter, []) in php. programmers (especially using jquery) are familiar
with
> using . after an expression that evaluates to an object, e.g.
>
> 
> My x class number is
> 
> 
> 
> document.getElementById('num').innerText =
>   ( ( document.getElementById('optional')
>   || document.getElementById('mandatory')
> ).appendChild(document.getElementById('thepara'))
> .className.match(/x(\d+)/) || [0,'absent']
>   )[1]
> 
> 
>
> which shows . after objects, method calls and expressions (as well as the
[]
> operator applied to an expression).
>
> do we just live without in phpville or am i missing something?
>
>
> and while i'm at it, and using my original error, how come...
>
> function o() { return (object) array('q'=>7); }
> echo o()->q;  // is ok syntax, but
>
> function a() { return array('q'=>5); }
> echo a()['q'];  // isn't?
>
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread Jim Lucas

Andrea Giammarchi wrote:

something I cannot find in any other library or framework.


This should tell you something then...

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
   and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
by William Shakespeare

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-12 Thread J DeBord
On Sat, Sep 12, 2009 at 8:47 PM, Jim Lucas  wrote:

> Andrea Giammarchi wrote:
>
>> something I cannot find in any other library or framework.
>>
>
> This should tell you something then...
>
> If something like Formandehyde isn't useful, then why is Charles so popular
(note: popular from my perspective. I wouldn't dare think that it is popular
with anyone on this list unless they expressly told me so)
http://www.charlesproxy.com/ . I can't say anything about the responses
Andrea has gotten without sounding rude and likely starting an internet
fight, so I won't say anything. Except for this. Tedd, the ajax example you
linked to does not need any debugging, that is for sure.


> --
> Jim Lucas
>
>   "Some men are born to greatness, some achieve greatness,
>   and some have greatness thrust upon them."
>
> Twelfth Night, Act II, Scene V
>by William Shakespeare
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


RE: [PHP] get an object property

2009-09-12 Thread Jan Reiter
I have to agree, your example works fine for me. For testing I used the
latest stable Release of server2go with PHP 5.2.10.

Or do you want to use something like that:

class o
{
protected $arr = array('a'=>0);
function o($n){$this->arr['a'] = $n;}
function getA(){return $this->arr['a'];}
}

$o = array( new o(1), new o(2) );


if ( end($o)->getA() > 1 ) {  
echo "yeah";
}

Which works fine as well ... 

Regards,
jan

-Original Message-
From: Tom Worster [mailto:f...@thefsb.org] 
Sent: Saturday, September 12, 2009 1:31 AM
To: PHP General List
Subject: [PHP] get an object property

if i have an expression that evaluates to an object, the return value from a
function, say, and i only want the value of one of the objects properties,
is there a tidy way to get it without setting another variable?

to illustrate, here's something that doesn't work, but it would be
convenient if it did:

$o = array( (object) array('a'=>1), (object) array('a'=>2) );

if ( end($o)->a > 1 ) {  // can't use -> like this!
...
}




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Eingehende eMail ist virenfrei.
Von AVG überprüft - www.avg.de 
Version: 8.5.409 / Virendatenbank: 270.13.71/2336 - Ausgabedatum: 09/11/09
09:15:00 


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Mail Command Body Issue - Trying to use 'do while' loop

2009-09-12 Thread c...@hosting4days.com
I'm having a problem with  mail body issue trying to use 'do while'  
loop in the $mail_body var.


this line:
do { echo $row_get1['name'] } while ($row_get1 = mysql_fetch_assoc 
($get1))


will show ok when it's on the page elsewhere (not in the $mail_body  
var) but typed like:


--- ok on web page (not email)
echo $row_get1['vt_name']; } while ($row_get1 = mysql_fetch_assoc 
($get1)); ?>


Q: i want "TEXT" LOOP "TEXT" - AM I MISSING some syntax characters  
like(; or??) somewhere or 


THANKS for your help - dave

- full email code 

$mail_body = "test \n\n"."test2".do { echo 'test' } while ($row_get1  
= mysql_fetch_assoc($get1))."Thanks

test xxx";  ?>

$header = "From: ". $Name . " <" . $email . ">\r\n"; //optional  
headerfields

$fullto = $recipientname . " <" . $recipient . ">";
//$fullto = $recipientname . " <" . $recipient . ">".", ".$recip2;
ini_set('sendmail_from', 't...@test.com');

mail($fullto, $subject, $mail_body, $header); //mail command :)
?>



Thanks,
c...@hosting4days.com






--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Mail Command Body Issue - Trying to use 'do while' loop

2009-09-12 Thread c...@hosting4days.com


On Sep 12, 2009, at 3:47 PM, c...@hosting4days.com wrote:

I'm having a problem with  mail body issue trying to use 'do while'  
loop in the $mail_body var.


this line:
do { echo $row_get1['name'] } while ($row_get1 = mysql_fetch_assoc 
($get1))


will show ok when it's on the page elsewhere (not in the $mail_body  
var) but typed like:


--- ok on web page (not email)
echo $row_get1['vt_name']; } while ($row_get1 = mysql_fetch_assoc 
($get1)); ?>


Q: i want "TEXT" LOOP "TEXT" - AM I MISSING some syntax characters  
like(; or??) somewhere or 


THANKS for your help - dave



I got it working like this




Q: is this the best way?





- full email code 

$mail_body = "test \n\n"."test2".do { echo 'test' } while  
($row_get1 = mysql_fetch_assoc($get1))."Thanks

test xxx";  ?>

$header = "From: ". $Name . " <" . $email . ">\r\n"; //optional  
headerfields

$fullto = $recipientname . " <" . $recipient . ">";
//$fullto = $recipientname . " <" . $recipient . ">".", ".$recip2;
ini_set('sendmail_from', 't...@test.com');

mail($fullto, $subject, $mail_body, $header); //mail command :)
?>



Thanks,
c...@hosting4days.com






--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php





Thanks,
c...@hosting4days.com






--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP 5.3 & PECL & WINDOWS: Compile | VirtualPC | VirtualBox

2009-09-12 Thread steve
Since it has been about a year with no PECL extensions for windows,
and I don't think theire ever will be, and I want to move to 5.3,
there are tough choices.

A: I can try downloading from source and compiling the pecl binaries
on windows. No experience compiling on windows, but I guess I can go
there...

B: Install a stripped down non-gui version of Ubuntu into VirtualPC or
VirtualBox, both of which I have on Windows7 here. Anyone know what
the performance of either would be? does one work faster than the
other? If we go this route, I might also have the Mac people do this
too.

Thanks!

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Odd Endless Loop with Explorer 8 (pc)

2009-09-12 Thread c...@hosting4days.com

I have many of these tags on a site...

They work well with all browsers i've tested - except  explorer 8 (pc)

'; ?>

It just goes into an endless loop but stays on the original page -  
never going to page2.php



Q: Any idea how to fix this?




Thanks,
c...@hosting4days.com






--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Odd Endless Loop with Explorer 8 (pc)

2009-09-12 Thread kranthi
> '; ?>
may b u should have
'; ?>

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] Odd Endless Loop with Explorer 8 (pc)

2009-09-12 Thread HallMarc Websites


> -Original Message-
> From: c...@hosting4days.com [mailto:c...@hosting4days.com]
> Sent: Saturday, September 12, 2009 10:39 PM
> To: php-general@lists.php.net
> Subject: [PHP] Odd Endless Loop with Explorer 8 (pc)
> 
> I have many of these tags on a site...
> 
> They work well with all browsers i've tested - except  explorer 8 (pc)
> 
> '; ?>
> 
> It just goes into an endless loop but stays on the original page -
> never going to page2.php
> 
> 
> Q: Any idea how to fix this?
> 
> 
> 
> 
> Thanks,
> c...@hosting4days.com
> 
> 

[HallMarc Websites] 
you are missing url=page2.php

'; ?>
 

______ Information from ESET Smart Security, version of virus signature
database 4420 (20090912) __

The message was checked by ESET Smart Security.

http://www.eset.com
 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Odd Endless Loop with Explorer 8 (pc)

2009-09-12 Thread c...@hosting4days.com


On Sep 12, 2009, at 7:57 PM, kranthi wrote:


'; ?>

may b u should have
'; ?>


Thanks kranthi & HallMarc Websites

url= ... - that did the trick!



Thanks,
c...@hosting4days.com






--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Reading files in PHP 5.3.0

2009-09-12 Thread Paul M Foster
On Sat, Sep 12, 2009 at 10:22:10AM -0400, tedd wrote:

> At 6:02 PM -0400 9/11/09, Paul M Foster wrote:
>>
>> I typically use us2.php.net, which is hosted by Hurricane Electric.
>>
>> Paul
>
> Paul:
>
> I wouldn't use Hurricane Electric if their accounts were provided for free!
>
> The following is an experience I had with Hurricane Electric and
> support for my opinion as to their "service".
>
> You see, many years ago Hurricane Electric hosted (IMO with
> complicity) a porn site that sent out over 2000 porn spams to AOL
> using MY email address as the person to contact. That incident caused
> me a great deal of trouble.
>
> In an attempt to understand and resolve the problem, I sent several
> emails to Hurricane Electric; I called them numerous times via
> telephone; and I even sent them letters via the US mail. But
> unfortunately they refused to answer ANY of my correspondence. Their
> lack of communication provided support for my opinion of their
> complicity with what had happened.
>
> A few years back they contacted me (again more spam) soliciting my
> interest in hosting with them. Normally, I would have just reported
> such spam to spamcop, but because of the incident I replied and told
> them what had happened.
>
> Later I was contacted by one of their technicians who looked thorough
> their records and confirmed/admitted the incident. However, he told
> me that they could not be held responsible for they clients they
> host. Furthermore, they have no intention of screening their clients.
> He said that they will provide hosting to whomever they want,
> including porn and spam sites. If their clients do anything wrong per
> "their standards", then they will deal with it internally. Otherwise
> they don't care about any harm done to anyone by them hosting such
> sites. In short, they want the money but not the responsibility.
>
> Now, maybe Hurricane Electric has changed its ways, but they can't
> change their past.
>
> In my opinion, there are more than enough hosting companies who care
> about the damage they might cause and take steps to reduce the about
> spam and porn on the net. My advice, seek hosts other than Hurricane
> Electric.

I don't know much about HE, other than the fact that they run ads in
Linux Journal. But they're a real hosting company, like Rackspace or
1and1. Yahoo (who hosts www.php.net) isn't a company I think of as a
hosting company. And they're an internet behemoth, like Godaddy or
Microsoft. So I'd personally steer away from them. Just my bias.

It sounds like HE's real problem is their TOS. I've hosted with a lot of
companies who will drop accounts where they find porn, spam and warez;
it's part of their TOS. The other problem I can see is that they are
apparently unwilling to even mediate a problem between two of their
accounts. "We just host 'em. Other than that, we don't care." Typical. I
expect the porn company paid them a *lot* more money than you did, so
they simply looked the other way. A shame.

The lesson, I suppose, is to look at the terms of service before you
sign up with a hosting company. You may still end up being a victim, but
at least you know what you're getting yourself into. If they don't
specifically disavow porn, spam and warez, then they allow (and in
effect, condone) it.

Paul

-- 
Paul M. Foster

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php