ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Ajax Framework (CJAX) for Codeigniter 2.x+

April 29, 2012 11:33am

Subscribe [24]
  • #31 / May 19, 2012 5:19am

    Ajaxboy

    243 posts

    @Distortion ,

    I am unable to reproduce the ‘CJAX: util. form’ alert issue, but the message signals the function ‘this._form’ as missing (which isn’t). Are you still having that issue?  If I could debug it I’d be able to tell more but just can’t reproduce it.  Have you tried again?  Some future changes to the core will prevent caching old versions to discard this as an issue.

    @Sanjay,

    Glad you got it working

  • #32 / May 25, 2012 7:37am

    Ajaxboy

    243 posts

    Version 5.0-Beta of the Ajax Framework will be released in the next few days. Lots of new positive changes and some exciting ones will be supported in this new release, In the mean time 4.2 is the preferred release and will probably be for a while until we get out of the beta.

  • #33 / May 29, 2012 10:19am

    Ajaxboy

    243 posts

    New Release 5.0-Beta

    > 100kb

     

    Changes From 4.2 to 5.0-Beta

    Extension of plugins API and plugins documentation

    There are so many new goodies for the plugin system that not many of them will get to be mentioned here.


    Ajax Upload Files

    This functionality was completely re-written, the new one is a lot more reliable than the previous, and can handle multiple uploads. Demo included in zip.


    20+ more features and Changes

    20+ more features and Changes, There are so many changes and new features that would make this post look messy and hard to read, so instead - just look at the ChangeLog.

    See Full ChangeLog:

    http://code.google.com/p/ajax-framework-for-codeigniter/source/browse/trunk/CHANGELOG.txt

    Download

    https://sourceforge.net/projects/cjax/files/CodeIgnater/

    Developer Sample Plugins

    Download

    https://sourceforge.net/projects/cjax/files/API/

    Because of the nature of beta software release - it is not encouraged to use this release for production environment. Though no known issues have been found. Be sure to post any issues if you find any.

     

  • #34 / May 29, 2012 4:48pm

    Ajaxboy

    243 posts

    Uploadify Jquery Integration, Upload Files with Flash

    CJAX Jquery.uploadify Plugin
    This plugin is an alternative if you already use Jquery, and jquery.uploadify.

    All dependencies are included. This PHP Plugin makes the configuration of uploadify a breeze.

    You may now make full use of the jquery.uploadify plugin, through cjax API, in PHP, Example included in demos zip.  This plugin is fully compatible and was tested uploading multiple files including 200MB+ files. All Settings are in the construction, meaning - you don’t have to change anything to make it work, everything is right here, you may customize these settings and use ANY other settings available in uploadify:

    Quick Samples

    This sample as it is, will upload ANY valid files, and will notify you of any errors -  such as directory permission and such.

    You’d use the exact same format (in PHP) that is used in jquery.uploadify plugin (JAVASCRIPT) options, that is what makes it easy to use, if you are already familiar with this plugin in jquery, even if you are not,  this sample speaks for itself:

    <?php
    
    $ajax =  ajax();
    
    //Paths are relative to uploadify plugin directory.
    $uploadify = $ajax->uploadify('.upload', array(
        'height' => 22,
        'checkExisting' => true, //or false
        'fileTypeDesc' => 'Images Files',
        'fileTypeExts' => '*.jpg;*.png;*.gif',
        'onUploadStart' => "function() {
            uploadify.loading('Uploading file…');
        }",
        'onUploadProgress' => "function(file, bytesUploaded, bytesTotal, totalBytesUploaded, totalBytesTotal) {
                uploadify.loading(totalBytesUploaded + ' bytes uploaded of ' + totalBytesTotal + ' bytes.');
            }",
        'onUploadSuccess' => "function(file, data, response) {
            uploadify.success('The file ' + file.name + ' was successfully uploaded.');
        }",
        'onUploadError' => "function() {
            uploadify.warning('An error occurred!');
        }",
        'onError' => "function() {
            uploadify.error('An error occurred!');
        }"
    ));
    
    //Example of overwritting options, you may overwrite any available options
    $uploadify->fileTypeDesc = 'Media Files';
    
    //Update extensions supported to upload
    $uploadify->fileTypeExts = '*.pdf;*.docx;*.doc;*.jpg;*.png;*.gif;*.zip';
    
    ##UPLOAD DIRECTORY
    //if you remove this line, it will  be by default uploaded to the plugin uploads/ directory . (if writable)
    $uploadify->target = "Directory/Where/To/Upload/Files";
    //replace the above line to the directory where you want the uploads to go

    Review plugin documentation

    http://www.uploadify.com/documentation/

    A working sample is included in the samples/demos zip

    Download the Plugin

    https://sourceforge.net/projects/cjax/files/Plugins/


    Hope that makes sense to anyone that might use the plugin

    In a side note,

    The Demos zip includes an *Updated*  Ajax Upload Files Example, which is built-in in the framework $ajax->upload() (see API documentation: http://code.google.com/p/ajax-framework-for-codeigniter/&#41;, the ajax file uploader allows you to upload any files and allows configuration for production usage, such as the usage of prefixes, suffixes in file names, etc.

     

  • #35 / May 31, 2012 6:48am

    Sanjay Sarvaiya

    94 posts

    Hi
    I have installed ajax-framework “Current Version 4.2” Its working like charm with most of browser but in ie7! nothing happen.
    Is there any way to work with ie7 ?

  • #36 / May 31, 2012 1:35pm

    Ajaxboy

    243 posts

    Hello Sanjay,

    Thanks for reporting this, will definitely look into it.

    Ajaxboy

  • #37 / Jun 01, 2012 12:46pm

    Ajaxboy

    243 posts

    New Release


    Download

    http://sourceforge.net/projects/cjax/files/CodeIgnater/


    5.0-Beta3

    * Fixed Ajax File Uploads fully working in IE7


    5.0-Beta2

    Changes From Beta to Bata2

    * Support for PATH INFO style URL

    eg: ajax.php/controller/function

    This adds to the already plenty of supported URLS in the list:
    ajax.php?$controller/$function
    ajax.php?controller=$controller&function;=$function
    ajax.php/$controller/$function

    With Mod-Rewrite:

    ajax/$controller/$function
    or:
    *Anything*/$controller/$function
    *Anything* - a word of your choosing by changing the word “ajax” in file .htaccess

    * Fixed issues with IE 7 not working
    All basic functionality and ajax operations are operational in IE7, but there might be other issues - see “known issues”.

    * Other small improvements in request handling, and dealing with controllers that have constructors.

    Known Issues:
    OveLay,overLayContent some formatting dis-perfections on IE7.
    Other small bugs/issues on IE7. Some demos may not work on IE7.
    Ajax Files Uploads have some issues

    See Full ChangeLog:
    http://code.google.com/p/ajax-framework-for-codeigniter/source/browse/trunk/CHANGELOG.txt

  • #38 / Jun 02, 2012 1:54pm

    Ajaxboy

    243 posts

    We’re moving from google code to Source Forge http://cjax.sourceforge.net/

    The next releases will likely be downloadable from a special sub-project for codeignater.

    -Ajaxboy

  • #39 / Jun 03, 2012 10:02am

    Kate Briggs

    1 posts

    Im really happy I started reading this today. Youve got a follower in me for sure!

  • #40 / Jun 03, 2012 11:19am

    Ajaxboy

    243 posts

    @Kate,

    Hello kate, thanks! 😊

    It is refreshing to see enthusiastic people providing positive feedback. 😊

    Be sure to sign up for news updates if you’d like to be in the loop or be notified of important updates or run into issues: https://lists.sourceforge.net/lists/listinfo/cjax-updates

    Any other constructive feedback is appreciated

    PS:

    For everyone that has downloaded the beta-release, it would be nice to hear if you have found any issues or how it’s working out.

    -Ajaxboy

  • #41 / Jun 05, 2012 7:27am

    Ajaxboy

    243 posts

    New Release

    AJAXFW_4CI_5.0-RC1
    Maintenance Release
    Jun 05, 2012

    * Fix minor things and improved minor things
    * Added the ability to control/change/set ANY element’s properties through Ajax.
    * Some docs were released
    * Moved to http://cjax.sourceforce.net
    * Support for all elements JavaScript properties in PHP
    See - http://cjax.sourceforge.net/docs/manipulating_container.php

    Download
    https://sourceforge.net/projects/cjax/files/CodeIgnater/

    Plugins
    https://sourceforge.net/projects/cjax/files/Plugins/

    ChangeLog
    http://cjax.svn.sourceforge.net/viewvc/cjax/CHANGELOG.txt?revision=1&view=markup

    This release takes us out of the beta release and all most changes in the beta turned out very stable. This new release Introduces some powerful functionality in regard to controlling HTML Elements through PHP.

  • #42 / Jun 11, 2012 10:23am

    Ajaxboy

    243 posts

    New Version Released
    5.0-RC2

    Some highlights:
    This release Fixes most of all IE issues. Extends the JavaScript Api - you now have access to ALL Js functions and Objects on the page. Adds speed to the overall framework - and to plugins, and provides options that can be used for easier development, it also adds an alternative to the current data processing for trouble shooting. This release also adds stability to the plugin system by proving the waitFor() function. Formatting fixes in IE and overlays, and other improvements, and other smallerer fixes, it also adds more options to the overlay.


    CJAX 5.0-RC2
    June 11, 2012

    Changes from RC1 TO RC2
    * Support to access for ALL JavaScript OBJECS and Functions
    With the release of RC1, we gave you the ability to access all element’s properties, now
    we are taking it a step further in RC2 -
    This is huge, and yes it means now you will have the possibility to access anything on the page through PHP.
    functions, methods, objects, window, document, element’s functions and methods, everything!.
    Please Note: This is a brand new feature, and there is not enough time to get all these functions documented,
    there is no assurance that all javascript functions will properly sync.
    All this is done dynamically and there is not a “function per function” convertion.
    See below instructions of patterns and ideas how to access the rest of the objects/functions/methods/properties/elements.
    Again this is a brand new feature and it may change in the future.

    See: http://cjax.sourceforge.net/docs/php2javascript/about.php
     
    * Plugins New method - $plugin->waitFor()
    Waits for a script with a specified filename to load before triggering plugin.
    This helps to keep a clock on the plugin’s execution which otherwise could fall into the asynchronous trap (loading and firing the
    before loading it’s dependencies - or not being able to reach functionality that may affect loading APIs or synchronous APIs might
    have fired before the plugin has completely loaded and executed, hense unable to affect). This function is a flexible alternative
    to keep an exact clock and has proven very dependable so far. All depends on the type and size of the plugin or whether you are experiencing
    asynchronous “clock” issues.

    * Performance: Plugins Speed, and everythsing else’s speed -
    This release is very important toward overall speed, and plugins speed, overcoming page load
    and shifting to Dom Load, now everything will load even faster. You will be able
    to notices the speed changes right away, for example in the uploadify plugin (download the new version of the plugin).
    These changes also affect the overall system, which will also trigger APIs faster.

    * Fallback: - Cjax currently depends on PHP SESSIONS to transmit APIs data over and across, some times some server might
    have issues with sessions, or from time to time session might seem not 100% reliable through the usage we’re giving it.
    Currently the other option to fallback is COOKIES, but might prove on the same road.
    We have added a new setting which you may specify as $ajax->fallback = true;. This will remove the dependency on PHP SESSIONS
    and will automatically print a small script tag on the page which will serve the purpose.
    This is not a replacement on how the system currently works, it’s just an alternative tool for these that might experience issues or to troubleshoot.

    * Config - while no configuration is required - we have added alternative options to allow you to easily debug, fallback, or other
    settings, through a config file. A new file in cjax/config.default.php is included, it allows you to configure these settings. You may
    also independently just call these settings like $ajax->debug = true or $ajax->fallback = true;. To make use of this config file
    you will need to rename it from config.default.php to config.php, this is to avoid it being overwritten in case you update/upgrade later.

    * Overlays now supports width property.

    * Overlay url now supports callback option - you may pass a callback within the settings
    and the requested contents will pass through the callback. Then you may manipulated before it is shown on the overlay.

    * Fixed some IE overlay formatting issues.
    Additionally, IE now plays nice with most of the demos, if not all.


    Download

    https://sourceforge.net/projects/cjax/files/CodeIgnater/

    Demos

    https://sourceforge.net/projects/cjax/files/Demos/


    Plugins

    https://sourceforge.net/projects/cjax/files/Plugins/

    Some links to the new stuff:

    http://cjax.sourceforge.net/docs/prepend_append.php

    http://cjax.sourceforge.net/docs/php2javascript/about.php

     

  • #43 / Jun 22, 2012 4:09am

    MonsterTKE

    27 posts

    Getting a blank page at /ajax.php?/test/test, followed the instructions, added the rewrite rule to my .htaccess file. as well as using the included one. Basically a bone stock codeigniter install, the only outside library is Tank-auth.

  • #44 / Jun 22, 2012 4:11am

    Ajaxboy

    243 posts

    Hello Monster,

    It appears you have an error in the url you are passing two different operators/marks within the URL. Try removing the extra slash (or the question mark) - either one. One of them it’s being interpreted for being part of the controller.

    Change

    from: ajax.php?/test/test

    to: ajax.php?test/test

    or: ajax.php/test/test

    please try that for me

    -cj

  • #45 / Jun 22, 2012 7:52am

    XatroX

    7 posts

    I get error like below. . .
    how can i fix it?

    Warning: defined() expects exactly 1 parameter, 2 given in C:\xampp\htdocs\inventory\ajax.php on line 34

    *sorry if my english so bad 😊

     

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases