| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Show Latest 5 Wordpress Posts in Homepage - Help Needed! | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
Show Latest 5 Wordpress Posts in Homepage - Help Needed!
I▓ve been working on this mod to show the latest 5 posts from the blog in the homepage. Currently we have that functionality with XNews; however, we▓d like to show the blog posts instead.
Steps taken: 1.) Created blog.php to call the latest 5 posts from www.site.com/blog: PHP Code:
When www.site.com/blog.php is entered in the address bar, it shows the 5 latest posts. 2) Then, I created blogspots.tpl in skin1/customer/ to call blog.php located in the root directory: HTML Code:
3) Finally, blogspots.tpl was called from home.tpl with: HTML Code:
Now I am getting this error message: Fatal error: Call to a member function on a non-object in /home/site/public_html/blog/wp-includes/functions.php on line 895 Will appreciate if someone with coding experience can shed some light Thanks, Augusto
__________________
------------------------------------------------------------------ X-Cart Gold V 4.1.8 + Mods |
|||||||
#2
|
|||||||
|
|||||||
Re: Show Latest 5 Wordpress Posts in Homepage - Help Needed!
I am also facing the same problem. I am having problem in including the php file to my pages.
I used the following code on a file and named it category_links.php. Code:
when i run this file , it shows me the links to the posts in the category id 13. This shows me the result in the form of links to the posts in this particular category. Now to include this result in my product page which belongs to the same category I added the following code on the bottom of customer/product.tpl page Code:
Here corresponding category Id is 274. I created another file named links.tpl and tried including the php file in that, but no success. The product page now shows header2 "Related Articles" but after that it gives me smarty error. I feel I have reached very near to the solution, but I am certainly missing something very simple . I just need to know now, how to include my php file on my pages, so the result which it shows are available as links on my products page. I will be very thankful for any help on this issue. thanks
__________________
X-Cart 4.4.5 ... www.drugteststrips.com X-Cart 4.4.5 ... www.drugalcoholtest.com Hues Technologies http://www.huestechnologies.com |
|||||||
#3
|
|||||||
|
|||||||
Re: Show Latest 5 Wordpress Posts in Homepage - Help Needed!
Hues, thanks for your quick response.
The other option I am exploring is the Feedburner snippet, which is basically an html code you add whereever you want the posts to be displayed. I tried it in my email signature and works well. We'll see how well it does in the homepage. Here is the link from feedburner: http://www.feedburner.com/fb/a/publishers/buzzboost I like the idea of adding the posts to product detail pages, categories, sub-categories, etc, that can be handled by a simple html command within the post. I got a free mod in my blog that can show related posts according to keywords that are pull out automatically from the title and metags, or you can enter them manually if needed. Perhaps this topic is not relevant for many people but us
__________________
------------------------------------------------------------------ X-Cart Gold V 4.1.8 + Mods |
|||||||
#4
|
|||||||
|
|||||||
Re: Show Latest 5 Wordpress Posts in Homepage - Help Needed!
To post your latest blog posts in the homepage or anywhere you want follow theses steps:
Open and account with www.FeedBurner.com and make sure your RSS works well. Activate the BuzzBoost section so you can get the script to be installed in your homepage or anywhere you want it to be. To maximize your CSS customization, copy and paste the URL provided in the script and enter it in the address bar, so you can see the tags, attributes, etc. Using the example they gave, enter this URL in your favorite browser HTML Code:
That will show you PHP Code:
For more details on CSS customization read http://blogs.feedburner.com/help/buzzboost/using_buzzboost/popup/ If you don▓t want to show the FeedBurner logo image, use this hack in skin1.css: HTML Code:
Keep in mind that even though the logo was hidden, the FeedBurner.com link embedded in the script will still remain there. If you know of a hack to remove the link, please post it. That▓s it┘ Enjoy it! Augusto
__________________
------------------------------------------------------------------ X-Cart Gold V 4.1.8 + Mods |
|||||||
#5
|
|||||||
|
|||||||
Re: Show Latest 5 Wordpress Posts in Homepage - Help Needed!
Thanks Augusto,
This works perfect, when we want to show recent posts on the blog. I just need to know how to get feeds for specific category only, so that I can add them on my product pages.
__________________
X-Cart 4.4.5 ... www.drugteststrips.com X-Cart 4.4.5 ... www.drugalcoholtest.com Hues Technologies http://www.huestechnologies.com |
|||||||
#6
|
|||||||
|
|||||||
Re: Show Latest 5 Wordpress Posts in Homepage - Help Needed!
You should check some wordpress plugins that may allow you create feeds for specific categories of your blog. I have a mod that separates feeds for full posts and summaries, not sure though if that will help you achieve what you want. check it out http://www.scratch99.com/wordpress-plugin-dualfeeds/
__________________
------------------------------------------------------------------ X-Cart Gold V 4.1.8 + Mods |
|||||||
|
|||
X-Cart forums © 2001-2020
|