I've been googling for a while, and browsed http://www.tumblr.com/docs/en/custom_themes but I haven't found the way to show the "original poster" under reblogs in my theme.
So NOT the source (whom I reblogged it from), but the user who originally contributed it to Tumblr (and the link to his / her post.
Hope somebody knows. Thanks! //r
Use reblog's variables containing Root:
{ReblogRootName} — the title of the blog this post was created by.
{ReblogRootTitle} — the URL for the blog this post was created by.
{ReblogRootURL} — the title of the blog this post was created by.
Related
the problem:
we are porting a wordpress blog to lektor. The slugs in wordpress of the post are directly under the main domain e.g. www.mypage.com/my-blogpost-about-food/ not www.mypage.com/blog/my-blogpost-about-food/.
Now the owner is not ready to accept any broken links. Broken links from the outside, e.g. some random internet page links to www.mypage.com/my-blogpost-about-food/. This link will not work in lektor. This will decrease the page rank of the redesign of the page with lektor. What can I do to avoid this?
Again, in our current wordpress website
the main blog page sits under:
www.mypage.com/blog/
each blog post has a unique slug, NOT under /blog/ but directly in the main.
e.g.
www.mypage.com/my-blogpost-about-food/
What can I do, to make these URLs be valid for lektor as well? that e.g. mypage.com/my-blogpost-about-food is a blog post.
EDIT: this is what lektor does not support. Blog posts in lektor must sit in www.mypage.com/blog/SINGLE-BLOG-POSTS-MUSTBEHERE but I want the blog posts to be here www.mypage.com/SINGLE-BLOG-POSTS-MUSTBEHERE
reading here
https://www.getlektor.com/docs/content/urls/
if I go to the system fields and enter my-blogpost-about-food it will still appear in /blog/my-blogpost-about-food/
reading here it becomes clear that I cannot change the slug in the parent model neither:
With the above settings the blog will live at blog/ and the posts at
blog/. But what if you want to put the date of the blog
post into the URL? That's thankfully very easy. All you need to do is
to set up a new URL format for the children. Just edit blog.ini and
add this to the [children] section:
slug_format = {{ (this.pub_date|dateformat('YYYY/M/') if this.pub_date) ~ this._id }}
What this does is that it will prepend the year (YYYY) and month (M)
to the ID of the page if the publication date is configured. Otherwise
it will just use the ID of the page. With this change our blog post
will move from for instance blog/hello/ to blog/2015/12/hello/.
now how would I achieve a behaviour similar to this?
this is the formal of the perma links of our wordpress installation:
This is possible. If you started with the default setup from lektor quickstart:
In models/blog-post.ini, remove hidden = yes
In models/blog.ini, under the pagination section, add items = site.query('/').filter(F._model == 'blog-post')
The first step lets you create blog posts under root in the admin.
The second step tells the page blog to look for its pagination items under /, and only include the ones of type blog-post. This will exclude e.g. About, Blog, etc.
You will now have your site's home page at /, a blog page with list of all posts at /blog, and each post will be located at example.com/my-blogpost-about-food/.
To create a new blog post in the admin, go to the root admin page (not the /blog admin page), click the +, and select Blog Post for your new page type. It will show up in the list on /blog, and live directly under /.
I'm not certain I understand exactly what you want to achieve. If I understand correctly you can possibly solve this using the replaced_with for children functionality:
https://www.getlektor.com/docs/guides/categories/
I need to get some attributes from the main article of an article variant. An example:
The user got article SW1234.4 selected. The shop should show the attribute "test" from the main article SW1234 and not from the variant SW1234.4.
I´m thinking about some smarty var with {$sArticle.mainnumber.attr4}
How is this possible?
you should try "{debug}" at first. (Enable popups!)
Now you can see which variables you have access to, maybe the information you are looking for is already stored in a smarty variable.
The Other way would be a custom Plugin which does a select on your articles table and gets the desired information which you than can assign to your view.
e.g.
$this->View()->assign($varname, $value);
I know my reply is a little late, but I am new to this website as a contributer.
Which Shopware Version?
Are u using the responsive theme?
Please provide a little more information. :)
this is my first post here and I need some help with Tumblr theme customizing.
In my current theme, I have two icons showing under every image post. The first one links to the hyperlink entered when posting the image and the second one is a link to the post.
The thing is when it comes to reblogging an image without any hyperlink, the firsy icon leads to the homepage. I'd like to make it link to the orignal post when it's the case.
Here's the original code :
{block:Photo}
<i class="icon-search"></i>
{/block:Photo}
<i class="icon-link-1"></i>
Here's what I've tried :
{block:Photo}
{block:IfLinkURL}<i class="icon-search"></i>{/block:IfLinkURL}
{block:IfNotLinkURL}<i class="icon-search"></i>{/block:IfNotLinkURL}
{/block:Photo}
But it doesn't work :(
Any idea?
Thanks a lot in advance
Edit : I just found out that {ReblogURL} is a link to reblog the post. That's not what I want, I need a link to the post itself on the source blog.
Looking at your edit, I think you want: {ReblogRootURL}
The URL for the blog this post was created by.
Source: http://www.tumblr.com/docs/en/custom_themes#reblogs
The scenario:
I'm on the Startpage of my Blog, and there is an Article with its post-thumbnail. When I click on the Header or the "…read more-link I get to the post.
My question:
Is it possible to set the image bigger when you're on the single-post-page? Furthermore I would like to understand how to set this post-thumbnail-difference up.
I hope you've understood my bad english :) I'm looking forward in receiving help from you guys.
Best regards
Morten
Update:
Here two Screenshots of the Scenario:
Startpage > http://s1.directupload.net/images/130517/ltxuxyj6.png
Singlepost > http://s1.directupload.net/images/130517/lap5re2j.png
The images belongs to me (© Morten Sassi)
I think it depends on the theme you're using : on mine, thumbnail isn't used for the startpage but it use the "featured image", and once on the page of the article I just add the image directly in the body of the article with the size I want.
Maybe you can have a look to your template code and either edit it (but if you're using a theme you didn't create and you update it later your modifications will be deleted) or create a child theme (better solution) to edit only the files you want.
Hope this will help ^^
The best & easy tricky way is uplod your image from media, copy the path and paste this on your post or page editor from backend..and you will get what you want.
Thanks
anand
I am setting my blog up using the fantastic Jekyll. Question is my markdown files are being shown in full on the homepage. How do i make them look more like this? So that only a little bit comes up with the title?
Thanks.
http://daverupert.com/
EDIT: As of Jekyll 1.0, this is not longer necessary (Answer is outdated).
Jekyll 1.0 exports a post.excerpt variable that contains the first paragraph of a post by default.
/Edit
So, you want to show an excerpt of the post, instead of the full post?
Theres three ways to do that:
Render the full post but use CSS to hide everything that is not needed
Use filters. You can access post.content, use the truncate filter to truncate it and the markdownify filter to render it.
Specify the excerpt in YAML Front Matter and render it using {{post.excerpt | markdownify}} (that is what i do on my blog)
Each of those blocks between horizontal lines are links to the actual blog post. Any time I have a question about how someone did something on their webpage I always view-source.
The source for that page is -
view-source:http://daverupert.com/
To find out how to do something in markdown I like this site -
http://daringfireball.net/projects/markdown/basics