Jump to content

How to code framework?

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
3 replies to this topic

#1
Hamed

Hamed

    Programming Professional

  • Members
  • PipPipPipPipPip
  • 276 posts
I am working on script by the name WoltLab Burning Board (WoltLab® - Your experienced partner in building up communities!)
I want to code script which do like that (I need to use php 5 OOP)
If we check ASP.NET when we open new page (in visual studio) when have onload page or for any click we can have one function in our class.
now I want to do sth which do sth like that.
E.g:

<?php

class hamed
{
    onload_page()
    {
        echo "hamed";
    }
    
    onclick_submit_one()
    {
        $db->query("Insert");
    }
    
    onclick_submit_two()
    {
        echo "you click on submit two";
    }
}

?>
I see that woltlab do sth like that but it is hard to understand and also it is paid can anyone help me to make one?

#2
Orjan

Orjan

    Writes binary right handed and hex left handed

  • Moderators
  • 3,299 posts
the onload is only for javascript connected to the html, as they are executed after the page is loaded from the source, that can be pure html, php or almost any other language...
__________________________________________
I study Information Systems at Karlstad University when I'm not on CodeCall

#3
Hamed

Hamed

    Programming Professional

  • Members
  • PipPipPipPipPip
  • 276 posts
I think you don't understand what I want.
when you load one page you might have some query and more then these are onload page.

Orjan said:

the onload is only for javascript connected to the html, as they are executed after the page is loaded from the source, that can be pure html, php or almost any other language...

Edited by Hamed, 21 September 2010 - 04:12 AM.


#4
bbqroast

bbqroast

    Codecall Addict

  • Members
  • PipPipPipPipPipPipPip
  • 554 posts
Looks like a job for java script- if you need to use it with PHP use AJAX google about it. I'm going to watch a program about google on TV so can't do it my self.
LOL just relized the irony of what i said :D
Please, write clearly with proper structure. Double spacing makes the text feel un-jointed, Capitalizing Every Word Means People Stop Before Every Word Sub-Consciously Which Is A Pain In The Backside, and use code tags! (The right most styling box).