php-general Digest 3 Feb 2010 18:58:27 -0000 Issue 6572

Topics (messages 301781 through 301793):

Re: database abstraction layer
        301781 by: Lester Caine

Re: session variables and SVG documents
        301782 by: Aurelie REYMUND
        301784 by: Ashley Sheridan
        301785 by: tedd
        301786 by: Adam Richardson

Re: DOM TextArea (and dom chart please)
        301783 by: Michael A. Peters
        301787 by: Ryan S

Thinking of moving to .NET because of standalone... any suggestions?
        301788 by: Ryan S
        301789 by: Jochem Maas
        301790 by: Robert Cummings
        301791 by: Michael A. Peters
        301792 by: Robert Cummings
        301793 by: Ryan S

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 ---
Ashley Sheridan wrote:
On Tue, 2010-02-02 at 23:19 +0100, Rene Veerman wrote:

function getMax($table, $field)

If I saw this sort of code I'd be appalled! It's possibly the worst way
to get the auto increment value. You won't notice it testing the site
out on your own, but all hell will break loose when you start getting a
lot of hits, and two people cause an auto increment at the same time!

ADOdb handles SEQUENCE correctly across all databases. Since MySQL does not understand SEQUENCE or GENERATOR, ADOdb simulates it with a dummy table which autoincrements and gets around the problem. Then one can use a secure generic GetID ;)

--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php

--- End Message ---
--- Begin Message ---
Hello,

unfortunately, it does not suite my needs. The image must be clickable. The
application I'm developping reads data from a database and display the
information graphically. The user must be able to click on some elements of
the picture, and I have to store the information the user clicked on
(session vars). I cannot tell the user not to use IE, so I have to find
another solution...

Regards,
Aurelie

2010/2/1 Ray Solomon <[email protected]>

> From: "Aurelie REYMUND" <[email protected]>
> Sent: Monday, February 01, 2010 3:37 AM
> To: <[email protected]>
> Subject: [PHP] session variables and SVG documents
>
>
>  Hello,
>>
>> I have the following problem with the Adobe SVG viewer:
>> I try to generate a SVG document using PHP. the following code is working
>> well under Firefox, as well as IE with ASV:
>>
>> <?php
>>
>> header("Content-type: image/svg+xml");
>>
>> $graph_title = 'title';
>>
>>
>> print('<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>');
>> $svgwidth=500;
>> $svgheight=400;
>> ?>
>>
>> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "
>> http://www.w3.org/TR/SVG/DTD/svg10.dtd";>
>> <svg width="<?php echo $svgwidth; ?>px" height="<?php echo $svgheight;
>> ?>px"
>> xmlns="http://www.w3.org/2000/svg";>
>>   <desc>This is a php-random rectangle test</desc>
>> <?php
>> srand((double) microtime() * 1000000); //initalizing random generator
>> for ($i = 0; $i < 20; $i+=1) {
>>   $x = floor(rand(0,$svgwidth-1)); //avoid getting a range 0..0 for rand
>> function
>>   $y = floor(rand(0,$svgheight-1));
>>   $width = floor(rand(0,$svgwidth-$x)); //avoid getting rect outside of
>> viewbox
>>   $height = floor(rand(0,$svgheight-$y));
>>   $red = floor(rand(0,255));
>>   $blue = floor(rand(0,255));
>>   $green = floor(rand(0,255));
>>   $color = "rgb(".$red.",".$green.",".$
>> blue.")";
>>   print "\t<rect x=\"$x\" y=\"$y\" width=\"$width\" height=\"$height\"
>> style=\"fill:$color;\"/>\n";
>> }
>> ?>
>>   <text x="<?php echo $svgwidth/2;?>px" y="300" style="font-size:15;"
>> text-anchor="middle">The servers Date and Time is: <?php print
>> (strftime("%Y-%m-%d, %H:%M:%S")); ?></text>
>>   <text x="<?php echo $svgwidth/2;?>px" y="340" style="font-size:15;"
>> text-anchor="middle">You are running:</text>
>>   <text x="<?php echo $svgwidth/2;?>px" y="360" style="font-size:15;"
>> text-anchor="middle"><?php print $HTTP_USER_AGENT; ?></text>
>> </svg>
>>
>> If now I want to include the session_start() at the beginning of the code,
>> in IE I got a pop-up dialog called "download file"
>>
>> What am I doing wrong ?
>>
>> Regards,
>> Aurelie
>>
>>
>
> It appears IE does not support svg yet and you need a plugin for it.
>
> However, you could also design your code differently by using Imagemagick
> to convert the svg to png.
> If that suits your needs, then use the modified code below:
>
>
> <?php
>
> header("Content-type: image/png");
>
> $graph_title = 'title';
>
> $svgwidth=500;
> $svgheight=400;
>
> $svg = '<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
> <svg width="'.$svgwidth.'px" height="'.$svgheight.'px" xmlns="
> http://www.w3.org/2000/svg";>
>   <desc>This is a php-random rectangle test</desc>';
>
>
> for ($i = 0; $i < 20; $i++) {
>
>        $x = floor(rand(0,$svgwidth-1));
>        $y = floor(rand(0,$svgheight-1));
>        $width = floor(rand(0,$svgwidth-$x));
>        $height = floor(rand(0,$svgheight-$y));
>        $red = floor(rand(0,255));
>        $blue = floor(rand(0,255));
>        $green = floor(rand(0,255));
>        $color = "rgb(".$red.",".$green.",".$blue.")";
>        $svg .= "\t<rect x=\"$x\" y=\"$y\" width=\"$width\"
> height=\"$height\" style=\"fill:$color;\"/>\n";
> }
>
>   $svg .= '<text x="'.($svgwidth/2).'px" y="300" style="font-size:15;"
> text-anchor="middle">The servers Date and Time is: '.date("Y-m-d,
> H:m:s").'</text>
>   <text x="'.($svgwidth/2).'px" y="340" style="font-size:15;"
> text-anchor="middle">You are running:</text>
>   <text x="'.($svgwidth/2).'px" y="360" style="font-size:15;"
> text-anchor="middle">'.$HTTP_USER_AGENT.'</text>
> </svg>';
>
>
> file_put_contents('/tmp/image.svg', $svg);
>
> exec("/usr/bin/rsvg /tmp/image.svg /tmp/image.png");
>
> echo file_get_contents('/tmp/image.png');
> ?>
>
> -Ray Solomon
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

--- End Message ---
--- Begin Message ---
On Wed, 2010-02-03 at 10:49 +0100, Aurelie REYMUND wrote:

> Hello,
> 
> unfortunately, it does not suite my needs. The image must be clickable. The
> application I'm developping reads data from a database and display the
> information graphically. The user must be able to click on some elements of
> the picture, and I have to store the information the user clicked on
> (session vars). I cannot tell the user not to use IE, so I have to find
> another solution...
> 
> Regards,
> Aurelie
> 
> 2010/2/1 Ray Solomon <[email protected]>
> 
> > From: "Aurelie REYMUND" <[email protected]>
> > Sent: Monday, February 01, 2010 3:37 AM
> > To: <[email protected]>
> > Subject: [PHP] session variables and SVG documents
> >
> >
> >  Hello,
> >>
> >> I have the following problem with the Adobe SVG viewer:
> >> I try to generate a SVG document using PHP. the following code is working
> >> well under Firefox, as well as IE with ASV:
> >>
> >> <?php
> >>
> >> header("Content-type: image/svg+xml");
> >>
> >> $graph_title = 'title';
> >>
> >>
> >> print('<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>');
> >> $svgwidth=500;
> >> $svgheight=400;
> >> ?>
> >>
> >> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "
> >> http://www.w3.org/TR/SVG/DTD/svg10.dtd";>
> >> <svg width="<?php echo $svgwidth; ?>px" height="<?php echo $svgheight;
> >> ?>px"
> >> xmlns="http://www.w3.org/2000/svg";>
> >>   <desc>This is a php-random rectangle test</desc>
> >> <?php
> >> srand((double) microtime() * 1000000); //initalizing random generator
> >> for ($i = 0; $i < 20; $i+=1) {
> >>   $x = floor(rand(0,$svgwidth-1)); //avoid getting a range 0..0 for rand
> >> function
> >>   $y = floor(rand(0,$svgheight-1));
> >>   $width = floor(rand(0,$svgwidth-$x)); //avoid getting rect outside of
> >> viewbox
> >>   $height = floor(rand(0,$svgheight-$y));
> >>   $red = floor(rand(0,255));
> >>   $blue = floor(rand(0,255));
> >>   $green = floor(rand(0,255));
> >>   $color = "rgb(".$red.",".$green.",".$
> >> blue.")";
> >>   print "\t<rect x=\"$x\" y=\"$y\" width=\"$width\" height=\"$height\"
> >> style=\"fill:$color;\"/>\n";
> >> }
> >> ?>
> >>   <text x="<?php echo $svgwidth/2;?>px" y="300" style="font-size:15;"
> >> text-anchor="middle">The servers Date and Time is: <?php print
> >> (strftime("%Y-%m-%d, %H:%M:%S")); ?></text>
> >>   <text x="<?php echo $svgwidth/2;?>px" y="340" style="font-size:15;"
> >> text-anchor="middle">You are running:</text>
> >>   <text x="<?php echo $svgwidth/2;?>px" y="360" style="font-size:15;"
> >> text-anchor="middle"><?php print $HTTP_USER_AGENT; ?></text>
> >> </svg>
> >>
> >> If now I want to include the session_start() at the beginning of the code,
> >> in IE I got a pop-up dialog called "download file"
> >>
> >> What am I doing wrong ?
> >>
> >> Regards,
> >> Aurelie
> >>
> >>
> >
> > It appears IE does not support svg yet and you need a plugin for it.
> >
> > However, you could also design your code differently by using Imagemagick
> > to convert the svg to png.
> > If that suits your needs, then use the modified code below:
> >
> >
> > <?php
> >
> > header("Content-type: image/png");
> >
> > $graph_title = 'title';
> >
> > $svgwidth=500;
> > $svgheight=400;
> >
> > $svg = '<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
> > <svg width="'.$svgwidth.'px" height="'.$svgheight.'px" xmlns="
> > http://www.w3.org/2000/svg";>
> >   <desc>This is a php-random rectangle test</desc>';
> >
> >
> > for ($i = 0; $i < 20; $i++) {
> >
> >        $x = floor(rand(0,$svgwidth-1));
> >        $y = floor(rand(0,$svgheight-1));
> >        $width = floor(rand(0,$svgwidth-$x));
> >        $height = floor(rand(0,$svgheight-$y));
> >        $red = floor(rand(0,255));
> >        $blue = floor(rand(0,255));
> >        $green = floor(rand(0,255));
> >        $color = "rgb(".$red.",".$green.",".$blue.")";
> >        $svg .= "\t<rect x=\"$x\" y=\"$y\" width=\"$width\"
> > height=\"$height\" style=\"fill:$color;\"/>\n";
> > }
> >
> >   $svg .= '<text x="'.($svgwidth/2).'px" y="300" style="font-size:15;"
> > text-anchor="middle">The servers Date and Time is: '.date("Y-m-d,
> > H:m:s").'</text>
> >   <text x="'.($svgwidth/2).'px" y="340" style="font-size:15;"
> > text-anchor="middle">You are running:</text>
> >   <text x="'.($svgwidth/2).'px" y="360" style="font-size:15;"
> > text-anchor="middle">'.$HTTP_USER_AGENT.'</text>
> > </svg>';
> >
> >
> > file_put_contents('/tmp/image.svg', $svg);
> >
> > exec("/usr/bin/rsvg /tmp/image.svg /tmp/image.png");
> >
> > echo file_get_contents('/tmp/image.png');
> > ?>
> >
> > -Ray Solomon
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >


