Welcome Guest, Not a member yet? Register   Sign In
  jQuery, Add / Delete elements without page refresh
Posted by: El Forum - 10-29-2007, 09:35 PM - Replies (16)

[eluser]Chris Newton[/eluser]
I've been trying to wrap my brain around this now for days, and I'm getting nowhere, so please bear with me...

I have admin page for my clients to add/edit/delete content to their site. I have a functioning form that currently has 2 input fields for files. I'd LIKE the client to be able to add / remove these input fields as needed based on the amount of files they need for a specific piece of content WITHOUT having to refresh the page using jQuery.

1. I need to delete an input field from a form without a page refresh AND make a call to the model to delete the corresponding data associated with that field.

I know how to get jQuery to remove or add an element to the page.
I know how to get Code Igniter to delete the data.

Using MVC, I"m having trouble wrapping my brain around how I'm supposed to call a jQuery function AND call a code igniter controller method without refreshing the page. I'm waiting for that "OH, I GET IT" moment, and unfortunately, it's just not coming.

Does anyone have any good jQuery / Code Igniter tutorials they could recommend? Any help you could provide at all would be greatly appreciated. I'm an established web guy trying to take his stuff to the next level and I see huge potential in both jQuery and Code Igniter if I can just get past the first operation...


  Dont uploading flv file
Posted by: El Forum - 10-29-2007, 08:22 PM - Replies (22)

[eluser]iniweb[/eluser]
$config['upload_path'] = 'uploads/images/';
$config['allowed_types'] = 'flv';
$config['max_size'] = '99920439';
$config['max_width'] = '1024';
$config['max_height'] = '768';

$this->load->library('upload', $config);

$this->upload->initialize($config);

$this->upload->do_upload('videofile');

Result: print_r($this->upload->data());

Array
(
[file_name] => habibi.flv
[file_type] => application/octet-stream
[file_path] => x:/home/yaba.by/www/uploads/images/
[full_path] => x:/home/yaba.by/www/uploads/images/habibi.flv
[raw_name] => habibi
[orig_name] =>
[file_ext] => .flv
[file_size] => 7382.4
[is_image] =>
[image_width] =>
[image_height] =>
[image_type] =>
[image_size_str] =>
)

wtf ):


  Save data in client's PC
Posted by: El Forum - 10-29-2007, 07:36 PM - Replies (1)

[eluser]cinewbie81[/eluser]
Hi, i want to save my data permanently in client's pc. How can i do it ?
I know it can be done using COOKIES, but given the fact that user delete the COOKIES quite frequently, i was wondering if there's any other way to do so ? Can it works using REGISTRY ? And what if they use LINUX OS ?


  creating dynamic parts in 3 column view
Posted by: El Forum - 10-29-2007, 04:50 PM - Replies (2)

[eluser]Scouser[/eluser]
I'm just starting with CodeIgniter and I was wondering what is the best way of dealing with dynamic parts which I want to use in my page.

Currently I use a 3 column page. With on the left side a menu, and depending on the state of the user it shows a number of menu items. In the middle I have some newsitems with 'read more' functionality. In the thirth column there some more dynamice text.

Formerly I used to call a function from within my webpage like

Code:
$menu->display();
but how should I do this now from CodeIgniter?


  user_guide minor errors
Posted by: El Forum - 10-29-2007, 04:41 PM - No Replies

[eluser]cfraz[/eluser]
{Pre-script}: Having just read through the user guide, I'm impressed with the documentation for CI - it stands head and shoulders above what most similar projects have. My apologies if this is the wrong place to post documentation related stuff.

In the Views section, the topic "Adding Dynamic Data to the View" has:

Quote:Note: You'll notice that in the example above we are using PHP's alternative syntax. If you are not familiar with it you can read about it here.

but it looks like it belongs to the next section, "Creating Loops."

Replace then with than:

CodeIgniter at a Glance section: "better performance then CodeIgniter"
Controllers section: "If your URI contains more then two segments"
Form Validation section: Rule Reference table for min_length, max_length,
URI Routing section: "you must use the dollar syntax rather then the double"
Input and Security Class section: "using the provided functions rather then fetching"
Unit Testing Class section: "test results formatted differently then the default"
Loader Class section: "unless you use something other then .php."
Hooks section: "use the same hook point with more then one script"
Text Helper section: "may be slightly more or less than what you specify"
XML Helper section: "Less then and greater than characters"
Database Library->Queries section: "use the above function rather then this one"
Database Library->Transactions section: "BDB table types rather then the more common"


  file_get_contents for remote files
Posted by: El Forum - 10-29-2007, 04:33 PM - Replies (3)

[eluser]sixpack434[/eluser]
I want to force download files on a remote server, is it possible to use file_get_contents with remote files so i can force_download e.g.

$data = file_get_contents("http://www.mysite.com/image/myphoto.jpg"); // Read the file's contents
$name = 'myphoto.jpg';

force_download($name, $data);


Thanks for your help


  EzSlide 0.1 Released! A PHP/Javascript Combo to Make Your Own Coverflow.
Posted by: El Forum - 10-29-2007, 04:02 PM - Replies (15)

[eluser]danoph[/eluser]
Hi again! I am releasing another open source application. This new application is called EzSlide. It's simple, one library, and mostly just for fun. EzSlide is a combination of PHP and Javascript that you can use to create cool slide reels, like Coverflow used on Apple's website and the famous Hotel Oxford website that practically utilizes mootools javascript library. Although I love using CodeIgniter and mootools in combination (the demo application was built using CI + mootools), you aren't bound to using either of the frameworks.

Like my last open source application, this project is totally open source, free, includes full documentation, an online demo, and downloadable sample application.

I am always open to suggestions and comments because this release (0.1) is definitely a work in progress. Also, many thanks to everyone who left feedback on EzAuth, my authorization library!

EzSlide Link: http://bizwidgets.biz/solutions/ezslide/


  What to put in a view?
Posted by: El Forum - 10-29-2007, 03:18 PM - Replies (4)

[eluser]lkagan[/eluser]
I'm just curious about how much logic, if any, you all place in your views. For example, I think it's OK to format a phone number in a view. If the number is stored in the DB as 9999999999, then writing a little logic to format that in the view seems fine to me.

At what point do you draw the line?

Thanks.


  hooks to extend your own application's core files
Posted by: El Forum - 10-29-2007, 03:10 PM - Replies (3)

[eluser]gerben[/eluser]
I saw that Codeigniter has built-in hooks that enable you to extend the core libraries, without having to hack into them. I'm looking for a way to do the same, but in this case, with my own controllers and views.

I use Modular Separation, which works great if you want to add whole new parts (pages) to your system, but it would be even better if one could automatically include parts of code in certain parts of the main application, once the module has been dropped into place. This is specifically handy if you develop open-source software (like in my case).

I don't know if that explanation is clear enough, so let me give an example:

Let's say I have an application with which users can create pages, and I've created a module that allows users to add a contact-form to every page. Of course I could then edit the code of my main-application so that it inserts the contact-form-module logic and views into every page. But it would be much easier for users (and coders) if these parts would be automatically added in the right places in the main app, through the use of hooks.

So here's my question:
What would be the best way to implement such a system of hooks? Any ideas or examples are very welcome!


  Benchmarks
Posted by: El Forum - 10-29-2007, 02:36 PM - Replies (14)

[eluser]feri_soft[/eluser]
Can someone provide me with some CI benchmarks? The only i did find was from ver. 1.5.1. I am using windows and is pretty hard to make a true test.
And btw. any ideas when 1.5.5 will come up. There was a thread from september saying there are enough fixes for a new release but nothing yet?


Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Latest Threads
TypeError when trying to ...
by InsiteFX
23 minutes ago
Webhooks and WebSockets
by InsiteFX
11 hours ago
Retaining search variable...
by pchriley
Today, 05:46 AM
Reading a session variabl...
by xanabobana
Today, 05:05 AM
Update to v4.5.1, same us...
by kenjis
Yesterday, 07:47 PM
Codeigniter 4 extend core...
by Semsion
Yesterday, 05:08 AM
v4.5.1 Bug Fix Released
by lokman
04-16-2024, 02:12 PM
problem with textarea
by Nitin Arora
04-16-2024, 05:07 AM
Showing pdf on browser
by aarefi
04-16-2024, 04:38 AM
[4.5.1] Disabling the deb...
by keto
04-16-2024, 02:43 AM

Forum Statistics
» Members: 84,482
» Latest member: bj88beer
» Forum threads: 77,558
» Forum posts: 375,892

Full Statistics

Search Forums

(Advanced Search)


Theme © iAndrew 2016 - Forum software by © MyBB