Separating the clock from the date

More
7 years 10 months ago #73233 by aminweb
hi,
I use date/timestamp field custom format : l,d F Y - h:i
now I want when show this field in category list , dont show clock(h:i) only show date.
and when item view show l,d F Y - h:i
how do it?
thanks

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73239 by micker
you can use separe format in form and display check different tabs in your date field

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73241 by aminweb
dispaly show in form items is ok.not problem in form (submission item)
I use date/timestamp field custom format : l,d F Y - h:i
I want when show this field in category list(table) , dont show clock(h:i) , only show date.

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago - 7 years 10 months ago #73243 by ggppdk
Hello

we have selection of different display per view (item view, multi-item view) in other fields

Fields that have different display in multi-item (category-based) views are
- image-gallery field
- relation field

it makes sense to add similar configuration to date field
(for now you could add custom PHP code inside category_items.php and remove the hour part ... from ...->display)


Also the long term plan is to add to all fields via a different / complementary way
-- The plan is that every field will declare a LIST of available "HTML display" types:
e.g. image field will declare

display,
display_small, display_medium, display_large
display_single, display_single_total

and in when draging the field to a template position you will also select a display out of the available

And then still the -default- "display" method will continue to work like before
- it can be different in different views ...


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!
Last edit: 7 years 10 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73246 by micker
yes maybe a different view between item and category for same field

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73247 by aminweb

ggppdk wrote: Hello

we have selection of different display per view (item view, multi-item view) in other fields

Fields that have different display in multi-item (category-based) views are
- image-gallery field
- relation field

it makes sense to add similar configuration to date field
(for now you could add custom PHP code inside category_items.php and remove the hour part ... from ...->display)


Also the long term plan is to add to all fields via a different / complementary way
-- The plan is that every field will declare a LIST of available "HTML display" types:
e.g. image field will declare

display,
display_small, display_medium, display_large
display_single, display_single_total

and in when draging the field to a template position you will also select a display out of the available

And then still the -default- "display" method will continue to work like before
- it can be different in different views ...


Thanks, but I did not understand what to do?

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73250 by aminweb
is it possibile add css class for part hours date?
for ex:
l,D F Y <div class="time-clock-hidden">h:i</div>

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73251 by micker
you can do it in template view directly but you need to code it

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago #73252 by aminweb

micker wrote: you can do it in template view directly but you need to code it

how do it?
please guide me with syntax code
so thanks

Please Log in or Create an account to join the conversation.

More
7 years 10 months ago - 7 years 10 months ago #73254 by micker
hello
1 you need to load your field in render position
2 insert your rendering field where you want
Code:
<?php $date = $item->fields["fieldname"]->display; $disp_date = explode( " ", $date); echo $disp_date[0]; ?>
in this case i explode string date with space and load first value
now you need to adatp this to your code and your value format (fieldname = yourfieldname, " " space delimiter, [0] is first value [1] second ect)

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]
Last edit: 7 years 10 months ago by micker.

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Save