IE doesn't display SVG natively, and the plugins for it are pants.
However, IE does make use of its own propitiatory vector language called
VML, This is how the Cufon font replacer system works.

Thanks,
Ash
http://www.ashleysheridan.co.uk



--- End Message ---
--- Begin Message ---
At 10:49 AM +0100 2/3/10, Aurelie REYMUND wrote:
Hello,

unfortunately, it does not suite my needs. The image must be clickable. The
application I'm developping reads data from a database and display the
information graphically. The user must be able to click on some elements of
the picture, and I have to store the information the user clicked on
(session vars). I cannot tell the user not to use IE, so I have to find
another solution...

Regards,
Aurelie


Aurelie:

The image must be clickable?

I must not be understanding something. Anything can be made clickable, just put it in an anchor, such as:

<a href="my-php-script-to-produce-the-image.php">Click This</a>

The previous post mentioned using ImageMagick to convert the svg to png -- so write that script and place it in an anchor. I don't see the problem.

Cheers,

tedd

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

--- End Message ---
--- Begin Message ---
On Wed, Feb 3, 2010 at 8:20 AM, Ashley Sheridan 
<[email protected]>wrote:

> On Wed, 2010-02-03 at 10:49 +0100, Aurelie REYMUND wrote:
>
> > Hello,
> >
> > unfortunately, it does not suite my needs. The image must be clickable.
> The
> > application I'm developping reads data from a database and display the
> > information graphically. The user must be able to click on some elements
> of
> > the picture, and I have to store the information the user clicked on
> > (session vars). I cannot tell the user not to use IE, so I have to find
> > another solution...
> >
> > Regards,
> > Aurelie
> >
> > 2010/2/1 Ray Solomon <[email protected]>
> >
> > > From: "Aurelie REYMUND" <[email protected]>
> > > Sent: Monday, February 01, 2010 3:37 AM
> > > To: <[email protected]>
> > > Subject: [PHP] session variables and SVG documents
> > >
> > >
> > >  Hello,
> > >>
> > >> I have the following problem with the Adobe SVG viewer:
> > >> I try to generate a SVG document using PHP. the following code is
> working
> > >> well under Firefox, as well as IE with ASV:
> > >>
> > >> <?php
> > >>
> > >> header("Content-type: image/svg+xml");
> > >>
> > >> $graph_title = 'title';
> > >>
> > >>
> > >> print('<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>');
> > >> $svgwidth=500;
> > >> $svgheight=400;
> > >> ?>
> > >>
> > >> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "
> > >> http://www.w3.org/TR/SVG/DTD/svg10.dtd";>
> > >> <svg width="<?php echo $svgwidth; ?>px" height="<?php echo $svgheight;
> > >> ?>px"
> > >> xmlns="http://www.w3.org/2000/svg";>
> > >>   <desc>This is a php-random rectangle test</desc>
> > >> <?php
> > >> srand((double) microtime() * 1000000); //initalizing random generator
> > >> for ($i = 0; $i < 20; $i+=1) {
> > >>   $x = floor(rand(0,$svgwidth-1)); //avoid getting a range 0..0 for
> rand
> > >> function
> > >>   $y = floor(rand(0,$svgheight-1));
> > >>   $width = floor(rand(0,$svgwidth-$x)); //avoid getting rect outside
> of
> > >> viewbox
> > >>   $height = floor(rand(0,$svgheight-$y));
> > >>   $red = floor(rand(0,255));
> > >>   $blue = floor(rand(0,255));
> > >>   $green = floor(rand(0,255));
> > >>   $color = "rgb(".$red.",".$green.",".$
> > >> blue.")";
> > >>   print "\t<rect x=\"$x\" y=\"$y\" width=\"$width\" height=\"$height\"
> > >> style=\"fill:$color;\"/>\n";
> > >> }
> > >> ?>
> > >>   <text x="<?php echo $svgwidth/2;?>px" y="300" style="font-size:15;"
> > >> text-anchor="middle">The servers Date and Time is: <?php print
> > >> (strftime("%Y-%m-%d, %H:%M:%S")); ?></text>
> > >>   <text x="<?php echo $svgwidth/2;?>px" y="340" style="font-size:15;"
> > >> text-anchor="middle">You are running:</text>
> > >>   <text x="<?php echo $svgwidth/2;?>px" y="360" style="font-size:15;"
> > >> text-anchor="middle"><?php print $HTTP_USER_AGENT; ?></text>
> > >> </svg>
> > >>
> > >> If now I want to include the session_start() at the beginning of the
> code,
> > >> in IE I got a pop-up dialog called "download file"
> > >>
> > >> What am I doing wrong ?
> > >>
> > >> Regards,
> > >> Aurelie
> > >>
> > >>
> > >
> > > It appears IE does not support svg yet and you need a plugin for it.
> > >
> > > However, you could also design your code differently by using
> Imagemagick
> > > to convert the svg to png.
> > > If that suits your needs, then use the modified code below:
> > >
> > >
> > > <?php
> > >
> > > header("Content-type: image/png");
> > >
> > > $graph_title = 'title';
> > >
> > > $svgwidth=500;
> > > $svgheight=400;
> > >
> > > $svg = '<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
> > > <svg width="'.$svgwidth.'px" height="'.$svgheight.'px" xmlns="
> > > http://www.w3.org/2000/svg";>
> > >   <desc>This is a php-random rectangle test</desc>';
> > >
> > >
> > > for ($i = 0; $i < 20; $i++) {
> > >
> > >        $x = floor(rand(0,$svgwidth-1));
> > >        $y = floor(rand(0,$svgheight-1));
> > >        $width = floor(rand(0,$svgwidth-$x));
> > >        $height = floor(rand(0,$svgheight-$y));
> > >        $red = floor(rand(0,255));
> > >        $blue = floor(rand(0,255));
> > >        $green = floor(rand(0,255));
> > >        $color = "rgb(".$red.",".$green.",".$blue.")";
> > >        $svg .= "\t<rect x=\"$x\" y=\"$y\" width=\"$width\"
> > > height=\"$height\" style=\"fill:$color;\"/>\n";
> > > }
> > >
> > >   $svg .= '<text x="'.($svgwidth/2).'px" y="300" style="font-size:15;"
> > > text-anchor="middle">The servers Date and Time is: '.date("Y-m-d,
> > > H:m:s").'</text>
> > >   <text x="'.($svgwidth/2).'px" y="340" style="font-size:15;"
> > > text-anchor="middle">You are running:</text>
> > >   <text x="'.($svgwidth/2).'px" y="360" style="font-size:15;"
> > > text-anchor="middle">'.$HTTP_USER_AGENT.'</text>
> > > </svg>';
> > >
> > >
> > > file_put_contents('/tmp/image.svg', $svg);
> > >
> > > exec("/usr/bin/rsvg /tmp/image.svg /tmp/image.png");
> > >
> > > echo file_get_contents('/tmp/image.png');
> > > ?>
> > >
> > > -Ray Solomon
> > >
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
> > >
>
>
> IE doesn't display SVG natively, and the plugins for it are pants.
> However, IE does make use of its own propitiatory vector language called
> VML, This is how the Cufon font replacer system works.
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
Maybe svgweb (by Google) would allow you to achieve your goals:
http://code.google.com/p/svgweb/

Adam

-- 
Nephtali:  PHP web framework that functions beautifully
http://nephtaliproject.com

--- End Message ---
--- Begin Message ---
Michael A. Peters wrote:


$website_data = new tidy('dom_test.html',$tidy_config);

Doh!

Should be

$website_data = new tidy('dom_test.html',$tidy_config,'utf8');

Otherwise it has the same problem with multibyte characters that loadHTML() has. But with the 'utf8' specified it works beautifully.
--- End Message ---
--- Begin Message ---


> I think what you are looking for is $input2->textContent in PHP.

Hey Andrew (and everyone else was was kind enough to write back) !

Found the solution, this is what i am using (and it works!), and i hope it 
helps anyone else who finds themselves in the spot i found myself

$inputs2 = $dom->getElementsByTagName('textarea'); // Find textareas  
foreach ($inputs2 as $input2) { 
        if(!$input2->nodeValue || $input2->nodeValue=="") { 
                $input2->nodeValue="it works!"; 
        } 
} 


Cheers guys!
/R



      

--- End Message ---
--- Begin Message ---
Hey Guys,

Coming from a C and Java background I just loved PHP and have been programming 
with it for years thanks in a large part to the kind people on this list... 
present and past (Immediately the name John Holmes comes to mind.. i hope the 
dude is well)
but now I have have to leave PHP or split time between php and .NET for just 
one reason:

.NET offers a way to run programs using the Windows GUI / stand alone executable

There always was talk on the list about running php code as standalone, but 
since I had a long absence from the list sorry if I missed any new updates... 
but I'm hoping someone can offer a way to run php standalone executable.

Before posting I always google, and the main results I have gotten so far is:
priado blender
and PHP-GTK

but no way to kind of drag and drop what you need like visual studio (i dont 
know how to use it yet, but been reading) or some other visual development tool 
like visual basic.

I need to make a few standalones programs that will run (mostly) on Windows... 
is there any other way that I have not found that i can use PHP instead of 
learning something new like .NET?

I have resisted going "the microsoft way" for years.. looks like my luck has 
run out...

Thanks,
Ryan



      

--- End Message ---
--- Begin Message ---
Op 2/3/10 6:09 PM, Ryan S schreef:
> Hey Guys,
> 
> Coming from a C and Java background I just loved PHP and have been 
> programming with it for years thanks in a large part to the kind people on 
> this list... present and past (Immediately the name John Holmes comes to 
> mind.. i hope the dude is well)
> but now I have have to leave PHP or split time between php and .NET for just 
> one reason:
> 
> .NET offers a way to run programs using the Windows GUI / stand alone 
> executable
> 
> There always was talk on the list about running php code as standalone, but 
> since I had a long absence from the list sorry if I missed any new updates... 
> but I'm hoping someone can offer a way to run php standalone executable.
> 
> Before posting I always google, and the main results I have gotten so far is:
> priado blender
> and PHP-GTK
> 
> but no way to kind of drag and drop what you need like visual studio (i dont 
> know how to use it yet, but been reading) or some other visual development 
> tool like visual basic.
> 
> I need to make a few standalones programs that will run (mostly) on 
> Windows... is there any other way that I have not found that i can use PHP 
> instead of learning something new like .NET?
> 
> I have resisted going "the microsoft way" for years.. looks like my luck has 
> run out...

I don't think that you'll get much else than Blender or PHP-GTK - so from that 
perspective
I'd hazard a guess that your not going to be finding anything that will allow 
you use php
for desktop development in the way you require.

come to think of it M$ has been doing something to shoehorn PHP into the .NET 
env ... I have
no idea whether this would be anything that could bare fruit for you, you'd 
have to google.

as an alternative you might consider Adobe Flex Builder - you get WYSIWYG-ness, 
you can leverage javascript
skills (by way of ActionScript) and it's runs on the AIR platform - so it's 
nice and desktoppy but
with the added bonus of being cross-platform. just a thought.

> 
> Thanks,
> Ryan
> 
> 
> 
>       
> 


--- End Message ---
--- Begin Message ---
Ryan S wrote:
Hey Guys,

Coming from a C and Java background I just loved PHP and have been programming 
with it for years thanks in a large part to the kind people on this list... 
present and past (Immediately the name John Holmes comes to mind.. i hope the 
dude is well)
but now I have have to leave PHP or split time between php and .NET for just 
one reason:

.NET offers a way to run programs using the Windows GUI / stand alone executable

There always was talk on the list about running php code as standalone, but 
since I had a long absence from the list sorry if I missed any new updates... 
but I'm hoping someone can offer a way to run php standalone executable.

Before posting I always google, and the main results I have gotten so far is:
priado blender
and PHP-GTK

