Re: Creating drop-down menus

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 17, 2012 at 4:58 PM, Paul M Foster <paulf@xxxxxxxxxxxxxxxxx> wrote:
> On Wed, Jul 18, 2012 at 08:45:34AM +1200, James Newman wrote:
>
>> Just to put my 2cents in, you might want to try jQuery if you're going to
>> go down the AJAX road.
>
> JQuery is a LOT of code to include if you're just going to do an AJAX
> call or two. There are examples of doing straight AJAX with Javascript
> on the 'Net. Once you work through them, you find that there's a
> "static" part that you can include in all the files you want to make
> AJAX calls. And then there's the part that deals directly with the data
> you get back from whatever PHP or other script is feeding you data from
> outside the website. That's the part that needs custom work. I *hate*
> Javascript, but I managed to figure it out.
>
> Another point: I'm not sure if it's the same for other people. I'm on a
> crappy little computer running Linux. I've got a little CPU meter in my
> taskbar. And nothing jacks that meter up like Javascript. I don't know
> why, but Javascript just devours CPU on my computer. The more
> javascript, the worse. And like I said, JQuery is a LOT of code. This is
> one of the reasons I tend to code things in PHP instead of Javascript.
>
> Paul
>

I found some time ago that a lot of those simple little AJAX examples
actually cause Javascript memory leaks. You can search the web to
learn how to handle the resources correctly yourself, but the
libraries like jQuery and YUI that are available do it for you and
seem to eliminate most of the leaks that I've seen. YMMV.

Andrew

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



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux