# Gallery extension - nested galleries and image editing

**URL:** <https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229>\
**Category:** Radiant CMS\
**Created:** [June 7, 2007, 6:27pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229 "2007-06-07T18:27:58Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 7, 2007, 6:27pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/1 "2007-06-07T18:27:58Z")

</div>

Hi all, I’ve just implemented 2 new features in the Gallery extension.

The first one is that now it’s possible to create nested galleries.  
So a Gallery could be a container for other galleries.

The second feature is the image editing page. It’s only a super beta  
version ( 😛 ), but you can crop an image working with the original  
file.  
I used the cropper library that someone mentioned in the last days  
here. Thanx for the advice 🙂  
In the next days I will release a semi-stable version… and then a  
will add some other functionalities in the image editing page.  
Let me know what you think about it!

[http://darcs.bigchieflabs.com/radiant/extensions/gallery/rdoc/](http://darcs.bigchieflabs.com/radiant/extensions/gallery/rdoc/)

Thank you guys!

* * *

Andrea F.

removed\_email\_address@domain.invalid  
[http://bigchieflabs.com/blog/](http://bigchieflabs.com/blog/)  
[http://think.bigchief.it](http://think.bigchief.it)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 7, 2007, 8:04pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/2 "2007-06-07T20:04:13Z")

</div>

Hooray for cropping!

Thanks for taking the time to implement this, Andrea.

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 7, 2007, 8:08pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/3 "2007-06-07T20:08:14Z")

</div>

Just curious:

What would be the best way to upgrade my Gallery installation to this  
latest version? I installed the original via SVN…

should I just run

# svn [http://darcs.bigchieflabs.com/radiant/extensions/gallery/](http://darcs.bigchieflabs.com/radiant/extensions/gallery/)

… and will I need to rake anything afterwards to get the new  
changes running?

Thanks,  
\*dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 7, 2007, 8:48pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/4 "2007-06-07T20:48:20Z")

</div>

Il giorno 07/giu/07, alle ore 20:06, d n ha scritto:

> Just curious:
> 
> What would be the best way to upgrade my Gallery installation to this  
> latest version? I installed the original via SVN…
> 
> should I just run
> 
> # svn [http://darcs.bigchieflabs.com/radiant/extensions/gallery/](http://darcs.bigchieflabs.com/radiant/extensions/gallery/)

I use darcs[1] instead of subversion…so you should type:

darcs get [http://darcs.bigchieflabs.com/radiant/extensions/gallery](http://darcs.bigchieflabs.com/radiant/extensions/gallery)

to check out the repository…or use the “pull” command to update it.  
Anyway you can download the development archive here:

[http://darcs.bigchieflabs.com/radiant/extensions/gallery/gallery.tar.gz](http://darcs.bigchieflabs.com/radiant/extensions/gallery/gallery.tar.gz)

My server on site5 is now down ☹ try in a few minutes…or hours ☹ :(…

> … and will I need to rake anything afterwards to get the new  
> changes running?

You have to run:

rake radiant:extensions:gallery:install

…that runs the migration and updates the js/css files…

[1] [http://www.abridgegame.org/darcs/](http://www.abridgegame.org/darcs/)

> Thanks,  
> \*dan

* * *

Andrea F.

removed\_email\_address@domain.invalid  
[http://bigchieflabs.com/blog/](http://bigchieflabs.com/blog/)  
[http://think.bigchief.it](http://think.bigchief.it)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 8, 2007, 7:34pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/5 "2007-06-08T19:34:53Z")

</div>

Hi Andrea,

I’m getting an Apache application error (500) when I try to crop an  
image…

I know you’re working on a stable version, just wanted to let you know.

Thanks,  
\*dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 8, 2007, 7:55pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/6 "2007-06-08T19:55:55Z")

</div>

Il giorno 08/giu/07, alle ore 19:33, d n ha scritto:

> Hi Andrea,
> 
> I’m getting an Apache application error (500) when I try to crop an  
> image…
> 
> I know you’re working on a stable version, just wanted to let you  
> know.
> 
> Thanks,  
> \*dan

Thank you…can you read the errors file to know what is the error?

* * *

Andrea F.

removed\_email\_address@domain.invalid  
[http://bigchieflabs.com/blog/](http://bigchieflabs.com/blog/)  
[http://think.bigchief.it](http://think.bigchief.it)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 5:02pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/7 "2007-06-18T17:02:25Z")

</div>

> You have to run:
> 
> rake radiant:extensions:gallery:install
> 
> …that runs the migration and updates the js/css files…

I get an error when i run rake for this (on my site5 server):

-bash-3.00$ rake radiant:extensions:gallery:install  
/usr/bin/rake:17:Warning: require\_gem is obsolete. Use gem instead.  
(in /home/danorine/radiant)  
rake aborted!  
Access denied for user ‘root’@‘localhost’ (using password: NO)

(See full trace by running task with --trace)  
-bash-3.00$

Any idea what i’m doing wrong?

Thanks,  
Dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 8, 2007, 8:10pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/8 "2007-06-08T20:10:58Z")

</div>

The logfile says:

NoMethodError (undefined method `items’ for nil:NilClass)

I can send you the complete details off-list if it would help.

\*Dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 6:29pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/9 "2007-06-18T18:29:36Z")

</div>

Il giorno 18/giu/07, alle ore 17:02, Dan Simpson ha scritto:

> -bash-3.00$ rake radiant:extensions:gallery:install  
> /usr/bin/rake:17:Warning: require\_gem is obsolete. Use gem instead.  
> (in /home/danorine/radiant)  
> rake aborted!

Try this:

rake production radiant:extensions:gallery:install

…and let me know! 😛

> –  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
> 
> * * *
> 
> Radiant mailing list  
> Post: removed\_email\_address@domain.invalid  
> Search: [http://radiantcms.org/mailing-list/search/](http://radiantcms.org/mailing-list/search/)  
> Site: [http://lists.radiantcms.org/mailman/listinfo/radiant](http://lists.radiantcms.org/mailman/listinfo/radiant)

* * *

Andrea F.

removed\_email\_address@domain.invalid  
[http://bigchieflabs.com/blog/](http://bigchieflabs.com/blog/)  
[http://think.bigchief.it](http://think.bigchief.it)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 6:40pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/10 "2007-06-18T18:40:37Z")

</div>

Thanks for that, Andrea! I wasn’t aware that task could be specified  
to affect the production environment.

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 6:03pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/11 "2007-06-18T18:03:32Z")

</div>

Dan,

Make sure you have a development database setup, and have defined  
it’s parameters in the database.yml file (radiant/public/config).

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 7:06pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/12 "2007-06-18T19:06:55Z")

</div>

d n wrote:

> Dan,
> 
> Make sure you have a development database setup, and have defined  
> it’s parameters in the database.yml file (radiant/public/config).

Excuse me. I forgot to mention that this was right on the money. I had  
only set up parameters for the production database. That worked fine  
until i tried to install this extension.

Thanks!  
Dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 9:05pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/13 "2007-06-18T21:05:49Z")

</div>

Dan Simpson wrote:

> The site appears fine until i try to go to the admin pages, at which  
> point i get this error message in my browser:
> 
> Application error (Apache)
> 
> Change this error message for exceptions thrown outside of an action  
> (like in Dispatcher setups or broken Ruby code) in public/500.html.

Ok. i found this:

skill -9 -u username -c dispatch.fcgi

to restart the fcgi process. It works! (by which i mean it doesn’t  
raise an error).

Now, if i can only figure out how to make the gallery work…

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 18, 2007, 6:59pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/14 "2007-06-18T18:59:52Z")

</div>

Andrea F. wrote:

> Try this:
> 
> rake production radiant:extensions:gallery:install
> 
> …and let me know! 😛

It seems to have worked! But then i got a different error… Here’s  
the terminal output:

# -bash-3.00$ rake production radiant:extensions:gallery:install /usr/bin/rake:17:Warning: require\_gem is obsolete. Use gem instead. (in /home/danorine/radiant) == CreateGalleryExtensionSchema: migrating

# – create\_table(:galleries) → 0.0358s – create\_table(:gallery\_items) → 0.0263s == CreateGalleryExtensionSchema: migrated (0.0812s)

# == AddHiddenColumn: migrating

# – add\_column(:galleries, :hidden, :boolean, {:null=\>false, :default=\>false}) → 0.0599s == AddHiddenColumn: migrated (0.0604s)

# == AddNameToGalleryItems: migrating

# – add\_column(:gallery\_items, :name, :string) → 0.0141s == AddNameToGalleryItems: migrated (0.0142s)

# == ChangeItemsNameTypeToText: migrating

# – change\_column(:gallery\_items, :description, :text) → 0.0135s == ChangeItemsNameTypeToText: migrated (0.0137s)

# == AddParentIdToGallery: migrating

# – add\_column(:galleries, :parent\_id, :integer) → 0.0160s == AddParentIdToGallery: migrated (0.0161s)

cp -r  
/home/danorine/radiant/config/…/vendor/extensions/gallery/lib/tasks/…/…/public  
/home/danorine/radiant/config/…  
-bash-3.00$ rake production radiant:extensions:gallery:example  
/usr/bin/rake:17:Warning: require\_gem is obsolete. Use gem instead.  
(in /home/danorine/radiant)  
Gallery page created. In order for lightbox to work you have to include  
this Radiant tag in your layout HEAD section:  
\<r:gallery:lightbox\_stuff /\>  
Check it out at [http://yoursite/gallery-example](http://yoursite/gallery-example)  
-bash-3.00$

The site appears fine until i try to go to the admin pages, at which  
point i get this error message in my browser:

Application error (Apache)

Change this error message for exceptions thrown outside of an action  
(like in Dispatcher setups or broken Ruby code) in public/500.html.

You can see it for yourself at [404 - PAGE NOT FOUND](http://radiant.danorine.net/admin/pages).

Thanks for any assistance you can give me!

Peace,  
Dan

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 7:08pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/15 "2007-06-19T19:08:20Z")

</div>

A couple of weeks ago I posted a patch to add Gibberish support to  
Radiant. It was actually quite easy. I have a post over on the dev  
list at Google groups, but that one is _very_ slow.

Has anyone (especially from the core team) had a look? I still feel  
strongly that we should get going on this, it will only get harder.  
And Gibberish is great, and makes everything very easy to maintain.

Take a look Patch Number 504, I think. Unfortunately the site is  
down, so I can’t check…

Keith B.  
Tel: +49-7731-79838380  
removed\_email\_address@domain.invalid  
[http://keithbingman.com](http://keithbingman.com)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 7:20pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/16 "2007-06-19T19:20:22Z")

</div>

Thanks, just curious, as I had heard nothing.

I haven’t done the Textile and Markdown plugins, which mainly means  
the reference. What are thoughts on this? Do people think it is  
required? Nice, of course, but required?

Keith B.  
Tel: +49-7731-79838380  
removed\_email\_address@domain.invalid  
[http://keithbingman.com](http://keithbingman.com)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 8:31pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/17 "2007-06-19T20:31:34Z")

</div>

Not sure if this is the kind of thing you were looking for but for our  
CMS we’ve created a helper to drop in a Textile editor for text areas.

[http://slateinfo.blogs.wvu.edu/plugins/textile\_editor\_helper](http://slateinfo.blogs.wvu.edu/plugins/textile_editor_helper)

On 6/19/07, Keith B. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > > 
> > 
> > * * *

–

Proud supporter of DC United

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 8:42pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/18 "2007-06-19T20:42:36Z")

</div>

I was merely referring to the documentation that is included in  
Radiant for both Textile and Markdown. I am trying to translate the  
Radiant interface, or more correctly, make it translatable. I was  
just wondering how far I should go…

Keith B.  
Tel: +49-7731-79838380  
removed\_email\_address@domain.invalid  
[http://keithbingman.com](http://keithbingman.com)

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 9:00pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/19 "2007-06-19T21:00:38Z")

</div>

Keith B. wrote:

> Thanks, just curious, as I had heard nothing.

Sorry about that Keith. I meant to respond but I haven’t had a chance to  
look at it yet. I am very excited about it and am thrilled that you have  
taken on the challenge.

> I haven’t done the Textile and Markdown plugins, which mainly means  
> the reference. What are thoughts on this? Do people think it is  
> required? Nice, of course, but required?

We need a standard way for extensions to be internationalized. They will  
need their own translation files, of course.

–  
John

---

<div class="post-metadata">

**Author:** ![gendag](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/f04885/32.png) [@gendag](https://www.ruby-forum.com/u/gendag)\
**Post date:** [June 19, 2007, 10:40pm UTC](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229/20 "2007-06-19T22:40:54Z")

</div>

As I said, this isn’t what I was talking about, but this looks very  
interesting, as does Slate. I will definitely give it a whirl as soon  
as I can.

Keith B.

[Next page](https://www.ruby-forum.com/t/gallery-extension-nested-galleries-and-image-editing/106229.md?page=2)
