Ajax Framework (CJAX) for Codeigniter 2.x+ |
[eluser]Ajaxboy[/eluser]
Yes, with CI hooks, you may create a custom function and load the file from there. http://ellislab.com/codeigniter/user-gui...hooks.html
[eluser]MonsterTKE[/eluser]
[quote author="Ajaxboy" date="1340623025"]Yes, with CI hooks, you may create a custom function and load the file from there. http://ellislab.com/codeigniter/user-gui...hooks.html[/quote] Edit, I can just load it in the construct. Thanks again for your help, and thanks for making this awesome library.
[eluser]Ajaxboy[/eluser]
It should work. 1. Create a file: application/hooks/preload.php add a class: preload. Code: class preload { Add hook in application/config/hooks.php Code: $hook['pre_controller'][] = array(
[eluser]MonsterTKE[/eluser]
Edit* Hopefully this thread will be helpful for anyone using this library. It seems with any programming the simplest thing will trip you up. In this case adding the script to the head by hand bas the right way to go, it is working perfectly. It was simply choking on the relative path to the script. Thanks again.
[eluser]fliu[/eluser]
Hi, 1. the upload file function, take the "$_SERVER['DOCUMENT_ROOT']" as default location, how do we change it? it does not take my "baser_url()./myfolder", getting warning message "directory does not exist". 2. after completing the uploading the files, is there a way to display just uploaded file name on the same view page? thank you Frank
[eluser]Ajaxboy[/eluser]
Hello Frank, Appears you are talking about the ajax upload functionality or the uploadify plugin, just replace "“$_SERVER[‘DOCUMENT_ROOT’]" for baser_url()./myfolder, and that should be all... make sure "baser_url()" is a local server directory and not a url.
[eluser]Ajaxboy[/eluser]
@MonsterTKE I believe this is the functionality you were after (with better definition): Sample: http://cjax.sourceforge.net/examples/ove...dation.php This will be fully supported in the upcoming RC3.
[eluser]Ajaxboy[/eluser]
<h2>Version 5.0-RC3 has been released</h2> This release has been tested with the latest CI 2.1.1 (and 2.1.0), no issues have been found. Release Date: Jun/30/2012 Download https://sourceforge.net/projects/cjax/fi...deIgnater/ Download Demos for RC3 https://sourceforge.net/projects/cjax/files/Demos/ Changes from RC2 to RC3: * Fixed some small bugs introduced in RC2 * Ajax Upload functionality was converted into a stand alone plugin "uploader" While within the framework API this functionality fits well, this ajax functionality is constantly improved and updated so as a plugin gives more flexiblity to release and update faster. * New Plugin Autoload functions Gives the autoload ability to plugins. So plugins can auto-execute themselves or run stuff without requiring for $ajax->[pluging]() to be initiated. * More optional settings introduced for further flexiblity. * Auth hook introduced If you require to validate user session or validate any user session validity you may use this setting to deny or approve an ajax request. * Routing hook introduced You may now route ajax request to other sections of your application, for example if your application has a built addon or plugin system and you simply want to route ajax to other sections of the application, you may route these requests with built-in support. * Include hook introduced If you need to include dependencies in the ajax framework while in ajax request mode, there is now a section where you can reference these. * Caching is now supported for page load commands * New 'Overlay and client-side' validation sample released * Replaced the "prevent" functionality to favor callbacks functionality. View Full ChangeLog: http://cjax.svn.sourceforge.net/viewvc/c...iew=markup Note: You will also need to upgrade ajax plugins you may be using to take advantage of the latest features, the older plugin are deprecated so be sure to get the new ones.
[eluser]somenet[/eluser]
Please can u demostrate complete configuration cjax and codeigniter with example.I can configure cjax with your docs guide but i can't get any respose while creating controller inside application/controller/filename. <?php class controller_test extends CI_Controller { function test() { $test_array = array( 1 => 'test1', 2 => 'test2', 3 => 'test3' ); return $test_array; } } ?> Thanks for sharing framework. |
Welcome Guest, Not a member yet? Register Sign In |