Skip to main content
11 events
when toggle format what by license comment
Apr 21, 2020 at 15:31 vote accept Julian
Apr 21, 2020 at 15:25 comment added Tony Djukic I was testing my answer and have posted it. If I put it into the console, just this line $( '.tas-event-time' ).html( $( '.tas-event-time' ).html().replace( '12:00 pm','12:00 noon') ); it executes perfectly and changes 12:00pm to 12:00 noon.
Apr 21, 2020 at 15:13 answer added Tony Djukic timeline score: 2
Apr 21, 2020 at 14:49 comment added Julian Yes but it's not even doing it with just that
Apr 21, 2020 at 14:49 answer added Sam timeline score: 0
Apr 21, 2020 at 14:49 comment added Tony Djukic You don't want to target all pm instances though, just those that start at 12:00, correct?
Apr 21, 2020 at 14:47 comment added Julian Ok did that, and have now got this script: $(".tas-event-time").text(function () { return $(this).text().replace("pm", "noon"); });
Apr 21, 2020 at 14:28 comment added Tony Djukic Might be having a hard time with it because the selection process is pretty ambiguous. Are you able to add to the template that generates the content for those entries? Then wrap the time in something simple like <span class="pp-time">12:00 pm</span>?
Apr 21, 2020 at 14:23 comment added Julian Oh I see, you mean like this? I've tried that but I can't get it right. The page in question we're trying to change is here
Apr 21, 2020 at 13:19 comment added Tony Djukic The best way to do this would be to replace the am and pm using jQuery - can you post your output code so we can see if there's something that can be targeted via the functionality? I've done something similar by replacing 'months' with 'seasons' but you have to be able to target an element and replace the text.
Apr 21, 2020 at 13:04 history asked Julian CC BY-SA 4.0