You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(7) |
Aug
(1) |
Sep
(30) |
Oct
(2) |
Nov
(2) |
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(4) |
Feb
(2) |
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(3) |
Nov
|
Dec
|
| 2007 |
Jan
(1) |
Feb
|
Mar
(3) |
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Wolfgang P. <wpi...@yo...> - 2007-08-19 10:03:27
|
Hi all,
i am using cpaint now already for some time - and i am quit happy with it=
(good job - thanks for it).
Now i am working on a new project where i do need to create database obje=
cts (persons) on the fly...
For
this i have decieded to use Javascript Objects - so i build a
Javascript Object Person - which takes the PErsons data with the
constructor - and then calls the cpaint.call function with that data.
As callback function i do have specifid a function inside of my object.
I did thought that the function will get called within the object
scope. But it does seem to not be so. The callback seems to get called
outside the object scope.
Is it possible to get the callback function called within the object scop=
e ?
Here is my example code:
function Person(firstname, lastname, birthdate) {
=A0=A0=A0 this.firstname =3D firstname;
=A0=A0=A0 this.lastname =3D lastname;
=A0=A0=A0 this.birthdate =3D birthdate;
=A0=A0=A0 this.personid =3D null;
=A0=A0=A0 // Will create the Person in the WHIDSYSTEM and set the person i=
d
=A0=A0=A0 this.cb_createPerson =3D function(result) {
=A0=A0=A0 =A0=A0=A0 if (!result) {
=A0=A0=A0 =A0=A0=A0 =A0=A0=A0 return null;
=A0=A0=A0 =A0=A0=A0 }
=A0=A0=A0 =A0=A0=A0 var person =3D result.getElementsByTagName('person');=
=A0=A0=A0 =A0=A0=A0 if ((!person) || (person.length!=3D1)) { return; }
=A0=A0=A0 =A0=A0=A0 person =3D person[0];
=A0=A0=A0 =A0=A0=A0 alert(this.firstname);=A0=A0 // Will return undefined=
=A0=A0=A0 =A0=A0=A0 this.personid =3D person.getAttribute('personid');
=A0=A0=A0 }
=A0=A0=A0 // Do call the servers create person function
=A0=A0=A0 cp.set_async(false);
=A0=A0=A0 cp.call("helpers/cca.php", 'createPerson',this.cb_createPerson,=
sessionid);
=A0=A0=A0 // Now we should have created the person so we have the personi=
d
=A0=A0=A0 // return to async operations
=A0=A0=A0 cp.set_async(true);
}
Thanks for hints
regards,
Wolfgang |
|
From: Paul S. <wi...@gm...> - 2007-03-16 00:29:07
|
All - I have decided to "retire" from CPAINT and cease all future development activity on the project. It has been a good run and I have met lots of people all across the world, but it's time to move on. I have other personal projects I would like to start working on ( http://www.wiley14.com/projects/) and have some time to relax (imagine that!) The website has been moved to it's permanent home - http://cpaint.sourceforge.net/. The documentation, source code, and even a dump of the old forum site is there for your reference. If anyone would like to pickup the code and start developing it again, please let me know and I'll hand over the reigns. I still think CPAINT is the best AJAX toolkit out there and I encourage you to keep using it for your own projects - I know I will! When I get around to it, I'm going to post some pointers on my blog ( www.wiley14.com) about the experiences I had while working on this project to help other people who want to get their own OSS project up and running. Again, it's been fun and I wish you all the best! Stay in touch, Paul Sullivan wi...@gm... |
|
From: Paul S. <wi...@gm...> - 2007-03-03 00:18:21
|
The backend uses UTF-8 encoding, which is essentially universal. Try using UTF-8 as the content type of your frontend web page. Take a look at http://cpaint.net/examples/encoding/index.html. It's a demo where we show a few different character sets, including Greek. Thanks, Paul On 3/2/07, ana...@ya... <ana...@ya...> wrote: > Hello all. > I had a problem which I belive it displayes a short-comming > of cpaint. > > I set from the front-end the response type into text. > Then from the back-end I set the data of the cpaint object > ($cp->set_data(Some Greek Text..). > The problem was that the text was not returned in the > front-end. > > I thought of using the method set_enconding. This method > however belongs to class cpaint_node. > The solution was that I created a dummy node and used > the node's set_encoding method. After that it worked fine. > > Since the cpaint object does have a set_data method, > I think it should have a set_encoding as well (and I'd > suggest that the encoding set by the cpaint's set_encoding > should be used by default from the cpaint_node objects). > > The method start does accept an encoding but in this way > I can not use a different encoding for each registered function. > > > The method I propose is: > function set_encoding($enc) { > $this->basenode->set_encoding($enc); > } > > Best regards. > > -- > Three words describe our society:homo homini lupus > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Cpaint-developers mailing list > Cpa...@li... > https://lists.sourceforge.net/lists/listinfo/cpaint-developers > |
|
From: <ana...@ya...> - 2007-03-02 20:59:15
|
Hello all.
I had a problem which I belive it displayes a short-comming
of cpaint.
I set from the front-end the response type into text.
Then from the back-end I set the data of the cpaint object
($cp->set_data(Some Greek Text..).
The problem was that the text was not returned in the
front-end.
I thought of using the method set_enconding. This method
however belongs to class cpaint_node.
The solution was that I created a dummy node and used
the node's set_encoding method. After that it worked fine.
Since the cpaint object does have a set_data method,
I think it should have a set_encoding as well (and I'd
suggest that the encoding set by the cpaint's set_encoding
should be used by default from the cpaint_node objects).
The method start does accept an encoding but in this way
I can not use a different encoding for each registered function.
The method I propose is:
function set_encoding($enc) {
$this->basenode->set_encoding($enc);
}
Best regards.
--
Three words describe our society:homo homini lupus
|
|
From: Paul S. <wi...@gm...> - 2007-01-23 16:23:12
|
In an attempt to breathe some fresh air into CPAINT and hopefully revive it, I am working up a new feature list for a release in the next few months. In addition, I am seeking help! * Fix NS_NOT_AVAILABLE_ERROR that's occuring in some Gecko based browsers (apparently, you have to wait a second after the page loads for the XMLHTTP object to become available. I haven't been able to reproduce it myself, but have a few reports of it happening). * Finish out WSDL & SOAP support in the backend * Add some sort of security "key" for accessing the backend (the basic idea here is that the client must send the server a key in order to gain access to the backend functionality - I'm sure there's more than one way to do this, so we need to figure out the best way) * Port the backend and proxy to Classic ASP * Create a plugin architecture for custom data converters/processors (had a concept last year, but never finished it) * Create a language independent settings/INI file (to configure the backend, proxy, etc...) * Anything else on the current TODO list not listed here ( http://cpaint.net/doc/todo.html) The following ideas could be done, depending on how many people we can get to help out: * Add/distribute a JavaScript widget library with CPAINT (have the code to a custom developed one, but needs lots of cleanup) * Port backend and proxy to other languages (PERL, ASP.Net, Ruby, etc) * New examples and more in-depth documentation, possibly a book If you are interested in helping out or have some ideas, please let me know. I'm going to attempt to make things a bit more formal and work up a design document once the features have been decided upon. Thanks, Paul |
|
From: Paul S. <wi...@gm...> - 2006-10-20 18:15:25
|
Dear Friends, It is with great pleasure to announce the release of CPAINT v2.1.0, which will be available worldwide momentarily at http://sf.net/projects/cpaint. Our last release was v2.0.3 on 8 February 2006. This version includes a significant amount of bug-fixes and enhancements. We welcome your comments and questions via our normal support methods, found on our website at http://www.cpaint.net/. In addition to the continual maintenance of CPAINT, we are working on a new developers guide, which we hope to make available soon. We would like to thank all of our users for their suggestions and code submissions which has made this release possible! Sincerely, the CPAINT Development Team CHANGELOG: //---- v2.1.0 (Released October 20, 2006) --------------------------------- - moved CPAINT 'core' files to lib to ease usage of CPAINT as SVN external without having to grab the examples and docs as well. - PHP: Added configuration value $cpaint2_config['proxy']['stream_timeout'] for the number of miliseconds to have the proxy wait for the response. - PHP: Added configuration value $cpaint2_config['proxy']['connect_timeout'] for the number of seconds to have the proxy wait until connection is established. - PHP: Added configuration value $cpaint2_config['proxy']['time_limit'] for the maximum runtime of the proxy script in seconds. - PHP: Added configuration value $cpaint2_config['proxy']['security']['error_reporting'] to set the level of PHP's error_reporting value for the proxy. - PHP: Made use of whitelist for both POST and GET requests. - PHP: Recognize http:// as default procotol in proxy script. (thanks oroshchuk) - PHP: Refactored the proxy-script for better maintainability. - PHP: Using <?php as PHP opening tag instead of <? in backend-debugger. - PHP: Perfomed variable initialization in config script. Using <?php as PHP opening tag instead of <?. - PHP: Cleaned up the code of the proxy script. - PHP: Checks for existance of arguments before assigning to local variable. - EXAMPLES: Fixed URL of proxy script in proxy-ping example. - EXAMPLES: Cleaned up the code of the calculator example. - EXAMPLES: Fixed issue in colorpicker example that prevented it from working. - PHP, JS: Added support for aliases to hide the names of CPAINT API methods in register(). - PHP: Removed configuration file dependency (core backend) (thanks miwhite) - PHP: Commented out WSDL-specific code blocks and variables - JS: Added ability to set HTTP Basic Authentication username and password when accessing local scripts (including proxy utility). - JS: Fixed handling of numeric strings (thanks ironoxide) - JS: Fixed typo in proxy calling code (thanks miwhite) - JS: Fixed create_object_structure to handle text nodes >4096 bytes (thanks Nelson Antunes) - JS: Fixed problem parsing attributes of first XML node element (thanks Nelson Antunes) - EXAMPLES: Fixed typo in Google example (thanks Curtis Farnham) - DOC: Fixed typo in frontend development guide (thanks James Johnson) - PROXY: Added the ability to use the CURL library, with ability to failover to built-in PHP socket functionality |
|
From: Paul S. <wi...@gm...> - 2006-10-05 16:08:14
|
Since I've never used JQuery, I can't give you a definate answer. But, CPAINT can interpret and convert JS data objects, so I would say as long as JQuery does the same, you shouldn't have too much trouble. As far as the new release, I think we are shooting for the middle of October. We are testing out the new functionality right now and updating our documentation (including a completely rewritten developer's guide). Thanks, Paul On 10/5/06, ir...@ao... <ir...@ao...> wrote: > > Do they integrate well (CPaint and JQuery)? > Any news regarding the upcoming release? > ________________________________ > Check out the new AOL. Most comprehensive set of free safety and security > tools, free access to millions of high-quality videos from across the web, > free AOL Mail and more. > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > Cpaint-developers mailing list > Cpa...@li... > https://lists.sourceforge.net/lists/listinfo/cpaint-developers > > > |
|
From: <ir...@ao...> - 2006-10-05 05:09:44
|
Do they integrate well (CPaint and JQuery)? Any news regarding the upcoming release? ________________________________________________________________________ Check out the new AOL. Most comprehensive set of free safety and security tools, free access to millions of high-quality videos from across the web, free AOL Mail and more. |
|
From: Paul S. <wi...@gm...> - 2006-09-11 20:59:46
|
Hi All, It's been over a year since CPAINT was released and a few months since any real work has been done. But, a few items have come up and I am sending this out to solicit any more comments/suggestions/items for the list: Backend: - Add "aliases" for registered functions (good for hiding function names from prying eyes or calling static methods). - Update the JSON implementation (it's been reported that lots of warnings & notices come up, although it works fine) Frontend: - Update the JSON implementation (Dominique sent me a new implementation, but haven't released a new distro with it. - Possibly add configurable JavaScript widgets (still getting clearance for work to release some work I've done in this area) Project: - Get the forums back online (recieved massive amounts of spam, so I turned them off) - Create an FAQ - Update developer documentation with better examples, including accessing XML servers via CPAINT frontend Again, if you've got any ideas you'd like to see implemented in CPAINT, let me know. I'll get them on the list, but I'm not setting any release dates right now. Thanks, Paul |
|
From: Paul S. <wi...@gm...> - 2006-04-28 15:16:31
|
Here is the changelog (so far). There are a few more bugs that I need to verify (they might not be bugs at all). I also need to update the documentation to reflect a few "tricks" that we've found recently. =BB PHP: Removed configuration file dependency (core backend) (thanks miwhi= te) =BB PHP: Commented out WSDL-specific code blocks and variables =BB JS: Fixed typo in proxy calling code (thanks miwhite) =BB EXAMPLES: Fixed typo in Google example (thanks Curtis Farnham) =BB DOC: Fixed typo in frontend development guide (thanks James Johnson) I'm shooting for a release on May 1st if I finish testing. |
|
From: Paul S. <wi...@gm...> - 2006-02-28 01:52:55
|
Seems the media has blown this one completely out of proportion - http://www.informationweek.com/story/showArticle.jhtml?articleID=3D18020647= 2 Well, not exactly based on what I read - http://patft.uspto.gov/netacgi/nph-Parser?Sect1=3DPTO1&Sect2=3DHITOFF&d=3DP= ALL&p=3D1&u=3D/netahtml/srchnum.htm&r=3D1&f=3DG&l=3D50&s1=3D7,000,180.WKU.&= OS=3DPN/7,000,180&RS=3DPN/7,000,180 They are trying to claim certain components of a website that could be built with AJAX, but not AJAX itself. |
|
From: Paul S. <wi...@gm...> - 2006-02-09 01:19:14
|
All, We were notified of a vulnerability that could compromise client-side security and allow scripts from a third-party server to execute. The exploit can be seen at http://cpaint.wiley14.com/examples/type/type.php?cpaint_response_type=3D%3C= iframe%20src=3Dhttp://www.gulftech.org/%3E and occurs when the developer sets the frontend response type option to an HTML string (which generates an error on the backend that echoes the HTML code to the client). We believe this exploit was more of an oversight on our part in not properly scrubbing incoming server options and data. However, we do not believe that this is a widespread, critical issue since it must be consciously exploited by the CPAINT developer. This hole was discovered by James Bercegay <sec...@gu...> of GulfTech Research and Development, Gulfport Mississippi US. We thank James for bringing this to our attention and working with us to find a solution. We have released version 2.0.3 which contains the appropriate patches on SourceForge.Net. The download location is http://sourceforge.net/project/showfiles.php?group_id=3D141041&package_id= =3D154713&release_id=3D392071. We highly recommend that you upgrade to this version as soon as possible. We want to assure our users that we still have complete confidence in CPAINT and the security mechanisms we have already implemented.=20 Please understand that these security advisories do not mean that we are naive (as the Dojo folks accused last time) or incompetent. There is no such thing as a 100% secure application and to believe so is truly being naive. We are glad that our software is successful enough to warrant a public security advisory and we continue to work towards an enterprise-strength toolkit with unsurpassed security. Sincerely, Paul Sullivan on behalf of the CPAINT Development Team http://cpaint.sourceforge.net/ http://sf.net/projects/cpaint/ |
|
From: Sam <sa...@te...> - 2006-01-24 00:38:01
|
Hi, I want to use cpaint implement a tree-like menu. I searched cpaint directory, couldn't found an example. Can anyone please post an example or a guideline how to do so using cpaint? Thanks Sam |
|
From: Paul S. <wi...@gm...> - 2006-01-17 20:56:49
|
The long awaited v2.0.2 of CPAINT is scheduled for release on Friday, 20 January 2006 via SourceForge.Net (http://sf.net/projects/cpaint). The two major changes in this release are the addition of JSON for passing objects between the frontend and backend seamlessly and the removal of the ASP implementation of the CPAINT backend. Future releases of CPAINT will include additional security & authorization mechanisms, Webservices (WSDL/SOAP) support on both frontend & backend, session support, bookmarkable links, older browser detection and support, comprehensive frontend & backend debugging, backend XML input support, and plugins (enabling custom input/output translators, events, and much more). The entire CPAINT team thanks you for your continued support! * See us in "Foundations of Ajax" by Aselson & Schutta (ISBN 1590595823) and "Ajax in Action" by Crane, Pascarello, & James (ISBN 1932394613). Changelog: //---- v2.0.2 (Released 20 January 2006) -------------------------- - JS: check HTTP response code and throw an error if request was not accepted by server. (thanks gloomyandy) - JS: allowing the underscore in node names. - JS: added support for the passing of arrays and objects to the backend. - JS: added X-Powered-By request header. - JS: node names, attribute names and -values from backend are now expected to be valid ISO-8859-1. - JS: fixed wrong initialization of the data property to int zero in class cpaint_result_object. - JS: removed unneccessary setter() methods from internal classes to reduce size. - JS: added debugging level cp.set_debug(-1) to suppress errors. - JS: fixed type conversion issue where non-empty, pure whitespace strings where interpreted as numbers. - JS: fixed problem with callback being called twice. (thanks to Lance Rushing) - JS: fixed problem with URLs with existing GET parameters. (thanks to Nelson Antunes) - JS / PHP: added support for JSON as response type. - JS / PHP: added support for E4X as response type. - PHP: added cpaint::unregister() - PHP: added cpaint::get_response_type(); - PHP: removed a bug in JSON library that prevented the generation of valid= JSON when including a leading zero character. - PHP: Removed unneccessary unescaping of parameters in proxy script. - PHP: added support for array and object parameters from JavaScript (JSON!= ). - PHP: added X-Powered-By response header. - PHP: removed encoding of node names, attribute names and attribute values to UTF-8 if possible. those values must now be valid ISO-8859-1. - PHP: removed output buffer to make it possible to include backend and frontend in the same file. - PHP: fixed error output (a function was called...) when no parameters where sent to CPAINT indicating a function call, thus making it possible to include backend and frontend in the same file (thanks S. Alexandre M. Lemaire) - PHP: added backend debugger code to main source tree & documentation. - PHP: secured proxy utility (see documentation). - PHP: added backend configuration file (for proxy security and future use) - ASP: removed from distribution to focus on PHP and other ports. |
|
From: Paul S. <wi...@gm...> - 2006-01-16 17:53:33
|
Hi Folks! After a few days of testing, I discovered that the original detection code I sent was returning erronious results and crashing some (older) browsers. Therefore, I have updated the code and have tested it with browsers as low as 3.0 (which I highly doubt anyone is still using). Attached is the new code. It no longer redirects, but instead displays a less annoying alert box with the result. That result is one of the following: activex - IE only, use an ActiveX object builtin - Opera, Mozilla-based browsers, & safari - use built in object java - Java is enabled and can use an applet iframe - IE 3.0Beta2+, Netscape 6.0Beta1+, Opera 4.0+ - use an IFRAME ilayer - Netscape 4.0Beta2 to 4.8 - use an ILAYER (similar to an IFRAME) none - no real "AJAX" capability, must use old skool forms Please feel free to test and report any results. I'm working on an implementation of CPAINT that will utilize IFRAMEs and ILAYERs for older browsers. I've also reverse-engineered a Java applet to use as well. Enjoy! Pauly |
|
From: Paul S. <wi...@gm...> - 2006-01-13 19:45:33
|
All, Attached is JavaScript code that can detect the AJAX "compliance" of a web browser. I have tested it in some really old browsers and so far the script works, but I will keep testing it. There are four levels of "compliance" that I determine through this script: * activex - the browser can use the Microsoft ActiveX objects (IE only) * builtin - the browser can use a built-in XMLHttpRequest object (other browsers) * java - the browser can use a Java applet for communications * iframe - the browser may be able to use an iframe for communications Note, as of this moment, there is not a "non-compliance level", as I believe that most browsers that use JavaScript at the very least could use an IFRAME for fallback communications. However, I am still investigating this concept and may add a "non" level to this script at a later date. Currently, this script simply detects the compliance level and redirects the browser, attaching the level to the querystring. Please feel free to test and your comments/suggestions are welcome.=20 This code isn't part of the official CPAINT release yet, but probably will be as part of our effort to support some older browsers via the IFRAME and Java applet fallbacks. Thanks, Paul |
|
From: Paul S. <wi...@gm...> - 2005-11-08 22:13:12
|
All, If you haven't figured out by now - the CPAINT development team took some time off. Over the past few weeks, we've been trying to figure out where to take CPAINT, improve our processes, and uncover ourselves from a blizzard o= f emails. Now that we've had some time to catch our breath, it's long past time that we get ourselves (and CPAINT) back on track. Therefore, we are going to attempt to get a new minor release of CPAINT out by December 25th. Our goal for this release will be to improve the code and documentation, based on the feedback we've received via email, the forums, and support tickets. The next release will support only ASP & PHP, although we will try extremely hard to get it running in other languages after the new year. I am also looking for new talent to join the team, so Dominique and myself aren't overwhelmed in the future. In particular, we are looking for help in porting CPAINT to other backend languages (targets are Perl, Python, .NET, and Ruby) and frontend JavaScript developers (specifically, GUI design/interaction). We also need to assemble a QA team, so we don't have any problems like we did in the past. If you're interested in helping, please fill out this nifty little form at http://cpaint.booleansystems.com/questionnaire.php and introduce yourself t= o us. And keep checking our forums at http://cpaint.booleansystems.com/forums/(the News & Announcements section in particular) for new information. Thanks for everyone's time and continued support! Sincerely, Paul _________________ Paul Sullivan (wiley14) CPAINT Development Team http://cpaint.sourceforge.net/ |
|
From: Paul S. <wi...@gm...> - 2005-11-04 21:53:21
|
We are currently looking for developers, QA engineers, support engineers, and technical writers to assist us in the continual development of CPAINT. If you are interested, please visit http://cpaint.booleansystems.com/questionnaire.php and fill out the short form. We will contact you after we've had a chance to review your information. Thanks, Paul _________________ Paul Sullivan CPAINT Development Team http://cpaint.sourceforge.net/ |
|
From: Paul S. <wi...@gm...> - 2005-10-23 00:35:55
|
I'm not understanding your question or issue. It looks like you got it to =
work.
On 10/22/05, marco <ma...@ke...> wrote:
> getting it to work took some dedication.
>
> I used the official documentation, getting the response
> attributes slowed me down.
>
> For single values:
> use $cp->set_data($string1); in the back-end to sent
> the string.
> in the frontend assign your result with
> document.getElementById('id for entry field for
> string1').value =3D result.ajaxResponse[0].data;
> (the front-end is default to return type object)
>
> For multiple values:
> backend;
> $string1_node =3D& $cp->add_node("node name for string1");
> $string2_node =3D& $cp->add_node("node name for string2");
> $string1_node->set_data($string1);
> $string2_node->set_data($string2);
> frontend;
> > return type set to XML (i did not get the
> get_attribute call to work).
> document.getElementById('id for string1').value =3D
> result.getElementsByTagName('node name for
> string1').item(0).firstChild.data;
> document.getElementById('id for string2').value
> =3D result.getElementsByTagName('node name for
> string2').item(0).firstChild.data;
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by the JBoss Inc.
> Get Certified Today * Register for a JBoss Training Course
> Free Certification Exam for All Training Attendees Through End of 2005
> Visit http://www.jboss.com/services/certification for more information
> _______________________________________________
> Cpaint-developers mailing list
> Cpa...@li...
> https://lists.sourceforge.net/lists/listinfo/cpaint-developers
>
|
|
From: marco <ma...@ke...> - 2005-10-22 21:46:08
|
getting it to work took some dedication.
I used the official documentation, getting the response
attributes slowed me down.
For single values:
use $cp->set_data($string1); in the back-end to sent
the string.
in the frontend assign your result with
document.getElementById('id for entry field for
string1').value = result.ajaxResponse[0].data;
(the front-end is default to return type object)
For multiple values:
backend;
$string1_node =& $cp->add_node("node name for string1");
$string2_node =& $cp->add_node("node name for string2");
$string1_node->set_data($string1);
$string2_node->set_data($string2);
frontend;
> return type set to XML (i did not get the
get_attribute call to work).
document.getElementById('id for string1').value =
result.getElementsByTagName('node name for
string1').item(0).firstChild.data;
document.getElementById('id for string2').value
= result.getElementsByTagName('node name for
string2').item(0).firstChild.data;
|
|
From: Paul S. <wi...@gm...> - 2005-09-19 21:51:34
|
The CPAINT development team has launched a new discussion board at http://cpaint.sourceforge.net/forums/. The new board includes a variety of topics and will be a great place to get help from peers and the CPAINT development team, including a moving FAQ, and "unofficial" project news. We strongly encourage you use this new forum for communicating with other CPAINT developers and the core development team. http://cpaint.sourceforge.net/forums/ |
|
From: Dominique S. <sal...@ya...> - 2005-09-12 08:36:21
|
Hi Alexandre, thanks for the code. I'll be looking at it next week (I'm out of town until sunday), so don't wonder if you don't hear from us :). Thanks, Dominique --- "S. Alexandre M. Lemaire" <sa...@sa...> wrote: > Glad to hear, while I don't claim to have full > knowledge of CPaint's functions - here's where I've > placed hooks. The functions finished, are as > follows, again, I post these here with your > assurance that the author comment will remain. I'm > always weary to contribute to open sourced projects, > hopefully this will be a positive experience :) I > leave any testing and furthering to you, I've used > this only with the standard response type. Note > that I've made use of SimpleXML (PHP5). You could > use any PHP-side XML parser to recreate the arrays, > simpleXML is just a personal preference of ours. > > Cordially. > Alexandre > > cpaint.php > > > Added to the cpaint_transform object > > > /** > * Unserialize a cpaint-serialized set of values > * @author A. Lemaire, saeven.net consulting inc > * @param string $data A string of 'serialized|' > prefixed data which is to be converted into XML. > * @return mixed An array of values representative > of the HTML form options > */ > function unserialize( $data, $encoding ){ > > $data = substr( $data, 11, strlen( $data ) - 11 > ); > $xml = simplexml_load_string( $data ); > $arr = array(); > > foreach( $xml->e as $e ){ > if( isset( $e->v ) ) > $arr[urldecode( (string)$e->k )] = > urldecode( (string)$e->v); > else{ > $narr = array(); > foreach( $e->m->v as $val ) > array_push( $narr, (string)$val ); > > $arr[urldecode( (string)$e->k )] = > $narr; > } > } > > return $arr; > } > > > And then your array_decode function must be changed > to look like this: > > /** > * decodes a (nested) array of data from UTF-8 > into the configured character set > * > * @access public > * @param array $data data to > convert > * @param string $encoding character > encoding > * @return array > */ > function decode_array($data, $encoding) { > $return_value = array(); > > foreach ($data as $key => $value) { > > if( @substr( $value, 0, 11 ) == 'serialized|' > ) > $return_value[$key] = > cpaint_transformer::unserialize( $value, $encoding > ); > else if( !is_array($value) ) { > $return_value[$key] = > cpaint_transformer::decode( $value, $encoding ); > > } else { > $return_value[$key] = > cpaint_transformer::decode_array($value, $encoding); > } > } > > return $return_value; > } > > > cpaint2.inc.js > > /** > * Serialize a form object into CPaint-PHP usable > data > * > * @author A. Lemaire, saeven.net consulting inc. > * @param string formData The form that is to be > serialized > * @access public > * @return string XML-serialized form data > */ > this.serializeForm = function( formData, depth ){ > oxml = "serialized|<o>"; > for( var i = 0 ; i < formData.length ; i++ ){ > > var key = formData[i].name; > var value = formData[i].value; > var mult = false; > > if( !key ) > continue; > > switch( formData[i].type ){ > case 'file': > continue; > case 'select-multiple': > mult = true; > > oxml += "<e><k>" + encodeURIComponent( key ) + > "</k><m>"; > for( var j = 0 ; j < formData[i].options.length > ; j++ ) > if( formData[i].options[j].selected ) > oxml += "<v>" + encodeURIComponent( > formData[i].options[j].value ) + "</v>"; > oxml += "</m></e>"; > break; > case 'checkbox': > if( formData[i].checked == false ) > value = 0; > break; > case 'radio': > if( formData[i].checked == false ) > continue; > break; > default: > break; > } > > if( !mult ) > oxml += "<e><k>" + encodeURIComponent( key ) + > "</k><v>" + encodeURIComponent( value ) + > "</v></e>"; > > } > oxml += "</o>"; > return oxml; > } > > > And then you must alter your call functions as > follows to call the above code: > > /** > * internal method for remote calls to the local > server without use of the proxy script. > * > * @access public > * @param array call_arguments array of > arguments initially passed to cpaint.call() > * @return void > */ > this.call_direct = function( call_arguments ) { > var url = call_arguments[0]; > var remote_method = call_arguments[1]; > var querystring = ''; > var i = 0; > > // correct link to self > if (url == 'SELF') { > url = document.location.href; > } > > if (use_cpaint_api == true) { > // backend uses cpaint api > // pass parameters to remote method > for( i = 3; i < call_arguments.length; i++ ){ > if( typeof( call_arguments[i] ) == 'object' > && call_arguments[i].tagName == 'FORM' ) > call_arguments[i] = this.serializeForm( > call_arguments[i].elements, 0 ); > querystring += '&cpaint_argument[]=' + > encodeURIComponent(call_arguments[i]); > } > > // add response type to querystring > querystring += '&cpaint_response_type=' + > response_type; > > // build header > if (transfer_mode == 'GET') { > url = url + '?cpaint_function=' + > remote_method + querystring; > > } else { > querystring = 'cpaint_function=' + > remote_method + querystring; > } > > } else { > // backend does not use cpaint api > // pass parameters to remote method > for (i = 3; i < call_arguments.length; i++) { > if (i == 3) { > querystring += > encodeURIComponent(call_arguments[i]); > > } else { > querystring += '&' + > encodeURIComponent(call_arguments[i]); > } > } > > // build header > if (transfer_mode == 'GET') { > url = url + querystring; > } > } > > // open connection > get_connection_object(); > > // open connection to remote target > debug('opening connection to "' + url + '"', 1); > httpobj.open(transfer_mode, url, async); > > // send "urlencoded" header if necessary (if > POST) > if (transfer_mode == "POST") { > > try { > httpobj.setRequestHeader("Content-Type", > "application/x-www-form-urlencoded"); > > } catch (cp_err) { > alert('ERROR! POST cannot be completed due > to incompatible browser. Use GET as your request > method.'); > } > } > > // callback handling for asynchronous calls > httpobj.onreadystatechange = callback; > > // send content > if (transfer_mode == 'GET') { > httpobj.send(null); > > } else { > debug('sending query: ' + querystring, 1); > httpobj.send(querystring); > } > > if (async == false) { > // manual callback handling for synchronized > calls > callback(); > } > } > > > /** > * internal method for calls to remote servers > through the proxy script. > * > * @access public > * @param array call_arguments array of > arguments passed to cpaint.call() > * @return void > */ > this.call_proxy = function(call_arguments) { > var proxyscript = proxy_url; > var url = call_arguments[0]; > var remote_method = call_arguments[1]; > var querystring = ''; > var i = 0; > > > var querystring_argument_prefix = > 'cpaint_argument[]='; > > // pass parameters to remote method > if (use_cpaint_api == false) { > // when not talking to a CPAINT backend, don't > prefix arguments > querystring_argument_prefix = ''; > } > > for (i = 3; i < call_arguments.length; i++) { > if( typeof( call_arguments[i] ) == 'object' && > call_arguments[i].tagName == 'FORM' ) > call_arguments[i] = this.serializeForm( > call_arguments[i].elements, 0 ); > querystring += > encodeURIComponent(querystring_argument_prefix + > call_arguments[i] + '&'); > } > > if (use_cpaint_api == true) { > // add remote function name to querystring > querystring += > encodeURIComponent('&cpaint_function=' + > remote_method); > > // add response type to querystring > querystring += > encodeURIComponent('&cpaint_responsetype=' + > response_type); > } > > // build header > if (transfer_mode == 'GET') { > proxyscript += '?cpaint_remote_url=' + > encodeURIComponent(url) > + '&cpaint_remote_query=' + querystring > + '&cpaint_remote_method=' + transfer_mode > + '&cpaint_response_type=' + response_type; > > } else { > querystring = 'cpaint_remote_url=' + > encodeURIComponent(url) > + '&cpaint_remote_query=' + querystring > + '&cpaint_remote_method=' + transfer_mode > + '&cpaint_response_type=' + response_type; > } > > // open connection > get_connection_object(); > > // open connection to remote target > debug('opening connection to proxy "' + > proxyscript + '"', 1); > httpobj.open(transfer_mode, proxyscript, async); > > // send "urlencoded" header if necessary (if > POST) > if (transfer_mode == "POST") { > > try { > httpobj.setRequestHeader("Content-Type", > "application/x-www-form-urlencoded"); > > } catch (cp_err) { > alert('[CPAINT Error] POST cannot be > completed due to incompatible browser. Use GET as > your request method.'); > } > } > > // callback handling for asynchronous calls > httpobj.onreadystatechange = callback; > > // send content > if (transfer_mode == 'GET') { > httpobj.send(null); > > } else { > debug('sending query: ' + querystring, 1); > httpobj.send(querystring); > } > > if (async == false) { > // manual callback handling for synchronized > calls > callback(); > } > } > > > Regards. > Alex > > ----- Original Message ----- > From: "Dominique Stender" <sal...@ya...> > To: <cpa...@li...> > Sent: Monday, September 12, 2005 3:18 AM > Subject: Re: [Cpaint-developers] Serializing form > objects into PHP arrays > > > Hi, > > don't worry about credit. We give full credit even > on > pointing out bugs. You will be mentioned in the doc > comments if we include your code into CPAINT. > > If you like, post the code in sf.net as patch, we'll > see how we can integrate it into CPAINT 2.0.2 if > possible. > > Thanks in advance, > Dominique > > --- "S. Alexandre M. Lemaire" <sa...@sa...> > wrote: > > > CPaint.. > > > > I've readied a function which turns form > objects > > into PHP arrays through > > CPaint. It works to my liking, and I'd be glad to > > share, since this would > > be to everyone's benefit. As a boon to your > library > > though, I trust that > > credit would be given where due? All I ask is > that > > the > > @author function comment remain intact if > possible. > > > > Here's an example print_r of what ends up at the > PHP > > function after the > > cp.call, this was a form with two fields, email1, > > email2, a checkbox > > (unchecked, when checked it sends the value), and > > lastly a select list which > > was a multiple select, where mama and 123 were > > selected. > > > > array ( > > 'email1' => 'some field value', > > 'email2' => '', > > 'checkbox' => '0', > > 'listval' => > > array ( > > 0 => 'mama', > > 1 => '123', > > ), > > 'Submit' => 'Save', > > ) > > > > Cordially. > > Alexandre > > > > > > > > > ------------------------------------------------------- > > SF.Net email is Sponsored by the Better Software > > Conference & EXPO > > September 19-22, 2005 * San Francisco, CA * > > Development Lifecycle Practices > > Agile & Plan-Driven Development * Managing > Projects > > & Teams * Testing & QA > > Security * Process Improvement & Measurement * > > http://www.sqe.com/bsce5sf > > _______________________________________________ > > Cpaint-developers mailing list > > Cpa...@li... > > > https://lists.sourceforge.net/lists/listinfo/cpaint-developers > > > > > > > __________________________________ > Yahoo! Mail - PC Magazine Editors' Choice 2005 > http://mail.yahoo.com > > > ------------------------------------------------------- > SF.Net email is Sponsored by the Better Software > Conference & EXPO > September 19-22, 2005 * San Francisco, CA * > Development Lifecycle Practices > Agile & Plan-Driven Development * Managing Projects > & Teams * Testing & QA > Security * Process Improvement & Measurement * > http://www.sqe.com/bsce5sf > _______________________________________________ > Cpaint-developers mailing list > Cpa...@li... > https://lists.sourceforge.net/lists/listinfo/cpaint-developers > > ______________________________________________________ Yahoo! for Good Donate to the Hurricane Katrina relief effort. http://store.yahoo.com/redcross-donate3/ |
|
From: S. A. M. L. <sa...@sa...> - 2005-09-12 07:40:11
|
Glad to hear, while I don't claim to have full knowledge of CPaint's = functions - here's where I've placed hooks. The functions finished, are = as follows, again, I post these here with your assurance that the author = comment will remain. I'm always weary to contribute to open sourced = projects, hopefully this will be a positive experience :) I leave any = testing and furthering to you, I've used this only with the standard = response type. Note that I've made use of SimpleXML (PHP5). You could = use any PHP-side XML parser to recreate the arrays, simpleXML is just a = personal preference of ours. Cordially. Alexandre cpaint.php Added to the cpaint_transform object /** * Unserialize a cpaint-serialized set of values * @author A. Lemaire, saeven.net consulting inc * @param string $data A string of 'serialized|' prefixed data which is = to be converted into XML. * @return mixed An array of values representative of the HTML form = options */ function unserialize( $data, $encoding ){ =20 =20 $data =3D substr( $data, 11, strlen( $data ) - 11 ); =20 $xml =3D simplexml_load_string( $data ); $arr =3D array(); =20 foreach( $xml->e as $e ){ if( isset( $e->v ) ) $arr[urldecode( (string)$e->k )] =3D urldecode( = (string)$e->v); else{ $narr =3D array(); foreach( $e->m->v as $val ) =20 array_push( $narr, (string)$val ); =20 $arr[urldecode( (string)$e->k )] =3D $narr; } } =20 return $arr; =20 } And then your array_decode function must be changed to look like this: /** * decodes a (nested) array of data from UTF-8 into the configured = character set *=20 * @access public * @param array $data data to convert * @param string $encoding character encoding * @return array */ function decode_array($data, $encoding) { $return_value =3D array(); =20 foreach ($data as $key =3D> $value) { =20 if( @substr( $value, 0, 11 ) =3D=3D 'serialized|' ) $return_value[$key] =3D cpaint_transformer::unserialize( = $value, $encoding ); =20 else if( !is_array($value) ) { $return_value[$key] =3D cpaint_transformer::decode( $value, = $encoding ); } else { $return_value[$key] =3D = cpaint_transformer::decode_array($value, $encoding); } } return $return_value; }=20 cpaint2.inc.js /** * Serialize a form object into CPaint-PHP usable data * * @author A. Lemaire, saeven.net consulting inc. * @param string formData The form that is to be serialized * @access public * @return string XML-serialized form data */ this.serializeForm =3D function( formData, depth ){ oxml =3D "serialized|<o>"; for( var i =3D 0 ; i < formData.length ; i++ ){ =20 var key =3D formData[i].name; var value =3D formData[i].value; var mult =3D false; =20 if( !key ) continue; =20 switch( formData[i].type ){ case 'file': continue; case 'select-multiple': mult =3D true; oxml +=3D "<e><k>" + encodeURIComponent( key ) + "</k><m>"; for( var j =3D 0 ; j < formData[i].options.length ; j++ ) if( formData[i].options[j].selected ) oxml +=3D "<v>" + encodeURIComponent( = formData[i].options[j].value ) + "</v>"; oxml +=3D "</m></e>"; break; case 'checkbox': if( formData[i].checked =3D=3D false ) value =3D 0; break; case 'radio': if( formData[i].checked =3D=3D false ) continue; break; default: break; } =20 if( !mult ) oxml +=3D "<e><k>" + encodeURIComponent( key ) + "</k><v>" + = encodeURIComponent( value ) + "</v></e>"; } oxml +=3D "</o>";=20 return oxml; } And then you must alter your call functions as follows to call the above = code: /** * internal method for remote calls to the local server without use of = the proxy script. * * @access public * @param array call_arguments array of arguments initially = passed to cpaint.call() * @return void */ this.call_direct =3D function( call_arguments ) { var url =3D call_arguments[0]; var remote_method =3D call_arguments[1]; var querystring =3D ''; var i =3D 0; =20 // correct link to self if (url =3D=3D 'SELF') { url =3D document.location.href; } =20 if (use_cpaint_api =3D=3D true) { // backend uses cpaint api // pass parameters to remote method for( i =3D 3; i < call_arguments.length; i++ ){=20 if( typeof( call_arguments[i] ) =3D=3D 'object' && = call_arguments[i].tagName =3D=3D 'FORM' ) call_arguments[i] =3D this.serializeForm( = call_arguments[i].elements, 0 ); querystring +=3D '&cpaint_argument[]=3D' + = encodeURIComponent(call_arguments[i]); } =20 // add response type to querystring querystring +=3D '&cpaint_response_type=3D' + response_type; =20 // build header if (transfer_mode =3D=3D 'GET') { url =3D url + '?cpaint_function=3D' + remote_method + = querystring; =20 } else { querystring =3D 'cpaint_function=3D' + remote_method + = querystring; } =20 } else { // backend does not use cpaint api // pass parameters to remote method for (i =3D 3; i < call_arguments.length; i++) { if (i =3D=3D 3) { querystring +=3D encodeURIComponent(call_arguments[i]); =20 } else { querystring +=3D '&' + encodeURIComponent(call_arguments[i]); } } =20 // build header if (transfer_mode =3D=3D 'GET') { url =3D url + querystring; }=20 } =20 // open connection=20 get_connection_object(); // open connection to remote target debug('opening connection to "' + url + '"', 1); httpobj.open(transfer_mode, url, async); // send "urlencoded" header if necessary (if POST) if (transfer_mode =3D=3D "POST") { try { httpobj.setRequestHeader("Content-Type", = "application/x-www-form-urlencoded"); } catch (cp_err) { alert('ERROR! POST cannot be completed due to incompatible = browser. Use GET as your request method.'); } } // callback handling for asynchronous calls httpobj.onreadystatechange =3D callback; // send content if (transfer_mode =3D=3D 'GET') { httpobj.send(null); } else { debug('sending query: ' + querystring, 1); httpobj.send(querystring); } if (async =3D=3D false) { // manual callback handling for synchronized calls callback(); } } =20 =20 /** * internal method for calls to remote servers through the proxy = script. * * @access public * @param array call_arguments array of arguments passed to = cpaint.call() * @return void */ this.call_proxy =3D function(call_arguments) { var proxyscript =3D proxy_url; var url =3D call_arguments[0]; var remote_method =3D call_arguments[1]; var querystring =3D ''; var i =3D 0; =20 =20 var querystring_argument_prefix =3D 'cpaint_argument[]=3D'; // pass parameters to remote method if (use_cpaint_api =3D=3D false) { // when not talking to a CPAINT backend, don't prefix arguments querystring_argument_prefix =3D ''; } for (i =3D 3; i < call_arguments.length; i++) { if( typeof( call_arguments[i] ) =3D=3D 'object' && = call_arguments[i].tagName =3D=3D 'FORM' ) call_arguments[i] =3D this.serializeForm( = call_arguments[i].elements, 0 ); querystring +=3D encodeURIComponent(querystring_argument_prefix + = call_arguments[i] + '&'); } if (use_cpaint_api =3D=3D true) { // add remote function name to querystring querystring +=3D encodeURIComponent('&cpaint_function=3D' + = remote_method); =20 // add response type to querystring querystring +=3D encodeURIComponent('&cpaint_responsetype=3D' + = response_type); } =20 // build header if (transfer_mode =3D=3D 'GET') { proxyscript +=3D '?cpaint_remote_url=3D' + encodeURIComponent(url) = + '&cpaint_remote_query=3D' + querystring + '&cpaint_remote_method=3D' + transfer_mode=20 + '&cpaint_response_type=3D' + response_type; } else { querystring =3D 'cpaint_remote_url=3D' + encodeURIComponent(url) + '&cpaint_remote_query=3D' + querystring + '&cpaint_remote_method=3D' + transfer_mode=20 + '&cpaint_response_type=3D' + response_type; } // open connection get_connection_object(); // open connection to remote target debug('opening connection to proxy "' + proxyscript + '"', 1); httpobj.open(transfer_mode, proxyscript, async); // send "urlencoded" header if necessary (if POST) if (transfer_mode =3D=3D "POST") { try { httpobj.setRequestHeader("Content-Type", = "application/x-www-form-urlencoded"); } catch (cp_err) { alert('[CPAINT Error] POST cannot be completed due to = incompatible browser. Use GET as your request method.'); } } // callback handling for asynchronous calls httpobj.onreadystatechange =3D callback; // send content if (transfer_mode =3D=3D 'GET') { httpobj.send(null); } else { debug('sending query: ' + querystring, 1); httpobj.send(querystring); } if (async =3D=3D false) { // manual callback handling for synchronized calls callback(); } } Regards. Alex ----- Original Message -----=20 From: "Dominique Stender" <sal...@ya...> To: <cpa...@li...> Sent: Monday, September 12, 2005 3:18 AM Subject: Re: [Cpaint-developers] Serializing form objects into PHP = arrays Hi, don't worry about credit. We give full credit even on pointing out bugs. You will be mentioned in the doc comments if we include your code into CPAINT. If you like, post the code in sf.net as patch, we'll see how we can integrate it into CPAINT 2.0.2 if possible. Thanks in advance, Dominique --- "S. Alexandre M. Lemaire" <sa...@sa...> wrote: > CPaint.. >=20 > I've readied a function which turns form objects > into PHP arrays through > CPaint. It works to my liking, and I'd be glad to > share, since this would > be to everyone's benefit. As a boon to your library > though, I trust that > credit would be given where due? All I ask is that > the > @author function comment remain intact if possible. >=20 > Here's an example print_r of what ends up at the PHP > function after the > cp.call, this was a form with two fields, email1, > email2, a checkbox > (unchecked, when checked it sends the value), and > lastly a select list which > was a multiple select, where mama and 123 were > selected. >=20 > array ( > 'email1' =3D> 'some field value', > 'email2' =3D> '', > 'checkbox' =3D> '0', > 'listval' =3D> > array ( > 0 =3D> 'mama', > 1 =3D> '123', > ), > 'Submit' =3D> 'Save', > ) >=20 > Cordially. > Alexandre >=20 >=20 >=20 > ------------------------------------------------------- > SF.Net email is Sponsored by the Better Software > Conference & EXPO > September 19-22, 2005 * San Francisco, CA * > Development Lifecycle Practices > Agile & Plan-Driven Development * Managing Projects > & Teams * Testing & QA > Security * Process Improvement & Measurement * > http://www.sqe.com/bsce5sf > _______________________________________________ > Cpaint-developers mailing list > Cpa...@li... > https://lists.sourceforge.net/lists/listinfo/cpaint-developers >=20 __________________________________=20 Yahoo! Mail - PC Magazine Editors' Choice 2005=20 http://mail.yahoo.com ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle = Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & = QA Security * Process Improvement & Measurement * = http://www.sqe.com/bsce5sf _______________________________________________ Cpaint-developers mailing list Cpa...@li... https://lists.sourceforge.net/lists/listinfo/cpaint-developers |
|
From: Dominique S. <sal...@ya...> - 2005-09-12 07:18:39
|
Hi, don't worry about credit. We give full credit even on pointing out bugs. You will be mentioned in the doc comments if we include your code into CPAINT. If you like, post the code in sf.net as patch, we'll see how we can integrate it into CPAINT 2.0.2 if possible. Thanks in advance, Dominique --- "S. Alexandre M. Lemaire" <sa...@sa...> wrote: > CPaint.. > > I've readied a function which turns form objects > into PHP arrays through > CPaint. It works to my liking, and I'd be glad to > share, since this would > be to everyone's benefit. As a boon to your library > though, I trust that > credit would be given where due? All I ask is that > the > @author function comment remain intact if possible. > > Here's an example print_r of what ends up at the PHP > function after the > cp.call, this was a form with two fields, email1, > email2, a checkbox > (unchecked, when checked it sends the value), and > lastly a select list which > was a multiple select, where mama and 123 were > selected. > > array ( > 'email1' => 'some field value', > 'email2' => '', > 'checkbox' => '0', > 'listval' => > array ( > 0 => 'mama', > 1 => '123', > ), > 'Submit' => 'Save', > ) > > Cordially. > Alexandre > > > > ------------------------------------------------------- > SF.Net email is Sponsored by the Better Software > Conference & EXPO > September 19-22, 2005 * San Francisco, CA * > Development Lifecycle Practices > Agile & Plan-Driven Development * Managing Projects > & Teams * Testing & QA > Security * Process Improvement & Measurement * > http://www.sqe.com/bsce5sf > _______________________________________________ > Cpaint-developers mailing list > Cpa...@li... > https://lists.sourceforge.net/lists/listinfo/cpaint-developers > __________________________________ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com |
|
From: John B. <jb...@uw...> - 2005-09-12 07:07:00
|
I'd be happy to give credit. Where can I find the function?
>>> sa...@sa... 2005/09/12 08:54:06 AM >>>
CPaint..
I've readied a function which turns form objects into PHP arrays
through
CPaint. It works to my liking, and I'd be glad to share, since this
would
be to everyone's benefit. As a boon to your library though, I trust
that
credit would be given where due? All I ask is that the
@author function comment remain intact if possible.
Here's an example print_r of what ends up at the PHP function after
the
cp.call, this was a form with two fields, email1, email2, a checkbox
(unchecked, when checked it sends the value), and lastly a select list
which
was a multiple select, where mama and 123 were selected.
array (
'email1' => 'some field value',
'email2' => '',
'checkbox' => '0',
'listval' =>
array (
0 => 'mama',
1 => '123',
),
'Submit' => 'Save',
)
Cordially.
Alexandre
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle
Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing &
QA
Security * Process Improvement & Measurement *
http://www.sqe.com/bsce5sf
_______________________________________________
Cpaint-developers mailing list
Cpa...@li...
https://lists.sourceforge.net/lists/listinfo/cpaint-developers
|