[phpwebapp-commits] CVS: app1 styles.css,1.2,1.3 page3.html,1.3,1.4 page2.html,1.3,1.4 page1.html,1.
Brought to you by:
dashohoxha
|
From: Dashamir H. <das...@us...> - 2003-08-26 16:40:22
|
Update of /cvsroot/phpwebapp/app1
In directory sc8-pr-cvs1:/tmp/cvs-serv22326
Modified Files:
styles.css page3.html page2.html page1.html index.php
external_page.html
Log Message:
converted CRLF to LF
Index: styles.css
===================================================================
RCS file: /cvsroot/phpwebapp/app1/styles.css,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** styles.css 15 Aug 2003 08:15:53 -0000 1.2
--- styles.css 25 Aug 2003 14:07:01 -0000 1.3
***************
*** 1,23 ****
! body
! {
! background-color: #efe7d6;
! margin-top: 20px;
! margin-left: 20px;
! margin-right: 20px;
! margin-bottom: 20px;
! font-family: arial, helvetica, sans-se;
! font-size: 12pt;
! color: #000000;
! }
!
! h1, h2
! {
! text-align: center;
! }
!
! strong
! {
! color: #000066;
! font-size: 14px;
! font-weight: bold
! }
--- 1,23 ----
! body
! {
! background-color: #efe7d6;
! margin-top: 20px;
! margin-left: 20px;
! margin-right: 20px;
! margin-bottom: 20px;
! font-family: arial, helvetica, sans-se;
! font-size: 12pt;
! color: #000000;
! }
!
! h1, h2
! {
! text-align: center;
! }
!
! strong
! {
! color: #000066;
! font-size: 14px;
! font-weight: bold
! }
Index: page3.html
===================================================================
RCS file: /cvsroot/phpwebapp/app1/page3.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** page3.html 15 Aug 2003 08:15:53 -0000 1.3
--- page3.html 25 Aug 2003 14:07:01 -0000 1.4
***************
*** 1,27 ****
! <html>
! <head>
! <title>Page 3</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! </head>
!
! <body>
! <h2>Page 3 of the application</h2>
!
! <h3>Debugging Transitions</h3>
!
! <p>If you open in an editor the file
! <em>config/const.Debug.php</em> you will see there a constant
! named <em>DEBUG_GOTO</em>. Make it <em>true</em> and notice that
! each time that you make a transition you get an alert about
! it.</p>
!
! <p>Go To
! [ <a href="javascript:GoTo('page1.html')">Page 1</a>
! | <a href="javascript:GoTo('page2.html')">Page 2</a>
! | Page 3
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
--- 1,27 ----
! <html>
! <head>
! <title>Page 3</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! </head>
!
! <body>
! <h2>Page 3 of the application</h2>
!
! <h3>Debugging Transitions</h3>
!
! <p>If you open in an editor the file
! <em>config/const.Debug.php</em> you will see there a constant
! named <em>DEBUG_GOTO</em>. Make it <em>true</em> and notice that
! each time that you make a transition you get an alert about
! it.</p>
!
! <p>Go To
! [ <a href="javascript:GoTo('page1.html')">Page 1</a>
! | <a href="javascript:GoTo('page2.html')">Page 2</a>
! | Page 3
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
Index: page2.html
===================================================================
RCS file: /cvsroot/phpwebapp/app1/page2.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** page2.html 15 Aug 2003 08:15:53 -0000 1.3
--- page2.html 25 Aug 2003 14:07:01 -0000 1.4
***************
*** 1,32 ****
! <html>
! <head>
! <title>Page 2</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! </head>
!
! <body>
! <h2>Page 2 of the application</h2>
!
! <h3>External Pages</h3>
!
! <p>The external pages are HTML pages that are outside the
! application. They are linked as usually in HTML, without using
! transitions and the function <strong>GoTo()</strong>. See the
! examples below and click the link to the <em>external
! page</em>.</p>
!
! <ul>
! <li><a href="http://www.yahoo.com/">Yahoo!</a></li>
! <li><a href="external_page.html">external page</a></li>
! </ul>
!
! <p>Go To
! [ <a href="javascript:GoTo('page1.html')">Page 1</a>
! | Page 2
! | <a href="javascript:GoTo('page3.html')">Page 3</a>
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
--- 1,32 ----
! <html>
! <head>
! <title>Page 2</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! </head>
!
! <body>
! <h2>Page 2 of the application</h2>
!
! <h3>External Pages</h3>
!
! <p>The external pages are HTML pages that are outside the
! application. They are linked as usually in HTML, without using
! transitions and the function <strong>GoTo()</strong>. See the
! examples below and click the link to the <em>external
! page</em>.</p>
!
! <ul>
! <li><a href="http://www.yahoo.com/">Yahoo!</a></li>
! <li><a href="external_page.html">external page</a></li>
! </ul>
!
! <p>Go To
! [ <a href="javascript:GoTo('page1.html')">Page 1</a>
! | Page 2
! | <a href="javascript:GoTo('page3.html')">Page 3</a>
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
Index: page1.html
===================================================================
RCS file: /cvsroot/phpwebapp/app1/page1.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** page1.html 15 Aug 2003 08:15:53 -0000 1.3
--- page1.html 25 Aug 2003 14:07:01 -0000 1.4
***************
*** 1,60 ****
! <html>
! <head>
! <title>Page 1</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! <script language="javascript" type="text/javascript">
! function on_test()
! {
! var msg;
! msg = "Function on_test() is called.\n"
! + "Here we can do input data validations etc.\n"
! + "Finally, if everything is OK, we call\n"
! + "GoTo('page1.html') to make the transition.\n";
! alert(msg);
! GoTo('page1.html');
! }
! </script>
! </head>
!
! <body>
! <h2>Page 1 of the application</h2>
!
! <h3>A phpWebApp Application is Like a State Machine</h3>
!
! <p>The <strong>phpWebApp</strong> thinks of a web application as
! a state machine, where each state is a web page. Each time the browser
! loads something new in its window, you see a snapshot of the application
! in a certain state. For example, this sample application can be
! described by the following state diagram:</p>
!
! <div align="center">
! <img src="img/state_diagram.png"
! alt="A state diagram that represents three pages of the application as three states">
! </div>
!
! <h3>Transitions by GoTo()</h3>
!
! <p>Transitions from one page of the application to another are
! done by using the javascript function
! <strong>GoTo('page.html')</strong>. This function is declared by
! the framework itself and is included automatically at the end of
! each page of the application. Make a 'View Source' now and see
! that there is some code appended to the page by the
! framework.</p>
!
! <p>In real applications, usually <em>GoTo()</em> is called from
! inside a <em>JavaScript</em> function, after making some input
! data validations etc. E.g. try this link:
! <a href="javascript:on_test()">test</a> wich calls the
! <em>JavaScript</em> function <em>on_test()</em>.</p>
!
! <p>Go To
! [ Page 1
! | <a href="javascript:GoTo('page2.html')">Page 2</a>
! | <a href="javascript:GoTo('page3.html')">Page 3</a>
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
--- 1,60 ----
! <html>
! <head>
! <title>Page 1</title>
! <link rel="stylesheet" type="text/css" href="styles.css">
! <script language="javascript" type="text/javascript">
! function on_test()
! {
! var msg;
! msg = "Function on_test() is called.\n"
! + "Here we can do input data validations etc.\n"
! + "Finally, if everything is OK, we call\n"
! + "GoTo('page1.html') to make the transition.\n";
! alert(msg);
! GoTo('page1.html');
! }
! </script>
! </head>
!
! <body>
! <h2>Page 1 of the application</h2>
!
! <h3>A phpWebApp Application is Like a State Machine</h3>
!
! <p>The <strong>phpWebApp</strong> thinks of a web application as
! a state machine, where each state is a web page. Each time the browser
! loads something new in its window, you see a snapshot of the application
! in a certain state. For example, this sample application can be
! described by the following state diagram:</p>
!
! <div align="center">
! <img src="img/state_diagram.png"
! alt="A state diagram that represents three pages of the application as three states">
! </div>
!
! <h3>Transitions by GoTo()</h3>
!
! <p>Transitions from one page of the application to another are
! done by using the javascript function
! <strong>GoTo('page.html')</strong>. This function is declared by
! the framework itself and is included automatically at the end of
! each page of the application. Make a 'View Source' now and see
! that there is some code appended to the page by the
! framework.</p>
!
! <p>In real applications, usually <em>GoTo()</em> is called from
! inside a <em>JavaScript</em> function, after making some input
! data validations etc. E.g. try this link:
! <a href="javascript:on_test()">test</a> wich calls the
! <em>JavaScript</em> function <em>on_test()</em>.</p>
!
! <p>Go To
! [ Page 1
! | <a href="javascript:GoTo('page2.html')">Page 2</a>
! | <a href="javascript:GoTo('page3.html')">Page 3</a>
! ]</p>
!
! <a href="javascript:history.back()"><img src="img/back.png" alt="Back" border="0"></a>
! <a href="{{APP_URL}}"><img src="img/home.png" alt="Home" border="0"></a>
! </body>
! </html>
Index: index.php
===================================================================
RCS file: /cvsroot/phpwebapp/app1/index.php,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** index.php 25 Aug 2003 13:41:13 -0000 1.2
--- index.php 25 Aug 2003 14:07:01 -0000 1.3
***************
*** 1,28 ****
! <?php
! /*
! Copyright 2001,2002,2003 Dashamir Hoxha, das...@us...
!
! This file is part of phpWebApp.
!
! phpWebApp is free software; you can redistribute it and/or modify
! it under the terms of the GNU General Public License as published by
! the Free Software Foundation; either version 2 of the License, or
! (at your option) any later version.
!
! phpWebApp is distributed in the hope that it will be useful,
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with phpWebApp; if not, write to the Free Software
! Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
! */
!
!
! include_once "webapp.php";
!
! //construct the target page of the transition
! $tpl_page = TPL_PATH.$event->targetPage;
! WebApp::constructHtmlPage($tpl_page);
?>
--- 1,28 ----
! <?php
! /*
! Copyright 2001,2002,2003 Dashamir Hoxha, das...@us...
!
! This file is part of phpWebApp.
!
! phpWebApp is free software; you can redistribute it and/or modify
! it under the terms of the GNU General Public License as published by
! the Free Software Foundation; either version 2 of the License, or
! (at your option) any later version.
!
! phpWebApp is distributed in the hope that it will be useful,
! but WITHOUT ANY WARRANTY; without even the implied warranty of
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
! GNU General Public License for more details.
!
! You should have received a copy of the GNU General Public License
! along with phpWebApp; if not, write to the Free Software
! Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
! */
!
!
! include_once "webapp.php";
!
! //construct the target page of the transition
! $tpl_page = TPL_PATH.$event->targetPage;
! WebApp::constructHtmlPage($tpl_page);
?>
Index: external_page.html
===================================================================
RCS file: /cvsroot/phpwebapp/app1/external_page.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** external_page.html 15 Aug 2003 08:15:53 -0000 1.3
--- external_page.html 25 Aug 2003 14:07:01 -0000 1.4
***************
*** 1,33 ****
! <html>
! <head>
! <title>External Page</title>
! </head>
!
! <body>
! <h3>External Page</h3>
!
! <p>This page is not a part of the application
! <strong>app1</strong>, it is a simple HTML page, or the page of
! another application.</p>
!
! <p>Here you cannot use the function <strong>GoTo()</strong>
! because it is undefined, e.g. if you try this link: <a href=
! "javascript:GoTo('page1.html')">GoTo('page1.html')</a> you
! will get a javascript error.</p>
!
! <p>You can go to the page of the application from which you came
! here only by pressing the button <strong>back</strong> in the
! browser. If you try to link to it like this: <a href=
! "page2.html">page2.html</a> , it will not work, because the page
! will be openned in the browser as a simple html page (like this one)
! not as a page of the application <strong>app1</strong>. Try to click it
! and see that the transitions in 'page2.html' will not work.
! View the source of <a href="page2.html">page2.html</a> and notice
! that additional code added by the framework is missing (the logo
! is missing too).</p>
!
! <a href="javascript:history.back()">
! <img src="img/back.png" alt="Back" border="0">
! </a>
! </body>
! </html>
--- 1,33 ----
! <html>
! <head>
! <title>External Page</title>
! </head>
!
! <body>
! <h3>External Page</h3>
!
! <p>This page is not a part of the application
! <strong>app1</strong>, it is a simple HTML page, or the page of
! another application.</p>
!
! <p>Here you cannot use the function <strong>GoTo()</strong>
! because it is undefined, e.g. if you try this link: <a href=
! "javascript:GoTo('page1.html')">GoTo('page1.html')</a> you
! will get a javascript error.</p>
!
! <p>You can go to the page of the application from which you came
! here only by pressing the button <strong>back</strong> in the
! browser. If you try to link to it like this: <a href=
! "page2.html">page2.html</a> , it will not work, because the page
! will be openned in the browser as a simple html page (like this one)
! not as a page of the application <strong>app1</strong>. Try to click it
! and see that the transitions in 'page2.html' will not work.
! View the source of <a href="page2.html">page2.html</a> and notice
! that additional code added by the framework is missing (the logo
! is missing too).</p>
!
! <a href="javascript:history.back()">
! <img src="img/back.png" alt="Back" border="0">
! </a>
! </body>
! </html>
|