Dharma Mulya
|
| Posted: 03/22/2002, 4:13 AM |
|
I have been using CC for sometime and this newsgroup really helps.
My problem now is...trying to go another level in using CC.
All this time my knowledge on CC is more like cut and paste solution and
reversing the solution and adjusting it to my needs...(most of the time
without full understanding). Now I want to do things which might not be
shown in any of the samples.
What is the fastest way to create and understand all coding that need to be
used in the ... open event, before event, global etc...? (Most of the coding
needs adjustments...so it is difficult to adjust without understanding it..
I think....or is there any better way?)
If yes, is there a tutorial or manual in CC or I should have this knowledge
in programming language (eg. PHP JSP....) prior to using CC?
If I should have any prior knowledge, what it is recommended and where to
get it?
Most of the time I am using CC to output in PHP with MySQL on Linux server.
TQ all
Dharma
|
|
|
 |
kris
|
| Posted: 03/22/2002, 12:13 PM |
|
This is a very timely posting, and I believe many CC users should benefit from
it coming from the experts at CodeCharge.
Dharma Mulya wrote:
> I have been using CC for sometime and this newsgroup really helps.
> My problem now is...trying to go another level in using CC.
>
> All this time my knowledge on CC is more like cut and paste solution and
> reversing the solution and adjusting it to my needs...(most of the time
> without full understanding). Now I want to do things which might not be
> shown in any of the samples.
>
> What is the fastest way to create and understand all coding that need to be
> used in the ... open event, before event, global etc...? (Most of the coding
> needs adjustments...so it is difficult to adjust without understanding it..
> I think....or is there any better way?)
>
> If yes, is there a tutorial or manual in CC or I should have this knowledge
> in programming language (eg. PHP JSP....) prior to using CC?
>
> If I should have any prior knowledge, what it is recommended and where to
> get it?
>
> Most of the time I am using CC to output in PHP with MySQL on Linux server.
>
> TQ all
> Dharma
|
|
|
 |
Geert Larsen
|
| Posted: 03/22/2002, 1:43 PM |
|
I would like to add that it´s relevant for i.e. ASP developers as well 
/ geert
"kris" <ksingh@lsuhsc.edu> wrote in message
news:3C9B8E9E.2F96B931@lsuhsc.edu...
> This is a very timely posting, and I believe many CC users should benefit
from
> it coming from the experts at CodeCharge.
>
>
> Dharma Mulya wrote:
>
> > I have been using CC for sometime and this newsgroup really helps.
> > My problem now is...trying to go another level in using CC.
> >
> > All this time my knowledge on CC is more like cut and paste solution and
> > reversing the solution and adjusting it to my needs...(most of the time
> > without full understanding). Now I want to do things which might not be
> > shown in any of the samples.
> >
> > What is the fastest way to create and understand all coding that need to
be
> > used in the ... open event, before event, global etc...? (Most of the
coding
> > needs adjustments...so it is difficult to adjust without understanding
it..
> > I think....or is there any better way?)
> >
> > If yes, is there a tutorial or manual in CC or I should have this
knowledge
> > in programming language (eg. PHP JSP....) prior to using CC?
> >
> > If I should have any prior knowledge, what it is recommended and where
to
> > get it?
> >
> > Most of the time I am using CC to output in PHP with MySQL on Linux
server.
> >
> > TQ all
> > Dharma
>
|
|
|
 |
