Adding extra field to content items?

Your code modifications and patches you want to share with others.
Locked
Zanjabil
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Fri Aug 25, 2006 9:51 am

Adding extra field to content items?

Post by Zanjabil » Thu Sep 07, 2006 11:12 am

Hi,

I'm not sure if this is the right category but I can't figure out where else to put it :)

I want to add an extra field to all content items where I can put a URL when adding a new item.

If anyone can help me, I'd greatly appreciate it or at least point me in the right direction!

Thankyou.

mattr2110
Joomla! Explorer
Joomla! Explorer
Posts: 273
Joined: Thu Feb 16, 2006 2:42 am

Re: Adding extra field to content items?

Post by mattr2110 » Thu Sep 14, 2006 9:28 pm

That would be cool

pubdown
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Tue Oct 31, 2006 6:36 am
Contact:

Re: Adding extra field to content items?

Post by pubdown » Tue Oct 31, 2006 7:03 am

I am looking for that also.
Download the softwares you needed at
http://www.nj.com.ru

User avatar
phlux0r
Joomla! Guru
Joomla! Guru
Posts: 812
Joined: Thu Feb 09, 2006 1:41 am
Location: Auckland, NZ
Contact:

Re: Adding extra field to content items?

Post by phlux0r » Fri Nov 17, 2006 10:54 pm

The simplest way to add a new simple field to a content item is to add a parameter to the content.xml file. That parameter will automatically appear in the parameters tab when you edit a content item. It also gets saved and retrieved automatically.

Then you would only need to hack the front end content item display code to handle the display of your custom parameter field.

Anything more complex would require either adding a database field to the content table or creating another table holding your custom fields and linking to the content table via the content id. Then you'd need to add custom back-end code to handle the new stuff and hack the front end code as well.

grafixart
Joomla! Apprentice
Joomla! Apprentice
Posts: 28
Joined: Tue Feb 13, 2007 10:42 pm

Re: Adding extra field to content items?

Post by grafixart » Mon May 07, 2007 8:15 am

What do you write in the front end to display the text field?

kadded
Joomla! Explorer
Joomla! Explorer
Posts: 306
Joined: Sun Mar 23, 2008 9:54 pm

Re: Adding extra field to content items?

Post by kadded » Wed Jun 18, 2008 1:09 am

If it is not urgent you can always wait for this component to be finished:
http://developer.joomla.org/gsoc2008/cu ... ained.html.

Otherwise, if you feel like buying components you can always try Joomsuite Content. I have no experience with joomsuite, but it sure looks good.
http://extensions.joomla.org/component/ ... Itemid,35/

I would prefer a component over hacking the xml file, since I need a flexible (read: various templates) content field manager.

Hope this helps.

kadded
Joomla! Explorer
Joomla! Explorer
Posts: 306
Joined: Sun Mar 23, 2008 9:54 pm

Re: Adding extra field to content items?

Post by kadded » Sat Aug 16, 2008 12:33 am

One of those components just released its beta. Check its progress on this forum topic:
http://forum.joomla.org/viewtopic.php?f ... &sk=t&sd=a

User avatar
mojito
Joomla! Guru
Joomla! Guru
Posts: 703
Joined: Wed Sep 07, 2005 10:18 pm
Location: London
Contact:

Re: Adding extra field to content items?

Post by mojito » Wed Jun 03, 2009 2:37 pm

phlux0r wrote:The simplest way to add a new simple field to a content item is to add a parameter to the content.xml file. That parameter will automatically appear in the parameters tab when you edit a content item. It also gets saved and retrieved automatically.

Then you would only need to hack the front end content item display code to handle the display of your custom parameter field.

Anything more complex would require either adding a database field to the content table or creating another table holding your custom fields and linking to the content table via the content id. Then you'd need to add custom back-end code to handle the new stuff and hack the front end code as well.

Where can I find content.xml I did a search and it didnt come up! Thanks
Check out the 'bad toilet' online !

tobiasn
Joomla! Apprentice
Joomla! Apprentice
Posts: 27
Joined: Tue Feb 27, 2007 6:34 pm

Re: Adding extra field to content items?

Post by tobiasn » Wed Jun 17, 2009 7:42 pm

Hi, I wrote a bit about this here: http://forum.joomla.org/viewtopic.php?f=178&t=320017

The first and last post should give you enough examples to make some headway. Good luck!


Locked

Return to “Core Hacks and Patches”