kn1g
Forum Replies Created
-
Forum: Themes and Templates
In reply to: [Brasserie] JQuery version problemsI included version 2.1.3 directly in the header.php (I know that the “nice” approach is the function.php – just lazyness).
For reproducing I installed the plugin “jQuery Updater”.When the plugin is active the feature section does not animate and “display:” stays “none”.
After deactivating everything works fine again.https://www.airpell.de/BrasserieJQuery/?page_id=2
(I would even provide login info (via mail). But not post it here.)Thanks and best regards
NicoFreakin’ great and fast support. Works fine now!
I appriciate your work!
Bought you a beer via PayPal Donation and rated 5/5 Stars.Thx and with best regards from Germany. kn1g
Figured it out myself.
If anyone is interested,<?php wp_footer(); ?>
calls the required libaries. So it works only if the footer Hook is in the code.Hey Janay,
i am still figuring out how to do this.
There are two things i am struggling with:
First, i dont know why the date of the first post is ALWAYS (-1 Year/DAY/ whatever) and why the mainpost has the date “1957” no matter which value i give to the “startDate”. I found the following topics:
https://github.com/VeriteCo/TimelineJS/issues/100
https://github.com/VeriteCo/TimelineJS/issues/85
there it says, that the bug has been removed. But i still have these problems.
see: https://github.com/VeriteCo/TimelineJS/issues/288
Do you also have this bug? (I just visited your page and noticed that you also have this problem..)Second, i had the following ideas to get a kind of “main post” inbetween the other posts:
- Rearrange the main post and put it to the current date. Simultaniously display all past posts before this and all future posts behind it.
Problem: The main post is always displayed before all other posts - Disable/Remove the main post and set an post always to the current date.
Problem: i can not disable the main post (dont know how).
tried
$EM_Events = EM_Events::get(array('limit'=>$maxEventsDisplayed, 'orderby'=>'start_date'));
But got in trouble as i tried to access the elements. like$EM_Events[0]['event_id']
was not possible. How can i access the elements of the class? (Didn’t find a specific “getter” function) like “get_event_id”.Sry, but i am still a bit confused by the structure of the Event classes and the task to loop properly through all events.
Could it be that the option
EM_Events::output(array( 'order'=>'DESC'
does not work?ok, sry. I tried only “output” before. I think “get” will do the job ??
hi janay,
i think the problem with more custom fields is complicated. Because i think, that you cant solve this in the “timline.php” alone. The timeline.php just outputs the values. To check if the values are outputted correct, check the controller output as i posted above. (I think this will work correctly) – If your custom fields are outputted correct by the controller. The job of the “timeline.php” is done.
Now you need to get deeper into the code. Can’t help you there at the moment.Hey, custom fields are a bit tricky.
I give you an example how i did it:- 1. Define a custom field. Lets name it “example” (You do this by editing the post in the WP-Backend)
- 2. Add a line to the timline controller php (timeline.php) like:
$example = get_post_meta($main_post->ID, "example", true);
(thats for the main post – modifiy for other posts!). Add it BEFORE the$json['timeline'] = array();
- 3. Replace the Json variable you want to change. For example:
$json['timeline']['startDate'] = $example;
That should work! I also have some problems with the timeline. Im currently trying to figure out, how to stick the main post always to the current date. I want to have past posts and future posts…
Anyway, i hope i could help you Janay! If not i can upload my code to pastebin. Just let me know!I also had similar problems by installing the Timeline. But everything works finde now. I can not exactly remember how i solved the problems, but i can give you some basic hints to figure it out by yourself.
- 1. It definitely works with the shortcode [timeline src=”https://example.com/api/timeline/category_posts/”%5D
-
2. !! check the controller!!
@janay, if you check it you will see, that it could not work.
look@ https://conexion.cluster003.ovh.net/blog/api/timeline/category_posts/
To check if your controller works properly enter the url into your webbrowser (https://example.com/api/timeline/category_posts/). You should see an JSon formatted file. - 3. You need to have posts in the category you want to display
hi,
it took me 2h to figure out, how this works… I’ve never heard of jason before. A short tutorial would have been nice and saved me a lot of time (I would make one. But i’ve currently no time. Perhaps in a few weeks if i still remember).
Anyway GREAT plugin!Is it possible to style the timeline via the shortcode? I’ve seen there is a “dark” theme in the css folder. Can i activate different themes in the shortcode?
- Rearrange the main post and put it to the current date. Simultaniously display all past posts before this and all future posts behind it.