RonB
|
| Posted: 03/23/2002, 3:56 AM |
|
"Dharma Mulya" <supreme@mol.net.my> schreef in bericht
news:a7f75b$5bn$1@news.codecharge.com...
> I have been using CC for sometime and this newsgroup really helps.
> My problem now is...trying to go another level in using CC.
>
> All this time my knowledge on CC is more like cut and paste solution and
> reversing the solution and adjusting it to my needs...(most of the time
> without full understanding). Now I want to do things which might not be
> shown in any of the samples.
>
> What is the fastest way to create and understand all coding that need to
be
> used in the ... open event, before event, global etc...? (Most of the
coding
> needs adjustments...so it is difficult to adjust without understanding
it..
> I think....or is there any better way?)
>
> If yes, is there a tutorial or manual in CC or I should have this
knowledge
> in programming language (eg. PHP JSP....) prior to using CC?
>
> If I should have any prior knowledge, what it is recommended and where to
> get it?
>
> Most of the time I am using CC to output in PHP with MySQL on Linux
server.
>
> TQ all
> Dharma
>
>
I think some knowledge of your preferred prgramming language is welcome. I
was in the same position as you are. I wanted more then just the standard
features. I wanted email for user notification, after insert updates to
other tables etc etc. I already had knowledge of sql so the problem was
getting it to work with, in my case, PHP.
I got a book and started reading, I looked at the code codecharge generates
and tried to understand what happens. My options improved because I can try
and program my own code for features that codecharge doesn't have. Learning
to code isn't meant as a replacement for codecharge, it will show you the
real potential of the program. I use codecharge to build and maintain the
company intranet that runs on MySql and oracle 8i. Most of the code is
generated by codecharge as is and I do some edditing with Dreamweaver for
the html templates. The extra's I code myself(with ocasional help from the
great people at codecharge and the enormous PHP community that's out there)
It's been a great experience!
RonB
|
|
|
 |
Glenn Holden
|
| Posted: 03/26/2002, 7:55 PM |
|
I agree with RonB. It sounds like you need to become a little more familiar
with programming in PHP. PHP.net and PHP.org are two great web sites with
searchable online docs, newsgroups, and lots of downloadable stuff. Since
I've started PHP, not so long ago, I've been a regular visitor there and
here.
For where to put the PHP code in Code Charge, CC's online help has detailed
event flow like this:
......
BeforeCancel ? Validation ? BeforeInsert ? BeforeUpdate ? BeforeDelete ?
BeforeExecute ? AfterInsert ? AfterUpdate ? AfterDelete ? Open ?
BeforeShowUpdate ? BeforeShowInsert ? BeforeShow ? Close
Open Executed before the form is processed.
Close Executed after the form is processed.
......
If you are still stuck you will have to post some more specifics.
Glenn
"RonB" <r.borkent@123chello.nl> wrote in message
news:a7hqh5$14d$1@news.codecharge.com...
>
> "Dharma Mulya" <supreme@mol.net.my> schreef in bericht
>news:a7f75b$5bn$1@news.codecharge.com...
> > I have been using CC for sometime and this newsgroup really helps.
> > My problem now is...trying to go another level in using CC.
> >
> > All this time my knowledge on CC is more like cut and paste solution and
> > reversing the solution and adjusting it to my needs...(most of the time
> > without full understanding). Now I want to do things which might not be
> > shown in any of the samples.
> >
> > What is the fastest way to create and understand all coding that need to
> be
> > used in the ... open event, before event, global etc...? (Most of the
> coding
> > needs adjustments...so it is difficult to adjust without understanding
> it..
> > I think....or is there any better way?)
> >
> > If yes, is there a tutorial or manual in CC or I should have this
> knowledge
> > in programming language (eg. PHP JSP....) prior to using CC?
> >
> > If I should have any prior knowledge, what it is recommended and where
to
> > get it?
> >
> > Most of the time I am using CC to output in PHP with MySQL on Linux
> server.
> >
> > TQ all
> > Dharma
> >
> >
>
> I think some knowledge of your preferred prgramming language is welcome. I
> was in the same position as you are. I wanted more then just the standard
> features. I wanted email for user notification, after insert updates to
> other tables etc etc. I already had knowledge of sql so the problem was
> getting it to work with, in my case, PHP.
> I got a book and started reading, I looked at the code codecharge
generates
> and tried to understand what happens. My options improved because I can
try
> and program my own code for features that codecharge doesn't have.
Learning
> to code isn't meant as a replacement for codecharge, it will show you the
> real potential of the program. I use codecharge to build and maintain the
> company intranet that runs on MySql and oracle 8i. Most of the code is
> generated by codecharge as is and I do some edditing with Dreamweaver for
> the html templates. The extra's I code myself(with ocasional help from the
> great people at codecharge and the enormous PHP community that's out
there)
> It's been a great experience!
>
> RonB
>
>
|
|
|
 |
Dharma Mulya
|
| Posted: 03/27/2002, 9:58 AM |
|
So what you are saying is that for me to go and learn PHP prior to using CC.
Point taken. And that will take me to this next question.
Is there any note or rule as to what extend CC will do the coding for you
and at what point should you jump in and put your knowledge of PHP to as
you've mentioned? Can you explain to me please?
TQ again.
BeforeCancel ? Validation ? BeforeInsert ? BeforeUpdate ? BeforeDelete ?
BeforeExecute ? AfterInsert ? AfterUpdate ? AfterDelete ? Open ?
BeforeShowUpdate ? BeforeShowInsert ? BeforeShow ? Close
Open Executed before the form is processed.
Close Executed after the form is processed.
Glenn Holden <glenn@nilenet.com> wrote in message
news:a7rfre$3bb$1@news.codecharge.com...
> I agree with RonB. It sounds like you need to become a little more
familiar
> with programming in PHP. PHP.net and PHP.org are two great web sites with
> searchable online docs, newsgroups, and lots of downloadable stuff. Since
> I've started PHP, not so long ago, I've been a regular visitor there and
> here.
>
> For where to put the PHP code in Code Charge, CC's online help has
detailed
> event flow like this:
>
> .....
> BeforeCancel ? Validation ? BeforeInsert ? BeforeUpdate ? BeforeDelete ?
> BeforeExecute ? AfterInsert ? AfterUpdate ? AfterDelete ? Open ?
> BeforeShowUpdate ? BeforeShowInsert ? BeforeShow ? Close
>
> Open Executed before the form is processed.
> Close Executed after the form is processed.
> .....
>
>
> If you are still stuck you will have to post some more specifics.
> Glenn
>
>
>
> "RonB" <r.borkent@123chello.nl> wrote in message
>news:a7hqh5$14d$1@news.codecharge.com...
> >
> > "Dharma Mulya" <supreme@mol.net.my> schreef in bericht
> >news:a7f75b$5bn$1@news.codecharge.com...
> > > I have been using CC for sometime and this newsgroup really helps.
> > > My problem now is...trying to go another level in using CC.
> > >
> > > All this time my knowledge on CC is more like cut and paste solution
and
> > > reversing the solution and adjusting it to my needs...(most of the
time
> > > without full understanding). Now I want to do things which might not
be
> > > shown in any of the samples.
> > >
> > > What is the fastest way to create and understand all coding that need
to
> > be
> > > used in the ... open event, before event, global etc...? (Most of the
> > coding
> > > needs adjustments...so it is difficult to adjust without understanding
> > it..
> > > I think....or is there any better way?)
> > >
> > > If yes, is there a tutorial or manual in CC or I should have this
> > knowledge
> > > in programming language (eg. PHP JSP....) prior to using CC?
> > >
> > > If I should have any prior knowledge, what it is recommended and where
> to
> > > get it?
> > >
> > > Most of the time I am using CC to output in PHP with MySQL on Linux
> > server.
> > >
> > > TQ all
> > > Dharma
> > >
> > >
> >
> > I think some knowledge of your preferred prgramming language is welcome.
I
> > was in the same position as you are. I wanted more then just the
standard
> > features. I wanted email for user notification, after insert updates to
> > other tables etc etc. I already had knowledge of sql so the problem was
> > getting it to work with, in my case, PHP.
> > I got a book and started reading, I looked at the code codecharge
> generates
> > and tried to understand what happens. My options improved because I can
> try
> > and program my own code for features that codecharge doesn't have.
> Learning
> > to code isn't meant as a replacement for codecharge, it will show you
the
> > real potential of the program. I use codecharge to build and maintain
the
> > company intranet that runs on MySql and oracle 8i. Most of the code is
> > generated by codecharge as is and I do some edditing with Dreamweaver
for
> > the html templates. The extra's I code myself(with ocasional help from
the
> > great people at codecharge and the enormous PHP community that's out
> there)
> > It's been a great experience!
> >
> > RonB
> >
> >
>
>
|
|
|
 |
Glenn Holden
|
| Posted: 03/30/2002, 12:15 PM |
|
Dharma,
I do think you should start with Code Charge. That will take you to a
point. A good point, Code Charge is fairly robust. And you will need to
understand code charge to the extent that you know it's features and
limitations so you do know when you have to go to Php for the solution.
I start by looking for a CC solution to my interface. Refine it and refine
it to the point where it does everything CC can do for you. That usually
includes all my input and some output style forms, along with basic field
validation, page security and some navigation. CC builds the shell of your
site, pages, and forms. It handles database connections and provides you an
object interface ($db->) to work with it, just as you'd probably do if you
built it from scratch.
For anything beyond that I go to Php. I'm like you, in that I often start
with someone else's code and cut, paste and modify. Nothing wrong with
that. To understand better what it's doing, take a snippet here and there
and research it's keywords in the code charge and Php manuals. Do it as you
need to, not everything at once. It's much easier to learn and remember
that way.
Also, Sometimes I use an external Php editor (find a free one on the net)
when debugging because Php errors refer to a line number which is absent in
Code Charge. You have to open the php document that CC generates in the
external editor to pinpoint the problem. (If I'm missing something here you
guys, please let me know!)
When you are stuck, ask here and in the php groups.
If you have more questions about events, their sequence and what to put in
them, be sure to read up on events in CC help. For example of how to use
them, you have to go to the samples.
Ciao,
Glenn
"Dharma Mulya" <supreme@mol.net.my> wrote in message
news:a7t18a$2f3$1@news.codecharge.com...
> So what you are saying is that for me to go and learn PHP prior to using
CC.
> Point taken. And that will take me to this next question.
>
> Is there any note or rule as to what extend CC will do the coding for you
> and at what point should you jump in and put your knowledge of PHP to as
> you've mentioned? Can you explain to me please?
>
> TQ again.
>
> BeforeCancel ? Validation ? BeforeInsert ? BeforeUpdate ? BeforeDelete ?
> BeforeExecute ? AfterInsert ? AfterUpdate ? AfterDelete ? Open ?
> BeforeShowUpdate ? BeforeShowInsert ? BeforeShow ? Close
>
> Open Executed before the form is processed.
> Close Executed after the form is processed.
>
>
>
> Glenn Holden <glenn@nilenet.com> wrote in message
>news:a7rfre$3bb$1@news.codecharge.com...
> > I agree with RonB. It sounds like you need to become a little more
> familiar
> > with programming in PHP. PHP.net and PHP.org are two great web sites
with
> > searchable online docs, newsgroups, and lots of downloadable stuff.
Since
> > I've started PHP, not so long ago, I've been a regular visitor there and
> > here.
> >
> > For where to put the PHP code in Code Charge, CC's online help has
> detailed
> > event flow like this:
> >
> > .....
> > BeforeCancel ? Validation ? BeforeInsert ? BeforeUpdate ? BeforeDelete ?
> > BeforeExecute ? AfterInsert ? AfterUpdate ? AfterDelete ? Open ?
> > BeforeShowUpdate ? BeforeShowInsert ? BeforeShow ? Close
> >
> > Open Executed before the form is processed.
> > Close Executed after the form is processed.
> > .....
> >
> >
> > If you are still stuck you will have to post some more specifics.
> > Glenn
> >
> >
> >
> > "RonB" <r.borkent@123chello.nl> wrote in message
> >news:a7hqh5$14d$1@news.codecharge.com...
> > >
> > > "Dharma Mulya" <supreme@mol.net.my> schreef in bericht
> > >news:a7f75b$5bn$1@news.codecharge.com...
> > > > I have been using CC for sometime and this newsgroup really helps.
> > > > My problem now is...trying to go another level in using CC.
> > > >
> > > > All this time my knowledge on CC is more like cut and paste solution
> and
> > > > reversing the solution and adjusting it to my needs...(most of the
> time
> > > > without full understanding). Now I want to do things which might not
> be
> > > > shown in any of the samples.
> > > >
> > > > What is the fastest way to create and understand all coding that
need
> to
> > > be
> > > > used in the ... open event, before event, global etc...? (Most of
the
> > > coding
> > > > needs adjustments...so it is difficult to adjust without
understanding
> > > it..
> > > > I think....or is there any better way?)
> > > >
> > > > If yes, is there a tutorial or manual in CC or I should have this
> > > knowledge
> > > > in programming language (eg. PHP JSP....) prior to using CC?
> > > >
> > > > If I should have any prior knowledge, what it is recommended and
where
> > to
> > > > get it?
> > > >
> > > > Most of the time I am using CC to output in PHP with MySQL on Linux
> > > server.
> > > >
> > > > TQ all
> > > > Dharma
> > > >
> > > >
> > >
> > > I think some knowledge of your preferred prgramming language is
welcome.
> I
> > > was in the same position as you are. I wanted more then just the
> standard
> > > features. I wanted email for user notification, after insert updates
to
> > > other tables etc etc. I already had knowledge of sql so the problem
was
> > > getting it to work with, in my case, PHP.
> > > I got a book and started reading, I looked at the code codecharge
> > generates
> > > and tried to understand what happens. My options improved because I
can
> > try
> > > and program my own code for features that codecharge doesn't have.
> > Learning
> > > to code isn't meant as a replacement for codecharge, it will show you
> the
> > > real potential of the program. I use codecharge to build and maintain
> the
> > > company intranet that runs on MySql and oracle 8i. Most of the code is
> > > generated by codecharge as is and I do some edditing with Dreamweaver
> for
> > > the html templates. The extra's I code myself(with ocasional help from
> the
> > > great people at codecharge and the enormous PHP community that's out
> > there)
> > > It's been a great experience!
> > >
> > > RonB
> > >
> > >
> >
> >
>
>
|
|
|
 |
RonB
|
| Posted: 03/30/2002, 1:17 PM |
|
On Wed, 27 Mar 2002 18:39:57 +0100, Dharma Mulya wrote:
> So what you are saying is that for me to go and learn PHP prior to using
> CC. Point taken. And that will take me to this next question.
>
> Is there any note or rule as to what extend CC will do the coding for
> you and at what point should you jump in and put your knowledge of PHP
> to as you've mentioned? Can you explain to me please?
>
> TQ again.
>
> BeforeCancel ?
Code parsed before cancel action is done ( you might for no reason at all
want to count the times someone cancels and put this data into a table in your
database.
> Validation ?
Check if the user input is according to rules. ie date is filled in correct
format before sending the form or some variable that has to be filled
isnt null
>BeforeInsert ?
Simple: some action done before the insert statement is send to the
database. If you do inserts to more then one table you could use this
event to get the Mysql insert id for that table.
I use this event for email notification and mostly for date reformatting
european dates to MySql format.I wrote a function for that so the code
would look like:
$flddatefield=dbdate($flddatefield);
>BeforeUpdate ?
Same as in the before insert. Before you do the update some information
could be inserted in some other table ie a log of some kind.
> BeforeDelete ?
Same as above
> BeforeExecute ?
Same as above
>AfterInsert ? >
same as above
>AfterUpdate ? AfterDelete ?
same as above
> BeforeShowUpdate ?
Havnet used this one yet
> BeforeShowInsert ?
Havent used this one yet
>BeforeShow ?
This is the one I use the most because it allows me to do all kinds of
stuff before the page is displayed.
For example: In my company ( a drug addiction treatment center) the are
workers that do groupTherapy sessions. These are always done by two
Therapists. In one of the management tools I'm buiding managers want to
see how many contacts each worker has over a period of a month. So before
the page is displayed I divide the number of contacts by 2. So each
worker get half of the count for that group. ($fieldX=$fldX /2;)
Also Mysql saves dates in YYYY-MM-DD format but in europe whe use
DD-MM-YYYY. All fields containing dates have to be reformatted. This is
done in the beforeshow events with a function I wrote
(showdbdate($flddatefield);
showdbdate is only the name of the function not the function itself
ofcourse.
For form input you can automatically display cuurent date for your date
field. In beforeshow event you put the code:
$date=date('d-m-Y');
$flddatefield=$date;
Since the user is putting dates in european format in the forms these
have to be reformatted in the beforeinsert or before update events so
MySql knows what to do with them
Hope this helps a bit.
RonB
|
|
|
 |
Dharma Mulya
|
| Posted: 04/03/2002, 8:37 AM |
|
TQ both of you and if I am stuck can I refer to you again? I will start my
new level now.
RonB <r.borkent@chello123.nl> wrote in message
news:a85a0r$8re$1@news.codecharge.com...
> On Wed, 27 Mar 2002 18:39:57 +0100, Dharma Mulya wrote:
>
> > So what you are saying is that for me to go and learn PHP prior to using
> > CC. Point taken. And that will take me to this next question.
> >
> > Is there any note or rule as to what extend CC will do the coding for
> > you and at what point should you jump in and put your knowledge of PHP
> > to as you've mentioned? Can you explain to me please?
> >
> > TQ again.
> >
> > BeforeCancel ?
>
> Code parsed before cancel action is done ( you might for no reason at all
> want to count the times someone cancels and put this data into a table in
your
> database.
>
> > Validation ?
> Check if the user input is according to rules. ie date is filled in
correct
> format before sending the form or some variable that has to be filled
> isnt null
>
> >BeforeInsert ?
> Simple: some action done before the insert statement is send to the
> database. If you do inserts to more then one table you could use this
> event to get the Mysql insert id for that table.
> I use this event for email notification and mostly for date reformatting
> european dates to MySql format.I wrote a function for that so the code
> would look like:
> $flddatefield=dbdate($flddatefield);
>
>
> >BeforeUpdate ?
> Same as in the before insert. Before you do the update some information
> could be inserted in some other table ie a log of some kind.
>
> > BeforeDelete ?
> Same as above
>
> > BeforeExecute ?
> Same as above
>
> >AfterInsert ? >
> same as above
>
> >AfterUpdate ? AfterDelete ?
> same as above
>
> > BeforeShowUpdate ?
> Havnet used this one yet
>
> > BeforeShowInsert ?
> Havent used this one yet
>
> >BeforeShow ?
> This is the one I use the most because it allows me to do all kinds of
> stuff before the page is displayed.
> For example: In my company ( a drug addiction treatment center) the are
> workers that do groupTherapy sessions. These are always done by two
> Therapists. In one of the management tools I'm buiding managers want to
> see how many contacts each worker has over a period of a month. So before
> the page is displayed I divide the number of contacts by 2. So each
> worker get half of the count for that group. ($fieldX=$fldX /2;)
> Also Mysql saves dates in YYYY-MM-DD format but in europe whe use
> DD-MM-YYYY. All fields containing dates have to be reformatted. This is
> done in the beforeshow events with a function I wrote
> (showdbdate($flddatefield);
> showdbdate is only the name of the function not the function itself
> ofcourse.
>
> For form input you can automatically display cuurent date for your date
> field. In beforeshow event you put the code:
> $date=date('d-m-Y');
> $flddatefield=$date;
> Since the user is putting dates in european format in the forms these
> have to be reformatted in the beforeinsert or before update events so
> MySql knows what to do with them
>
> Hope this helps a bit.
>
> RonB
>
|
|
|
 |
RonB
|
| Posted: 04/04/2002, 11:11 AM |
|
On Wed, 03 Apr 2002 18:36:49 +0200, Dharma Mulya wrote:
> TQ both of you and if I am stuck can I refer to you again? I will start
> my new level now.
>
>
Sure, no prob
RonB
|
|
|
 |
Glenn Holden
|
| Posted: 04/04/2002, 2:13 PM |
|
Please do.
"Dharma Mulya" <supreme@mol.net.my> wrote in message
news:a8fb4c$847$1@news.codecharge.com...
> TQ both of you and if I am stuck can I refer to you again? I will start my
> new level now.
>
>
> RonB <r.borkent@chello123.nl> wrote in message
>news:a85a0r$8re$1@news.codecharge.com...
> > On Wed, 27 Mar 2002 18:39:57 +0100, Dharma Mulya wrote:
> >
> > > So what you are saying is that for me to go and learn PHP prior to
using
> > > CC. Point taken. And that will take me to this next question.
> > >
> > > Is there any note or rule as to what extend CC will do the coding for
> > > you and at what point should you jump in and put your knowledge of PHP
> > > to as you've mentioned? Can you explain to me please?
> > >
> > > TQ again.
> > >
> > > BeforeCancel ?
> >
> > Code parsed before cancel action is done ( you might for no reason at
all
> > want to count the times someone cancels and put this data into a table
in
> your
> > database.
> >
> > > Validation ?
> > Check if the user input is according to rules. ie date is filled in
> correct
> > format before sending the form or some variable that has to be filled
> > isnt null
> >
> > >BeforeInsert ?
> > Simple: some action done before the insert statement is send to the
> > database. If you do inserts to more then one table you could use this
> > event to get the Mysql insert id for that table.
> > I use this event for email notification and mostly for date reformatting
> > european dates to MySql format.I wrote a function for that so the code
> > would look like:
> > $flddatefield=dbdate($flddatefield);
> >
> >
> > >BeforeUpdate ?
> > Same as in the before insert. Before you do the update some information
> > could be inserted in some other table ie a log of some kind.
> >
> > > BeforeDelete ?
> > Same as above
> >
> > > BeforeExecute ?
> > Same as above
> >
> > >AfterInsert ? >
> > same as above
> >
> > >AfterUpdate ? AfterDelete ?
> > same as above
> >
> > > BeforeShowUpdate ?
> > Havnet used this one yet
> >
> > > BeforeShowInsert ?
> > Havent used this one yet
> >
> > >BeforeShow ?
> > This is the one I use the most because it allows me to do all kinds of
> > stuff before the page is displayed.
> > For example: In my company ( a drug addiction treatment center) the are
> > workers that do groupTherapy sessions. These are always done by two
> > Therapists. In one of the management tools I'm buiding managers want to
> > see how many contacts each worker has over a period of a month. So
before
> > the page is displayed I divide the number of contacts by 2. So each
> > worker get half of the count for that group. ($fieldX=$fldX /2;)
> > Also Mysql saves dates in YYYY-MM-DD format but in europe whe use
> > DD-MM-YYYY. All fields containing dates have to be reformatted. This is
> > done in the beforeshow events with a function I wrote
> > (showdbdate($flddatefield);
> > showdbdate is only the name of the function not the function itself
> > ofcourse.
> >
> > For form input you can automatically display cuurent date for your date
> > field. In beforeshow event you put the code:
> > $date=date('d-m-Y');
> > $flddatefield=$date;
> > Since the user is putting dates in european format in the forms these
> > have to be reformatted in the beforeinsert or before update events so
> > MySql knows what to do with them
> >
> > Hope this helps a bit.
> >
> > RonB
> >
>
>
|
|
|
 |
|