but no way to kind of drag and drop what you need like visual studio (i dont 
know how to use it yet, but been reading) or some other visual development tool 
like visual basic.

I need to make a few standalones programs that will run (mostly) on Windows... 
is there any other way that I have not found that i can use PHP instead of 
learning something new like .NET?

I have resisted going "the microsoft way" for years.. looks like my luck has 
run out...

This is not my area of familiarity but I believe there is also something called WxWidgets (or something similarly named) for doing similar. It may be closer to the Windows metal. I wonder too if HipHop, that new PHP to C++ compiled binary thing from Facebook, might also have potential in this kind of standalone arena.

Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP

--- End Message ---
--- Begin Message ---
Ryan S wrote:


I need to make a few standalones programs that will run (mostly) on
Windows... is there any other way that I have not found that i can
use PHP instead of learning something new like .NET?

Use the best tool for the job.

I suspect that if your primary target is MS you will have an application that is more consistent with MS interface guidelines if you use MS tools to develop it.

I've only played a little bit with php-gtk and just didn't "get it" but I do know the few times I have used Windows, the gtk+ apps I used on it always felt a bit out of place (so does iTunes, btw) on the system.

I don't know the details, but I know that at least some .NET apps can be ported to *nix without too much trouble using mono, so by using .NET you may not be sacrificing portability.

I'm not saying use .NET, I don't know, but if I was developing GUI desktop apps where Windows was the primary target, I would use a Windows native programming environment to do it as I suspect it would result in far less headaches and far easier time finding solutions to problems via google when I'm stumped.

I believe .NET is pretty much how it is done on Windows now (but I really don't know, I stay away from Windows, I'm a ABM'r).

Just my 2 cents.

--- End Message ---
--- Begin Message ---
Robert Cummings wrote:
Ryan S wrote:
Hey Guys,

Coming from a C and Java background I just loved PHP and have been programming 
with it for years thanks in a large part to the kind people on this list... 
present and past (Immediately the name John Holmes comes to mind.. i hope the 
dude is well)
but now I have have to leave PHP or split time between php and .NET for just 
one reason:

.NET offers a way to run programs using the Windows GUI / stand alone executable

There always was talk on the list about running php code as standalone, but 
since I had a long absence from the list sorry if I missed any new updates... 
but I'm hoping someone can offer a way to run php standalone executable.

Before posting I always google, and the main results I have gotten so far is:
priado blender
and PHP-GTK

but no way to kind of drag and drop what you need like visual studio (i dont 
know how to use it yet, but been reading) or some other visual development tool 
like visual basic.

I need to make a few standalones programs that will run (mostly) on Windows... 
is there any other way that I have not found that i can use PHP instead of 
learning something new like .NET?

I have resisted going "the microsoft way" for years.. looks like my luck has 
run out...

This is not my area of familiarity but I believe there is also something called WxWidgets (or something similarly named) for doing similar. It may be closer to the Windows metal. I wonder too if HipHop, that new PHP to C++ compiled binary thing from Facebook, might also have potential in this kind of standalone arena.

I just did a quick google and there's WinBinder.

Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP

--- End Message ---
--- Begin Message ---
Thanks for the reply Michael, Robert and Jochem,

makes sense, a native windows app is going to look more in place than any of 
the demos and graphics i have seen of GTK.

Was also looking at GTK-Builder, unfortunately you really have to hunt for each 
scrap of new info - which is why I'm guessing open source falls back a bit 
compared to M$'s offerings.

MS shoehorning something into dotnet sounds interesting, will ask my pal google 
what he can bring up ;)
I did read about FLEX but i have pretty much complete php scripts that i want 
to use in a desktop environment, FLEX wouldnt do for my (present) needs.

Will look up WxWidgets and HipHop (somehow i get the feeling i'm gonna be 
drowned in millions of results that have rap lyrics instead of programming 
information - should be a test of my patience :-))    )

Anyone have anything more to add/advise, please do so.

Cheers guys!



      

--- End Message ---

Reply via email to