- Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236
fw190
ParticipantDeprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 2432Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Warning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220Would it be possible that the next/previous post links would display posts from same category?
I have a bilingual site and wouldn’t like to show a next post with another language 😉
- This topic was modified 12 years, 7 months ago by fw190. Reason: spelling
AdvertismentDeprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Daniel Tara
KeymasterWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220Not really, those links are handled directly by WordPress and there’s little control in regards to what they link to.
Anyway, I don’t recommend using categories for different languages. Instead use a plugin like WPML or qTranslate.
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236fw190
ParticipantWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220I found something like this:
http://codex.wordpress.org/Function_Reference/next_post_link#Text_As_Link.2C_Without_Post_Title.2C_Within_Same_Categoryand
http://codex.wordpress.org/Template_Tags/previous_post_link
But this is too big for me to sort this by myself
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Daniel Tara
KeymasterWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220It only allows you to modify the link text, not the URL it points to.
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236fw190
ParticipantWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220But it states there http://codex.wordpress.org/Function_Reference/next_post_link#Text_As_Link.2C_Without_Post_Title.2C_Within_Same_Category
that: “Displays custom text as link to the next post within the same category” so I thought that it is the thing for me.
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Daniel Tara
KeymasterWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220I believe you are making a confusion. Tat function is
next_post_link();
, which displays a link to the next post INSIDE the post you are currently reading. It’s not paged navigation for post archived. The function for that isnext_posts_link();
(minor difference). If what you are looking for is inner post navigation, then all you have to do is add a third parameter , TRUE like in the example. You’ll still have to edit the file manually.Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236fw190
ParticipantWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220Sorry for making confusions. I will try to explain again what I mean.
Someone opens one post and reads it. Inside that post he has a link to the next and previous post in this category so if he is browsing for example bombs or missiles the next/previous post will bring him to a next post about bombs or missiles and not to the next post which was posted for example about airplanes.
Sory again for not being able to say what I mean precisely.
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Daniel Tara
KeymasterWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220Thank you, it is clear now.
In functions.php you’ll find the function
esplanade_post_nav();
In that function you can find the 2 functions that display the next/previous post links. You just need to add a third parameter
true
to them and they will behave as you desire.Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236fw190
ParticipantWarning: Cannot modify header information - headers already sent by (output started at /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php:340) in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php on line 220Thank you for the solution. This may sound that I’m stupid but could you post those lines so I could copy paste them, as when I was experimenting last time a had to upload the original file from source as the site wasn’t workin at all. I’m not a web developer and even such small things may couse problems for me.
I hope that I do not make to much trouble.
Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Deprecated: Function get_magic_quotes_gpc() is deprecated in /var/html/dev/wp/wp-includes/formatting.php on line 4371Notice: Trying to get property 'comment_author_email' of non-object in /var/html/dev/wp/wp-content/plugins/fv-gravatar-cache/fv-gravatar-cache.php on line 236Daniel Tara
KeymasterNotice: Undefined offset: 0 in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 532Fatal error: Uncaught Error: Call to a member function id() on array in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php:36 Stack trace: #0 /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php(538): CrayonFormatter::format_code('', Array, Object(CrayonHighlighter)) #1 [internal function]: CrayonFormatter::delim_to_internal(Array) #2 /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php(516): preg_replace_callback('#()#msi', 'CrayonFormatter...', 'function esplan...') #3 /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_highlighter.class.php(166): CrayonFormatter::format_mixed_code('function esplan...', Object(CrayonLang), Object(CrayonHighlighter)) #4 /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_highlighter.class.php(186): CrayonHighlighter->process() #5 /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_wp.class.php(213): CrayonHighlighter->output(true in /var/html/dev/wp/wp-content/plugins/crayon-syntax-highlighter/crayon_formatter.class.php on line 36