Support Forum
not directly out of the box... but you can use our api and hooks to adjust the behavior...
are you able to create your own sp theme or a child sp theme,and make a few edits?
Visit Cruise Talk Central and Mr Papa's World
we recommend creating a child theme or your own theme otherwise if you upgrade our themes, you will lose any changes... both are quite easy to do...
child themes see: https://simple-press.com/simpl.....ld-themes/
your own theme see: https://simple-press.com/docum.....g-a-theme/
once you have a theme, then edit the spFunctions.php file in the templates directory of your theme... if you made a child theme, just create the file... then add this to it:
add_filter('sph_topicview_query', 'my_topic_view_query'); function my_topic_view_query($spdb) { global $spThisUser; if ($spThisUser->guest) { $spdb->where.= ' AND (post_index = 1)'; add_action('sph_BeforeSectionStart_foot', 'my_ouput_notice'); } return $spdb; } function my_ouput_notice() { echo '<div class="spMessage">This is a message area - add what you want</div>'; }
that should do what you want...
I also took the liberty of adding a message section so you can output some text asking them to join or whatever... you can remove it if you like...
Visit Cruise Talk Central and Mr Papa's World
Thanks, Mr Papa.
Unfortunately it threw an error at me…
add_filter('sph_topicview_query', 'my_topic_view_query'); function my_topic_view_query($spdb) { global $spThisUser; if ($spThisUser->guest) { $spdb->where.= ' AND (post_index = 1)'; add_action('sph_BeforeSectionStart_foot', 'my_ouput_notice'); } return $spdb; } function my_ouput_notice() { echo '
Join the site to see more.
'; }
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at XXXXXXXX/wp-content/sp-resources/forum-themes/1Qi/templates/spFunctions.php:14) in XXXXXXXX/wp-content/plugins/wp-cart-for-digital-products/wp_eStore1.php on line 9
I've X'd out some sensitive information, but you should get the gist. Do you know what the problem might be?
Thanks again.
are you sure you did a code copy?? from the raw code? otherwise, you might have gotten wrongly encoded quotes... use the raw code button above the syntax highlighted code...
the code works for me... so thinking its cut and paste error...
Visit Cruise Talk Central and Mr Papa's World
oh, new file then... so yeah, have to put that... sorry...
so it gives you what you want?
Visit Cruise Talk Central and Mr Papa's World
sorry, not following... Its showing instead of the first post? or elsewhere on page? do you have link to it?
Visit Cruise Talk Central and Mr Papa's World
1 Guest(s)