We build. You grow.

Get best community software here

Start a social network, a fan-site, an education project with oxwall - free opensource community software

New Posts | Forum

Nirmalya Ghosh
Nirmalya Ghosh Apr 29 '13
Howdy Everyone,

I just wanted to know which php file shows the posts in the newsfeed? I think it will be in /ow_plugins/newsfeed/components but not sure which file it is. Can anybody help?

Thank you.

Kieron H Leader
Kieron H Apr 30 '13
you are correct 
Nirmalya Ghosh
Nirmalya Ghosh Apr 30 '13
I wanted to know what is the name of the specific file.
Kieron H Leader
Kieron H Apr 30 '13
i dont know but that is the directory were the file is
Nirmalya Ghosh
Nirmalya Ghosh Apr 30 '13
Yes Kieron, I know that but I wanted to know the exact file.
Alia Team
Alia May 1 '13
try feed_item.php
Nirmalya Ghosh
Nirmalya Ghosh May 1 '13
Actually, I was trying to update only the portion that shows the new posts in the newfeed.

The basic code should be as follows



<script type="text/javascript">var auto_refresh = setInterval(function (){$('#ow_newsfeed ow_smallmargin').load('feed_item.php?q=<?php echo $search_word; ?>').fadeIn("slow");}, 10000); // refresh every 10000 milliseconds
<body><div id="ow_newsfeed ow_smallmargin"> </div></body>
</script>



But actually I could not get it to work!

Should it be connected to the database using this code



<?php$search_word=$_GET['q'];$sql = mysql_query("Select id form Messages where message LIKE '%$search_word%'");$feed_item=mysql_num_rows($sql);//Display count.........echo $feed_item;?>



Can anybody help in this matter?

Any developer?

Thank you.

Alia Team
Alia May 2 '13
Topic was moved from General Questions.
Daisy Team
Daisy May 15 '13
Nirmalya, the code you have provided will not work. I suggest that you check out the /ow_plugins/newsfeed/controllers/ajax.php file to see how the loadItem function works.

P.S. As far as I can see from the code you are trying to load the feed_item.php file directly - it will not work in our software because of our routing system. Please see the crash course for more information here: http://docs.oxwall.org/dev:crash-course#page-routing
Nirmalya Ghosh
Nirmalya Ghosh May 16 '13
So Daisy, can you help me further how can we get this to work as I think that this would help many members here as most of us are wanting this!

Thank you.

Daisy Team
Daisy May 16 '13
Sorry , but we do not provide examples or guidelines on how to perform a specific modification. We expect people posting in this forum know how to modify the code and all they need is some hints.
cara
cara Dec 16 '22
To answer this question, wordle you would need to use the WordPress SEO plugin to look for posts in the newsfeed. This plugin will help you find and analyze the content of your posts so that you can improve their ranking on search engines.
Chat GPT
Chat GPT Jan 1 '23
If we are not familiar with the basics of php development, it is indeed difficult to modify the source code because too much background knowledge is required. Fortunately, there is Chat GPT now, he can help us review and modify the code, it is really great for developers