21
Cozzie
Re: How to show forum posts related to a pages/category's name
  • 2009/5/12 2:29

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Hi Darin

thanks a lot, but if I understand you correctly that's not what I want to do.

Here is what I've done so far:

I've added the newbb 'latest posts' block to my smartsection pages

then in the file which controls this block (modules/newbb/blocks/newbb_block.php) I have gone to the appropriate function (function b_newbb_show($options)) and I have made this little change:

the original code was:

$approve_criteria ' AND t.approved = 1 ';

I have changed it to:

$approve_criteria ' AND t.approved = 1 AND t.topic_title LIKE "%oxford%" OR t.topic_subject LIKE "%oxford%" OR x.post_text LIKE "%oxford%"';


OK, so like this on my category pages in the smartsection module I have a block which shows a list of any forum questions which mention Oxford.

The thing is I can't figure out how to make that be a variable dependent on the page title (which is each schools name). I'm guessing it should be something like:

$approve_criteria ' AND t.approved = 1 AND t.topic_title LIKE "%($school_name)%" OR t.topic_subject LIKE "%($school_name)%" OR x.post_text LIKE "%($school_name)%"';


And that I need to send a variable called $school_name to the newbb/blocks/newbb_block.php ($school_name being the name of each page title in my smartsection module).

I'm really not sure if I'm explaining myself well here, thanks a lot for any further help

Cheers!



22
Cozzie
How to show forum posts related to a pages/category's name
  • 2009/5/11 5:22

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Hi there

Can anyone tell me how i might be able to do the following:

I want to show any posts in my newbb forum that are related to the page name or category name of other pages in my site (which happen to use the smartsection module).

So for example I use smartsection module to have information about different schools, each category page name in the module is a school's name. On each category page I would like to show a list of posts in my forum that mention the school.

I think this would be really useful to my readers and to anyone with a forum website as it will draw readers in to the forum.

So far I have tried to adapt the newbb block which shows the latest posts in the forum.

I have changed the code to return any posts which have a certain word in their subject or text but the problem is I can't figure how to make the newbb block understand what the page/category name is of the smartsection module.

I'm using XOOPS 2.0.18 - can anyone help me? thanks a lot!



23
Cozzie
Re: showing content according to user's location
  • 2009/5/5 1:39

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


It looks ideal, thanks a lot Ghia your help is really appreciated!



24
Cozzie
showing content according to user's location
  • 2009/4/28 11:05

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Is there any way or a module which I can display content according to visitor's geolocation/ip address?

Specifically I'd like to show different banner adverts for visitor's from different countries?

Can XOOPS do this or is there an ad management system which can do this and be integrated in to a XOOPS site?

thanks a lot!!!



25
Cozzie
Re: SEO hack for CBB v3.08
  • 2009/3/23 9:59

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Hi, first of all thanks to aproape for this really great hack.

I have the same concern as doosh. I think the problem is the stripping of [ and ] means that xlanguage tags are not read.

Can anyone tell me where in the seo script I can stop it from removing the square brackets [ ] from the urls? Or if there is any reason this shouldn't be done? This should get the hack working with sites using multiple languages

thanks



26
Cozzie
Re: newbb how to stop this Re Re Re Re Re?
  • 2009/3/23 3:14

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


thanks guys! I found the problem and it was a change I made. In the langauge file I had changed the prefix to 'Re' (instead of 'Re:') while in reply.php the code adds an extra Re if it cannot find Re: (with semi-colon). Anyway thanks a lot for your replies I'd thought it must be a settings problem but your answered told me that it must be a change I'd made



27
Cozzie
Re: newbb how to stop this Re Re Re Re Re?
  • 2009/3/20 1:49

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Hi Darin

thanks for the reply but not sure what you mean.

My problem is, let's say there is a thread with 5 posts (one question and 4 replies)

the titles for each post goes like this:

This is my question

Re This is my question

Re Re This is my question

Re Re Re This is my question

Re Re Re Re This is my question

This is shown up in my forum (I'm using flat display) and any newbb search results. I checked the database and the Re's are added to the newbb_posts table each time a post is made.

I think it really looks terible, especially when threads get large. It seems xoops.org newbb doesn't have this problem so I'm not sure if I have done something to make this happen in mine.

Any thoughts on how I can stop it?

thanks a lot



28
Cozzie
newbb how to stop this Re Re Re Re Re?
  • 2009/3/19 10:05

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Hi there

Can anyone tell me how to stop the subject line for each post in a newbb thread from adding an extra Re: each time?

It seems in the XOOPS site each post in a thread after the original one has only the one Re: added to the subject line - this would be ideal, How can I have one Re: added to replies but no more than one?

Thanks a lot



29
Cozzie
Re: notifications.php not working
  • 2009/3/17 3:31

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


Thanks a lot Catz!

I've just realised what the problem is. I was logging in and out of the site between 2 users. If I just login as the one user on one computer, notifications.php works fine.

In case users of the site also register more than account (which they switch between) is there a way to enable the notifications.php to still work for them (is the above change still worth doing?)

Thanks a lot for your help!!!



30
Cozzie
Re: notifications.php not working
  • 2009/3/17 1:09

  • Cozzie

  • Not too shy to talk

  • Posts: 133

  • Since: 2007/7/13


sorry, should have said, its 2.0.18




TopTop
« 1 2 (3) 4 5 6 ... 14 »



Login

Who's Online

105 user(s) are online (74 user(s) are browsing Support Forums)


Members: 0


Guests: 105


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits