AdvancedContent

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Locked

What do you think: Use the image uploads dir or just the uploads dir for {content_image}?

image uploads dir
23
68%
uploads dir
8
24%
don't care
3
9%
 
Total votes: 34

Jeff
Power Poster
Power Poster
Posts: 961
Joined: Mon Jan 21, 2008 5:51 pm
Location: MI

Re: improve the content type "content"

Post by Jeff »

To release a module all you do is upload an XML file (for ModuleManager) or a tar.gz file in the admin area of the forge.
JeremyBASS

Re: improve the content type "content"

Post by JeremyBASS »

Hmmm... heck tell ya what... I can start it if you'd like to work together on this... I think I have an idea for how to handle this as a module and  I could get the base together... but IMHO I think that dropping the in-template implementation altogether may not be a good thing, but I have some solutions for that... I have most of my mods at a stable stand point that I could get this rolling... Email me if you wish and let’s get rolling if you wish :D
NaN

Re: improve the content type "content"

Post by NaN »

ajprog wrote: To release a module all you do is upload an XML file (for ModuleManager) or a tar.gz file in the admin area of the forge.
Thanks, but I know how to release a module  ;D
I just need to think about the programming stuff etc ;)
MattAntWest
New Member
New Member
Posts: 3
Joined: Sun Mar 07, 2010 9:38 pm

Re: improve the content type "content"

Post by MattAntWest »

Hi guys I'm trying to get this to work with the content_image tag. Here's what I have at the minute.

Code: Select all

{content_image block='image1' dir='images/:::title:::' class='image' label='Image 1'}
I've tried doing it using the capture tag as well.

Code: Select all

{capture assign='dir'}'images/{title}'{/capture}
{content_image block='image1' dir='$dir' class='image' label='Image 1'}
Unfortunately neither of these (or the other million variations I've tried) work!

Basically I'm trying to import the title of the page (which will be a name) into the directory parameter for the content_image tag. I am creating a website which has a number of different pages for displaying info about members of the organisation and each member has a folder with the same name as the {title} in which their pictures are stored.

I suppose that I could create a different template for each different member but this would take ages and would be a pain so I am going to try this first.

If all else fails I may try creating another field which holds the content_image code and try and hide this from the user ( so they don't delete it by accident when they try to edit their information.

If anyone can help me sort my problem it would be awesome.
JeremyBASS

Re: improve the content type "content"

Post by JeremyBASS »

it'd be (if I put smarty on this.. Im not sure)

{content type=image block='image1' dir='images/:::title:::' class='image' label='Image 1'}
User avatar
robsta
Forum Members
Forum Members
Posts: 131
Joined: Thu Oct 20, 2005 11:39 pm
Location: Wellington

content2 and 1.6.7

Post by robsta »

Hi JeremyBass

just upgraded and my content2 has gone... I can downgrade but is there a fix?

Thanx

R
Last edited by robsta on Wed Mar 10, 2010 10:45 am, edited 1 time in total.
JeremyBASS

Re: improve the content type "content"

Post by JeremyBASS »

hmm.. I never use {content2 ...}

I use something like

{content type=image block='image1' dir='images/:::title:::' class='image' label='Image 1'}

I'd start there.. but I can say this for sure.. 100%... it does work with 1.6.7.. hope this helps.. -Jeremy
NaN

Re: improve the content type "content"

Post by NaN »

I upgraded too but had no problems.
As i know nothing has changed to the contenttypes in the last CMSms update (1.6.7) so there should be no problem with upgrading.
What do you mean with "has gone"?
Are there any errormessages?
Did you try to set config['debug']=true in config php?
User avatar
robsta
Forum Members
Forum Members
Posts: 131
Joined: Thu Oct 20, 2005 11:39 pm
Location: Wellington

solved upgrade problem

Post by robsta »

NaN, JeremyBass

I've fixed it pebkac on my part I had mismatched plugin and include files... any chance we could pop this i forge?

Cheers Rob
hexdj
Power Poster
Power Poster
Posts: 415
Joined: Sat Mar 24, 2007 8:28 am

Re: improve the content type "content"

Post by hexdj »

I would also like to see this in forge. Although it really SHOULD be part of Core

Wishful thinking  ;)
NaN

Re: improve the content type "content"

Post by NaN »

Just created the first release in forge: http://dev.cmsmadesimple.org/projects/content2

This release also contains all mods of JeremyBass so far and some new features like redirect page if page is only visible to frontend users and user is not logged in or does not belong to the specified group. Content can also just be hidden without any action. You can even protect only certain content blocks or the whole page content. The page properties feu access and redirect page can be inherited by parent pages (if of content type "Content (Extended)).
Inheritance, feu access and redirecting only works in conjunction with the plugin {content2}.

Fixed a small bug with the option "Disable WYSIWYG editor on this page (regardless of template or user settings)" (i hope at least).

Please report any kind of feedback.

Cheers.
NaN

Re: improve the content type "content"

Post by NaN »

JeremyBASS wrote:
{content type=image block='image1' dir='images/:::title:::' class='image' label='Image 1'}
Just a note...
Notice that this won't work properly if the page is created since there is no title at this time.
So the used directory will be just "images/".
User avatar
NikNak
Forum Members
Forum Members
Posts: 183
Joined: Fri Oct 02, 2009 2:28 pm

Re: improve the content type "content"

Post by NikNak »

Hi NaN

I've just tried this and get:
Fatal error: Call to undefined method Content2::GetBackendSection() in /home/odchostc/public_html/sgtestv4/lib/classes/contenttypes/Content2.inc.php on line 44

Is it now important to use {content2 ...}  rather than {content ...}  ?

All was fine before using the files downloaded from earlier in this post.
Using cmsms 1.7

Thanks

Nik
NaN

Re: improve the content type "content"

Post by NaN »

*lol*

Sorry, wrong copy.
I uploaded a buggy version and deleted the working one :D
It really was tooo late yesterday.
This will be fixed soon.
(Is already fixed in SVN)

Just remove in Content2.inc.php around line 67 $this->GetBackendSection(); - this was just an experiment that does not work yet.

No you don't need the {content2} Plugin to use the content type at all.
Only if you want to use the frontend access function you need to use the modified plugin.
Last edited by NaN on Sat Mar 27, 2010 5:01 pm, edited 1 time in total.
mccord42
Forum Members
Forum Members
Posts: 23
Joined: Thu Jun 22, 2006 12:07 am

Re: improve the content type "content"

Post by mccord42 »

I just tried installing this from the files listed above, but I am getting an error about line 402 having an extra ) in it.

This is the line 402 from the file------>   if( !empty($blockInfo['label']) )

once I remove the extra ) i am now getting the following error:
Parse error: syntax error, unexpected T_VARIABLE in /var/www/dev/templates/lib/classes/contenttypes/Content2.inc.php on line 340

Any ideas?

Thanks for any help.
Locked

Return to “Modules/Add-Ons”