Keyword

Advanced Search

Search Results (Searched for: extra field order)

  • Michael Tull
  • Michael Tull's Avatar
14 Mar 2011 16:07

Multiple Catagory display with multiple templates...

Category: English K2 Community

 

 

Ok, so here is what I am looking to do, and I am hoping that someome might be abel to point me in the right direction.

 

I have two ( at this stage ) Catagories - Events and News. ( oh and I am using CSS4K2)

 

I want to display SOME items from both these catagories on the front page.  So I looked around and yes.. I can use a "frontpage" tag, or the latest items to do this, and it works, however these two catagories have two compleatly different templates in catagory list view.  The news is a pretty basic blog, but the events are not, with a number of individual extra fields being displayed ( not displaying all the fields in the list view )

When I use tags or latest, bang.. I have another template to mess with being 'generic'.. and they all have to look the same, which just does not work for what I want to do.

 

What I would like to do is either.. preferably 1) Display items from multiple catagories where each item retains its own CatItem template and the items are displayed in and order (latest etc) ...

 

Or display News and Events in two sections on the main content area on the front page using their own catlist templates.

 

I have looked at a few extensions but have not come up with an answer.. ( looking at K2 content wall from Jxtc next.. )

I thought about using k2_content and adding two module into content area with loadpos etc but have not had a chance to try it yet to see if it will get everything I need.. and how flexible/ what sub templates do.. and beside, thats a whole lot of extra work IF there is a way I can just 'retain' the template for individual items in a multi cat view.

 

I am hoping for a little advice, through, suggestions from anyone out there who knows a lot more than me.

 

Many thanks in advance.

 

Michael Tull
  • harikaram
  • harikaram's Avatar
24 Feb 2011 16:43
REQUEST: K2 API Enhancements was created by harikaram

REQUEST: K2 API Enhancements

Category: English K2 Community

In developing template overrides for my websites, I'm having to do a lot of PHP coding in order to get data that one might expect to be available, for example, getting the item tags and author information in the generic templates.  Below are a few addition to the api of the item object (which is currently just is stdClass in the "item" template) that would be very useful...


Tags, extrafields, and author info fully set for all views
->getExtraFieldByName('My Extra Field') returning the object or perhaps just the value
$item->extraFieldGroupName
Having the default image data set by the view, consistently at the same place in the code flow for each view (currently its different for categories, items, generic, ...) AND prior to the onK2BeforeDisplay hook
Having it be a K2ItemModel or Table with an api rather than just a stdClass. 
More event hooks for categories paralleling those for items, especially w.r.t. the admin side

In the meantime, I'll attach a static class which I use in my template overrides to make working around these shortcomings a bit easier...
  • Olivier Karfis
  • Olivier Karfis's Avatar
16 Feb 2011 18:19
Replied by Olivier Karfis on topic Add Link to the item link-bar

Add Link to the item link-bar

Category: English K2 Community

Hi.

 

For replacing the text of the print, email, etc... with images, it is possible (see this template for example:

templates.joomlart.com/ja_norite/index.php?option=com_content&view=article&id=61&Itemid=111

 

In order to do this, you'll have to edit your item.php file, find the areas where these links are created and add an img tag in the <a> tag so that it looks something like this

 

around line 128:

<a class="itemPrintLink" href="<?php echo $this->item->printLink; ?>" onclick="window.print();return false;"> <img alt="<?php echo JText::_('Print'); ?>" title="<?php echo JText::_('Print'); ?>" src="templates/mytemplate/images/printbutton.png"> </a>

 

and so on....

 

As far as the personal link or IMG, I imagine that is something you need to be change on an article basis?  If so then you'll probably need to create an extrafield to use as the value and then recall that field value in the area where the buttons are defined. Refer to this post for more details on how to do that:

community.getk2.org/forum/topics/output-extra-fields

 

--Olivier
  • BBC
  • BBC's Avatar
13 Feb 2011 14:09

How do you move Extra Fields - Above Main Text?

Category: English K2 Community

K2 need urgently option to sort order of extra fields in Admin panel.

Not placement in template, it is impossible in Admin panel, but plain sorting. What field would show before in list of fields, that type of sorting.
  • John Helbling
  • John Helbling's Avatar
05 Feb 2011 17:45
Replied by John Helbling on topic Slide Show Pro for Image Viewer

Slide Show Pro for Image Viewer

Category: English K2 Community

Great! I did figure this out! Also with the flash I am using Slideshow Pro with the Thumbnail option. I was able to put the location of the swf file in the video section of the Item in the admin panel. I altered the All Videos Css files to give a white background and the Keyline border around the flash. Then I took the block of code for the video from the item.php and replaced the itemimage div. For kickers I was also able to create new DIV blocks to hold the player to the left then one to the right to hold my extra fields, tags etc. Turned out GREAT!

 

Thanks you for making K2! Love it!

 

John
  • dani_imanima
  • dani_imanima's Avatar
25 Jan 2011 21:23
Order items was created by dani_imanima

Order items

Category: English K2 Community

Hi everyone, I need to sort the items by date, and can not be by 'date created ', I can do this in several ways ...: -a serious extra creating a date type field, which when you fill out the typical schedule (but nose as I can create a kind of extra field). - Another option would be below fields: Date created, published and Publication Launch finished, add another field, to sort this. - And finally be able to sort by field end of the article, and I'm interested in leaving before the first items that will end (this would most likely believe, as it might). Thanks and greetings in advance.
  • matthew turner
  • matthew turner's Avatar
21 Jan 2011 00:04
Replied by matthew turner on topic Multiple Category Menu Item Layout order??

Multiple Category Menu Item Layout order??

Category: English K2 Community

Hi,

I think what would be better is a wider selection of display/ordering options for multi category pages:

Group by Category,

Group by Author,

Group by ExtraField etc,

And then apply the ordering (by date, or Ordering or even Random (why?)

Unfortunately I do not enough time to fix/create a better solution for this until a client needs it, but will post any further help if I can.
  • Laura Nunez
  • Laura Nunez's Avatar
29 Dec 2010 18:03

My 'database is causing the shared resources to be over-utilized' - What does this mean?

Category: English K2 Community

I am new to Joomla! and even newer to K2, but I am very willing to learn. 

 

I was contacted by our host that the database is taking up too much space and will be shut down until the problem is fixed.

 

The problem is with this :

 

-SELECT i.title AS title, i.metadesc, i.metakey, c.name as section, i.image_caption, i.image_credits, i.video_caption, i.video_credits, i.extra_fields_search, i.created, CONCAT(i.introtext, i.fulltext) AS text, CASE WHEN CHAR_LENGTH(i.alias) THEN CONCAT_WS(':', i.id, i.alias) ELSE i.id END as slug, CASE WHEN CHAR_LENGTH(c.alias) THEN CONCAT_WS(':', c.id, c.alias) ELSE c.id END as catslug FROM lav_k2_items AS i INNER JOIN lav_k2_categories AS c ON c.id=i.catid AND c.access <= 0 WHERE (MATCH(i.title, i.introtext, i.`fulltext`,i.extra_fields_search,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.metadesc,i.metakey) AGAINST ('+??alert(42)*' IN BOOLEAN MODE) ) AND i.trash = 0 AND i.published = 1 AND i.access <= 0 AND c.published = 1 AND c.access <= 0 AND c.trash = 0 AND ( i.publish_up = '0000-00-00 00:00:00' OR i.publish_up <= '2010-12-19 15:49:29' ) AND ( i.publish_down = '0000-00-00 00:00:00' OR i.publish_down >= '2010-12-19 15:49:29' ) GROUP BY i.id ORDER BY i.created DESC LIMIT 0, 50

 

What is this and what is the problem and how do I fix it?

 

Sorry if that comes off wrong - I do not want someone to fix it for me, or do my job for me. As I said, I am still new to Joomla! and K2. I do not know what this relates to or how to fix it but I want to learn.

 

Any and all help will be greatly appreciated.

 

Thanks for reading.
  • Alan Sparkes
  • Alan Sparkes's Avatar
27 Dec 2010 03:06

Extrafield validation and loading extrafields on form render

Category: English K2 Community

I need extrafields to load when the editing form is loaded in the front end. ie not when a user selects a category with extrafields in but as soon as its loaded. This is becuase it is a bespoke one submit process and I want it as user friendly as possible

As well as this i need form validation for each extrafield.

 

Jproven.coms solution works well for validation.

 

However I cant seem to beat the loading of fields issue. I need to change the mootools change event in order to load extrafields straight away.


$('catid').addEvent('change', function(){

Thats easy enough but as soon as i move loading of extrafields away from this mootools function jproven stops working.

 

Anyone else have an idea on acheving instant extrafields and validation?
  • Arvind Sah
  • Arvind Sah's Avatar
21 Dec 2010 05:49

can we add extra fields to the user registration form?

Category: English K2 Community

Hi,

I am using K2 User Extra Field but it is gives result with render html field with table and other things..from where we can control those html tags..

I need control above html table:

<table cellspacing="1" width="100%" class="paramlist admintable"><tbody><tr><td width="40%" class="paramlist_key"><span class="editlinktip"> </span></td><td class="paramlist_value"> <div style="font-weight: normal; font-size: 12px; color: rgb(255, 255, 255); padding: 4px; margin: 0pt; background: none repeat scroll 0% 0% rgb(11, 85, 196);"> Contact Details </div> </td></tr><tr><td width="40%" class="paramlist_key"><span class="editlinktip"><label for="pluginsuserExtendedFieldsaddress" id="pluginsuserExtendedFieldsaddress-lbl">Address</label></span></td><td class="paramlist_value"><input type="text" size="40" class="text_area" value="" id="pluginsuserExtendedFieldsaddress" name="plugins[userExtendedFieldsaddress]"></td></tr><tr><td width="40%" class="paramlist_key"><span class="editlinktip"><label for="pluginsuserExtendedFieldscity" id="pluginsuserExtendedFieldscity-lbl">City</label></span></td><td class="paramlist_value"><input type="text" size="40" class="text_area" value="" id="pluginsuserExtendedFieldscity" name="plugins[userExtendedFieldscity]"></td></tr><tr><td width="40%" class="paramlist_key"><span class="editlinktip"><label for="pluginsuserExtendedFieldsstateOrProvince" id="pluginsuserExtendedFieldsstateOrProvince-lbl">State or Province</label></span></td><td class="paramlist_value"><input type="text" size="40" class="text_area" value="" id="pluginsuserExtendedFieldsstateOrProvince" name="plugins[userExtendedFieldsstateOrProvince]"></td></tr></tbody></table>

 

Germán de Souza said:

Yes, is a little complicated task... but is possible, you must install this plugin "User Extended Fields for K2" and then change the parameters of the plugin in order to add your own fields...
  • Jiliko.net
  • Jiliko.net's Avatar
30 Nov 2010 15:17
Replied by Jiliko.net on topic Copy a new item in two tables

Copy a new item in two tables

Category: English K2 Community

Hi Greenslot,

Here's an example of an insert query for the #__k2_items table :

INSERT INTO `dev_k2_items` (`id`, `title`, `alias`, `catid`, `published`, `introtext`, `fulltext`, `video`, `gallery`, `extra_fields`, `extra_fields_search`, `created`, `created_by`, `created_by_alias`, `checked_out`, `checked_out_time`, `modified`, `modified_by`, `publish_up`, `publish_down`, `trash`, `access`, `ordering`, `featured`, `featured_ordering`, `image_caption`, `image_credits`, `video_caption`, `video_credits`, `hits`, `params`, `metadesc`, `metadata`, `metakey`, `plugins`) VALUES
(1, 'Welcome to Joomla!', 'welcome-to-joomla', 5, 1, 'Joomla! is a free open source framework and content publishing system designed for quickly creating highly interactive multi-language Web sites, online communities, media portals, blogs and eCommerce applications.
Joomla! provides an easy-to-use graphical user interface that simplifies the management and publishing of large volumes of content including HTML, documents, and rich media. Joomla! is used by organisations of all sizes for intranets and extranets and is supported by a community of tens of thousands of users.

', 'With a fully documented library of developer resources, Joomla! allows the customisation of every aspect of a Web site including presentation, layout, administration, and the rapid integration with third-party applications.Joomla! now provides more developer power while making the user experience all the more friendly. For those who always wanted increased extensibility, Joomla! 1.5 can make this happen.

A new framework, ground-up refactoring, and a highly-active development team brings the excitement of ''the next generation CMS'' to your fingertips. Whether you are a systems architect or a complete ''noob'' Joomla! can take you to the next level of content delivery. ''More than a CMS'' is something we have been playing with as a catchcry because the new Joomla! API has such incredible power and flexibility, you are free to take whatever direction your creative mind takes you and Joomla! can help you get there so much more easily than ever before.

Thinking Web publishing? Think Joomla!

', NULL, NULL, NULL, '', '2008-08-12 10:00:00', 62, '', 0, '0000-00-00 00:00:00', '2008-08-12 10:00:00', 62, '2006-01-03 01:00:00', '0000-00-00 00:00:00', 0, 0, 1, 0, 0, '', '', '', '', 92, 'catItemTitle=\ncatItemTitleLinked=\ncatItemFeaturedNotice=\ncatItemAuthor=\ncatItemDateCreated=\ncatItemRating=\ncatItemImage=\ncatItemIntroText=\ncatItemExtraFields=\ncatItemHits=\ncatItemCategory=\ncatItemTags=\ncatItemAttachments=\ncatItemAttachmentsCounter=\ncatItemVideo=\ncatItemVideoWidth=\ncatItemVideoHeight=\ncatItemVideoAutoPlay=\ncatItemImageGallery=\ncatItemDateModified=\ncatItemReadMore=\ncatItemCommentsAnchor=\n =Advanced\ncatItemK2Plugins=\nitemDateCreated=\nitemTitle=\nitemFeaturedNotice=\nitemAuthor=\nitemFontResizer=\nitemPrintButton=\nitemEmailButton=\nitemSocialButton=\nitemVideoAnchor=\nitemImageGalleryAnchor=\nitemCommentsAnchor=\nitemRating=\nitemImage=\nitemImgSize=\nitemImageMainCaption=\nitemImageMainCredits=\nitemIntroText=\nitemFullText=\nitemExtraFields=\nitemDateModified=\nitemHits=\nitemTwitterLink=\nitemCategory=\nitemTags=\nitemShareLinks=\nitemAttachments=\nitemAttachmentsCounter=\nitemRelated=\nitemRelatedLimit=\nitemVideo=\nitemVideoWidth=\nitemVideoHeight=\nitemVideoAutoPlay=\nitemVideoCaption=\nitemVideoCredits=\nitemImageGallery=\nitemNavigation=\nitemComments=\nitemAuthorBlock=\nitemAuthorImage=\nitemAuthorDescription=\nitemAuthorURL=\nitemAuthorEmail=\nitemAuthorLatest=\nitemAuthorLatestLimit=\nitemK2Plugins=\n\n', '', 'robots=\nauthor=', '', '');
Olivier
  • m.atze89
  • m.atze89's Avatar
18 Nov 2010 23:10
Item Order in Category list was created by m.atze89

Item Order in Category list

Category: English K2 Community

Hey all,im trying to add a new option of ordering. In this option, iwant to sort all Items by the value of an extra field (numbers from 0 two 10000). And if two Items got the same value, i want to sort them by hits. It would be great if u could tell me, in witch folder i can find the right script, and where exactly i have to add something or edit the script.I hope u understand what i want, because my english is not good :-/Thanksmatze
  • Fprefix
  • Fprefix's Avatar
14 Nov 2010 12:18

Search don't work in translated language (with Joomfish)

Category: English K2 Community

This plugin not working, see error:
No valid database connection You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' FROM #__k2_items AS i LEFT JOIN #__jf_content as jfc ON reference_id =' at line 14 SQL=SELECT i.title AS title, i.metadesc, i.metakey, c.name as section, i.image_caption, i.image_credits, i.video_caption, i.video_credits, i.extra_fields_search, i.created, CONCAT(i.introtext, i.fulltext) AS text, CASE WHEN CHAR_LENGTH(i.alias) THEN CONCAT_WS(':', i.id, i.alias) ELSE i.id END as slug, CASE WHEN CHAR_LENGTH(c.alias) THEN CONCAT_WS(':', c.id, c.alias) ELSE c.id END as catslug, jfl.code AS jflang, jfl.name AS jflname' FROM #__k2_items AS i LEFT JOIN #__jf_content as jfc ON reference_id = i.id LEFT JOIN #__languages as jfl ON jfc.language_id = jfl.id INNER JOIN #__k2_categories AS c ON c.id=i.catid AND c.access <= 0 WHERE ((LOWER(jfc.value) LIKE '%search..%')) AND i.trash = 0 AND i.published = 1 AND i.access <= 0 AND c.published = 1 AND c.access <= 0 AND c.trash = 0 AND jfc.reference_table = 'k2_items' AND jfl.code = '' GROUP BY i.id ORDER BY i.created DESC LIMIT 0, 50
  • allydawn
  • allydawn's Avatar
19 Oct 2010 18:49
Replied by allydawn on topic Unable to create a list inside an extra field

Unable to create a list inside an extra field

Category: English K2 Community

Nothing helps... I dont know how to do it :(
Here's my FIeld:




Here's my piese of code from k2.css

div.itemExtraFields {clear: none; margin:0 0 20px;padding:0;}
div.itemExtraFields h3 {margin:0 0 2px;padding:8px 16px;line-height:normal !important; font-size:100%;background: #fbfbfb; border:1px solid #e5e5e5; border-bottom: none;}
div.itemExtraFields ul {margin:0;padding:24px 16px;list-style:none;background: #fbfbfb;border:1px solid #e5e5e5;}
div.itemExtraFields ul li {display:block;}
div.itemExtraFields ul li span.itemExtraFieldsLabel {display:block;float:left;font-weight:bold;margin:0 4px 0 0;width:30%;}
div.itemExtraFields ul li span.itemExtraFieldsValue {display:block; margin-left: 30%}

if anyone knows...please help
  • Manos
  • Manos's Avatar
12 Oct 2010 12:52

Serious bug when moving an item to another category. Looses all custom fields!

Category: English K2 Community

Lefteri,

I understand this, however I am only moving an item from a subcategory to an other subcategory that both belong to the same category and have exactly the same extra fields. It's totally stupid to remove them, only to replace them with the same as blank. There should be a check in this case to skip the above step and preserve the fields' information.
K2 is a smart system. It should have this intelligence. Could you please let me know where could I modify the code in order to add a check to skip this step in this case?

Thanks in advance,

Manos
  • Start Tech Hosting
  • Start Tech Hosting's Avatar
27 Sep 2010 00:13
how can i extract and extra field item? was created by Start Tech Hosting

how can i extract and extra field item?

Category: English K2 Community

How can i extra an extra field item based on the name if gave it  when i created it. I am new to K2 and php but what i have figured out so that the the extra field group is and array. this is also the additional info block on the standard k2 templateit looks like thisArray
(
[0] => stdClass Object
(
[id] => 1
[name] => RapidShare Link
[value] => Rapid Share
[type] => link
[group] => 1
[published] => 1
[ordering] => 1
)

[1] => stdClass Object
(
[id] => 2
[name] => authour
[value] => me
[type] => textfield
[group] => 1
[published] => 1
[ordering] => 2
)

[2] => stdClass Object
(
[id] => 3
[name] => Version
[value] => 45
[type] => textfield
[group] => 1
[published] => 1
[ordering] => 3
)

)


i need to just get the first one but based on the name but it may not always be the first on  and display it in my template so that when there is a extra field called RapidShare Link it will show.
  • Jana Fedele
  • Jana Fedele's Avatar
19 Sep 2010 23:13
Replied by Jana Fedele on topic Sort, group and search by extra fields

Sort, group and search by extra fields

Category: English K2 Community

Thanks for the confirmation that I have just wasted a day or two.
Now, if I could only find the plug-in to do what I want!

William White said:K2 sorts by several things just like Joomla....it uses most recent, alph by title, oldest first, etc etc when you pick sort orders. Extra fields are for adding all sorts of additonal info like Address, City, State, and when the title is say Last, First and you sort it by title alph you may get a pretty good listing. Things are also sorta sorted..by categories and subcategories and have an order under each - but you are correct, exta fields are not used in the sort as far as i have seen
Jana Fedele said:seriously? You put in all these fields and you can't use them to make pages sorted by the fields? What is the point? What good is K2 you can't USE the dang data???????????????????????????????????????????????????????
  • william white
  • william white's Avatar
19 Sep 2010 22:46
Replied by william white on topic Sort, group and search by extra fields

Sort, group and search by extra fields

Category: English K2 Community

K2 sorts by several things just like Joomla....it uses most recent, alph by title, oldest first, etc etc when you pick sort orders. Extra fields are for adding all sorts of additonal info like Address, City, State, and when the title is say Last, First and you sort it by title alph you may get a pretty good listing. Things are also sorta sorted..by categories and subcategories and have an order under each - but you are correct, exta fields are not used in the sort as far as i have seen

Jana Fedele said:seriously? You put in all these fields and you can't use them to make pages sorted by the fields? What is the point?
What good is K2 you can't USE the dang data???????????????????????????????????????????????????????
  • Rhianon Hoffman
  • Rhianon Hoffman's Avatar
17 Sep 2010 20:35
Replied by Rhianon Hoffman on topic Varying Author Name

Varying Author Name

Category: English K2 Community

Whoops - I might have miscommunicated about the image. It doesn't look like that on the site - that's just what I want it to look like. Normal text, not linked, etc. I'm trying to put the code up that will enable browsers to display the information like that. Perhaps it isn't possible.

Thanks

William White said:looks good, nice work Seth Hoffman said:Hi Miltiadis, Thanks for getting back to me so quickly!
I followed your link and copied everything into my /templates/YOURTEMPLATE/html/com_k2/ folder. I did need to create the com_k2 folder which I assume is normal. There was already a mod_k2login there but not a com_ folder. Anyway, inside that folder, it seemed that the tutorial expected the "default" folder and a couple of views to be in the root. The views they used as examples, generic.php, user.php etc were not in the root but in the "templates" folder. Is that ok? The "default" folder was also located in the "templates" folder.

If I want to change the way the author name is displayed across the whole site, can I not just edit the files at the components/com_k2 level? Also, just to ensure I am communicating what I want to happen, I edited my last image to add the location. It doesn't need to be linkable, just displayed. I checked out the plugin you mentioned but it didn't seem to accomplish this.

So what should I do next?

Thanks so much for your help!
Seth

Miltiadis bouchalakis said:Hello you will need to override the template community.getk2.org/notes/Templating_in_K2 then you can create some extra fields and position them in the place of written by. or you can install extensions.joomla.org/extensions/extension-specific/k2-exten... and then call the user extra fields or call the user description i know that my post is cryptic for someone that is just starting to learn k2. Read the tutorials and i will help you. Be aware that you will need some php html and css knowledge in order to modify the template
  • william white
  • william white's Avatar
17 Sep 2010 20:29
Replied by william white on topic Varying Author Name

Varying Author Name

Category: English K2 Community

looks good, nice work

Seth Hoffman said:Hi Miltiadis,
Thanks for getting back to me so quickly!

I followed your link and copied everything into my /templates/YOURTEMPLATE/html/com_k2/ folder. I did need to create the com_k2 folder which I assume is normal. There was already a mod_k2login there but not a com_ folder. Anyway, inside that folder, it seemed that the tutorial expected the "default" folder and a couple of views to be in the root. The views they used as examples, generic.php, user.php etc were not in the root but in the "templates" folder. Is that ok? The "default" folder was also located in the "templates" folder.

If I want to change the way the author name is displayed across the whole site, can I not just edit the files at the components/com_k2 level? Also, just to ensure I am communicating what I want to happen, I edited my last image to add the location. It doesn't need to be linkable, just displayed. I checked out the plugin you mentioned but it didn't seem to accomplish this.

So what should I do next?

Thanks so much for your help!
Seth

Miltiadis bouchalakis said:Hello you will need to override the template community.getk2.org/notes/Templating_in_K2 then you can create some extra fields and position them in the place of written by. or you can install extensions.joomla.org/extensions/extension-specific/k2-exten... and then call the user extra fields or call the user description
i know that my post is cryptic for someone that is just starting to learn k2. Read the tutorials and i will help you.
Be aware that you will need some php html and css knowledge in order to modify the template
Displaying 421 - 440 out of 529 results.

Powered by Kunena Forum