Giter Club home page Giter Club logo

image-crud's Introduction

Image CRUD

image-crud's People

Contributors

arisdario avatar bbosternak avatar carlospinedat avatar emir avatar fido-hh avatar itguy614 avatar kaabi avatar scoumbourdis avatar willmendesneto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

image-crud's Issues

Allow different primary keys than "id"

on libraries/image-crud.php on line 234:

replace:

$results[$num]->delete_url = $this->_get_delete_url($row->id);

by:
$results[$num]->delete_url = $this->_get_delete_url($row->{$this->primary_key});

not working on HMVC

I cannot make it work on HMVC codeigniter. I'm not pro, but cannot make it work.

[bug] loading images as demand

can be possible to the images loading as demand when browser go down and reveals each one?

this on way to process a directory with huge amount of inmages...

Having an issue with set_relation_field()

When I try to use this function my code fails. After banging my head against the wall for days i decided to try to use Example3() and it fails in the same way. I am using the Community version of grocery crud, if that at all matters. And I am on Linux. All the other functions run fine as long as I don't set_relation_field. There seems to be a problem in the logic of getState(). There is a large ifelse ladder, and if set_relation_field is set, the logic just fall right through to the bottom. Anyone else run into this problem? Any type of work around?

feature : where ()

is there possible on future update there will be filter for image using where?
thanks

not working in sub folders

hi John ,

small issue . when I but the images_examples.php in a folder inside controllers its not working

so the path is : proFolder/subFolder/images_examples/example1

and I get the error : Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/proFolder/index.php/images_examples/example1/ajax_list

its seem he dose not recognized the sub folder !

I try that in pure image-crud and pure CI .and the same result .

I hope you can take a look at this

thank you

How to specify the database to use?

I am using two databases; a local copy of mysql which works great with GC. I plan to use AWS' RDS Postgresql for the images for use with Image crud. I have opened two databases using:
$DB1 = $this->load->database('default', TRUE);
$DB2 = $this->load->database('postgres', TRUE);
Default is using the mysql and that works fine. How do I tell Image Crud to use $DB2 instead?

not working on internet explorer

not workin on IE10 with error:
[FineUploader] responseText =

A PHP Error was encountered

Severity: Notice

Message: Undefined offset: 0

Filename: libraries/image_crud.php

Line Number: 296

{"success":false} [FineUploader] Error when attempting to parse xhr response text (SyntaxError: Invalid character)

as for IE 9 and earlier it simply does not show.

callbacks

callback_after_upload
callback_before_upload

example 3 and set_relation_field not working.

The problem is in this line:

->set_relation_field('category_id')

If I comment them the example works but not as expected, of course.

I think this is exactly what I needed so I could upload several images to different galleries using the same table, right ?

Generate thumbnails for existing images

on libraries/image_crud.php, before row 234 add this:

        if (!file_exists($this->image_path.'/'.$this->thumbnail_prefix.$row->{$this->url_field})) {
            $this->_create_thumbnail($this->image_path.'/'.$row->{$this->url_field}, $this->image_path.'/'.$this->thumbnail_prefix.$row->{$this->url_field});
        }

fixed height width of uploading image validation issue

i am trying to add fixed height width image validation in image crud class but not succeded in it. tried below but not worked. image not uploaded but database entry done.

class ImageUploadHandler
{

private function has_error($uploaded_file, $file, $error) {

if ($uploaded_file && is_uploaded_file($uploaded_file)) {
$file_size = filesize($uploaded_file);

list($width, $height, $type, $attr) = getimagesize($uploaded_file);

if($width != 600 || $height != 800){

return 'maxFileSize';

}

    } else {
        $file_size = $_SERVER['CONTENT_LENGTH'];
    }

}

Problem with uploads path

Hi, there.

I have two installations of CI with Imagecrud in the same server. The controller is in a subfolder called 'cms' inside 'controllers'. When I try to upload images in development install all is right. I get this line in console:

POST http://vaello.franciscobosch.es/index.php/cms/ima...ilesize=72225&qqfile=8003462-light-bulb-idea.jpg 200 OK 463ms

But when I try to upload images in production site I get an upload failed message, with the following line in console:

POST http://vaello.es/index.php/images/index/upload_fi...5&qqtotalfilesize=159608&qqfile=52210color12.jpg

404 Not Found
179ms

As you can see the difference is that the first one is taking the right pathwith the /cms/ folder after index.php, but not the second one.

Any help will be appreciated.

Best regards.

set_image_path not working as expected

Hi!
When I set image path like this:
$image_crud->set_image_path('../uploads/galleries/'.$gal_name);
all images are uploaded to "../uploads/galleries" path.
I have created the directory where I would like to upload the files.

In image_crud.php on line 523:
$file_name = $this->_upload_file( $this->image_path);

When I check content of $this->image_path I get only ../uploads/gallery/

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.