Re: New PHP User with a simple question

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

 



Christopher W wrote:
At least I hope it is simple...

I am trying to get an HTML menu link to set a variable's value. For example, when a user clicks the "Home" button on my page it would cause $page = "home"; or clicking the "About Us" button will set $page="about_us"; etc.

I think this should be fairly simple but being completely new to php I just cannot seem to get it right.

Any help would be greatly appreciate.

Thank you in advance.

Christopher,

Rather then criticizing you, I would like to point you in the direction that you describe in your responses to the others that are.

So, it sounds to me like you do not want to reload/change pages just to change the content of the current page.

With PHP alone you cannot load new content without reloading the entire page, or involving one of the other methods listed below.

I would say that you have two avenues to get this done.

The first using a meld of AJAX & PHP
http://nodstrum.com/2007/02/27/ajaxcontentload/
http://www.dhtmlgoodies.com/scripts/ajax-dynamic-articles/ajax-dynamic-articles.html
http://www.dhtmlgoodies.com/scripts/ajax-dynamic-content/ajax-dynamic-content.html

The second is with Javascript and/or CSS
http://www.devarticles.com/c/a/HTML/Preloading-HTML-Content-with-CSS/
http://www.dynamicdrive.com/dynamicindex17/switchcontent.htm

Hope these help.

--
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


[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