TinyPortal

Development => Feedback => Topic started by: osquitar on February 08, 2006, 10:42:02 PM

Title: php block
Post by: osquitar on February 08, 2006, 10:42:02 PM
I don't know if this is the right place to talk about php... Anyway I go...

Think about the button generator which is in the left side of this site. When you click on "render" something happens. I think the php code in the block run again with the parameters choosen by the user. I need to do the same thing but I don't know how. I see the page does not load again but just the block. Mr. Bloc, please!!! you are the author. Tell me how can I do it!

Title: Re: php block
Post by: eldacar on February 09, 2006, 12:56:14 AM
The button generator is in an iframe.
Title: Re: php block
Post by: osquitar on February 09, 2006, 01:00:32 AM
Anyway, Is possible reload a php block with new parameters (variables)?
Title: Re: php block
Post by: IchBin on February 09, 2006, 02:00:18 AM
I'm no php guru, but PHP by nature is dynamic. You can tell it to do many things. Even differently each time. I don't know how, but I know it's possible.
Title: Re: php block
Post by: osquitar on February 09, 2006, 02:15:03 AM
Yes, I had to use a php article, not a php block. Besides you must declare the variable to pass as global. That's all. I spent all day in this topic.

for example:

http://www.domain_name.com/index.php?page=2&optionMenu=3

In the article:

global $optionMenu;



I hope this will be useful for someone.