parameter passing issue on function


Posted on 16th Feb 2014 07:03 pm by admin

Well I thought I had created a pretty slick web page, using ?page and $_GET to load pages which where really function calls.


Here is a few lines that make up the menu
Did you know?Explore Trending and Topic pages for more stories like this.
Code: [Select]<li><a Href="?page=welcome_page">Home</a></li>
<li><a Href="?page=laninfo_display">Party Info</a></li>

This function loads other functions into the main body of the web page.
Code: [Select]function main_page(){
if ( $_GET['page'] == null ) {
$menu_link = welcome_page;
$menu_link();
}else{
$menu_link = $_GET['page'];
$menu_link();
}
}

All was good till recently I needed to start passing parameters back and forth between some functions. What would be the best way to solve this issue?
No comments posted yet

Your Answer:

Login to answer
66 Like 39 Dislike
Previous forums Next forums
Other forums

PDO returns erroneous columns from within pdt
Hi All,

This is a truly weird behavior:
When using a simple pdo fetch, erroneous columns a

how to easy edit text, with box? Help.
Hi.
I have a little problem. I'm doing a webpage for my aunt and I would like to make it as easy

value not going in data base
hello friends....
i am having a working javascript....when i am selecting any

php automatically escaping single quotes
I'm trying to test out my security a bit and I've noticed that php is escaping my single quotes. For

urldecode question
How would I format this line of code properly?

<?php echo urldecode($_GET['Title']); ?

ScriptManager History and Opera Issue
I am having an issue in opera with the ScriptManager. I have a ScriptManager on a page with history

switch form actions? not working
i want on submit to go to different pages according to the CatID

Code: <?php $CatID=$_

how do i make new line after *
First check this page here. and you see my report. Im pulling form a mysql db. I want to beable to m

frames get header location..
i have two frames, one top, one bottom. how do i do a form on the bottom frame that gives me the ur

Multidimensional Array into an Html table, help!
Hello all, I am new to HTML/PHP so any help would be great.

I have a multidimensional array f

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash