Reply to Re: DOM doc - simple find element PHP+JS

Your name:

Reply:


Posted by one man army on 01/22/06 07:03

In article <tfudnd0VXYeTaU3eRVn-uw@comcast.com>,
Randy Webb <HikksNotAtHome@aol.com> wrote STUFF

> how to quote
[yeah, I did not quote 'cause every news reader shows the thread easily,
anyway. Why waste lines? - I tried to write Randy back via email but the
email addr doesn't go. So I post again. ]

I pulled off the JS->PHP document.body.appendChild() hack, only to find
that after setting an element in the page to the result of the PHP mySQL
Query, I read the element with Javascript and it is "not yet changed".
Some kind of latency problem ( guessing). In other lives I have
initiated an event (chaining) and then handled the response in the
subsequent event. I do not know how to do that in this
HTML/Javascript/PHP combo.

TO make progress I have reverted to a simple form action o nthe intro
page, with the SQL in a target PHP file, then redirect to the main page
upon success.

Now I face coding the main page, where I DO want dynamic updates (using
"dynamically loaded scripts" apparently). I have a simple version
already, using Javascript only. Simple meaning 500 lines of js. I now
need the MySQL because the real db engine has deeper requirements than
my JS demo handles.

I would be willing to call Perl to do the MySQL, but the main point is
not to jump around to URLs and redraw the page. I thought the
dynamically loading script would be a neat solution. But reading the
result is now apparently a problem.

Or I need another way to pass back the result other than: setting an
element in the page to a value (latency problem); or passing it through
a URL (causes a redraw of the page). I have noticed that sometimes the
browser is smart and sees that the URL is the same and does a smart
refresh, but that is not guranteed.

So I do appreciate the insights. As I said, I am new to this. Further
discussion is welcome, or I'll start a new thread on the chaining topic
or something...

best regards -brian

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация