Forum Moderators: open

Message Too Old, No Replies

importing? styled text

         

ctoz

9:41 am on Feb 18, 2008 (gmt 0)

10+ Year Member



Hi folks,

Slow learner, with a problem.

I have a page on which there will be a choice of multiple divs of styled text, each approx 4KB.

Each div is to appear in the same position within the window; and each is triggered from two different links. And the links are not <a> tags, or forms, but other divs, using 'onclick'.

Already the page, without the extra text divs is around 60KB. I can in add all the text divs, but this will take the size to > 300KB.

Q1:
Should this size be a worry in terms of loading time?

I can go this route, because I can do the fairly crude javascript needed to hide and show the text divs as needed. Stress is on "crude".

Q2 etc:
But is there some relatively simple way to import the texts as required, using javascript? An ajax library with some tutorials, maybe?

Am I correct in thinking that PHP needs a form in order to do this sort of replacement, of one text by another?

cheers

[edited by: tedster at 7:08 pm (utc) on Feb. 18, 2008]

mehh

10:18 am on Feb 18, 2008 (gmt 0)

10+ Year Member



But is there some relatively simple way to import the texts as required, using javascript? An ajax library with some tutorials, maybe?

Yes. There are several ajax librarys out there, each has it own style and most have alot of documentation. I'm sure everyone on this forum will have their favorites, so it is imposible to recomend just one. Its a matter of finding one that suits you. Here is a list of some of the most popular ones:

I can't think of any more at the moment

ctoz

1:10 am on Feb 19, 2008 (gmt 0)

10+ Year Member



thanks