collapse

* User Info

 
 
Welcome, Guest. Please login or register.
Did you miss your activation email?

* Who's Online

  • Dot Guests: 54
  • Dot Hidden: 0
  • Dot Users: 1
  • Dot Users Online:

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • AngelinaBelle: For Documentation navigation, I really like to use the "<<" icon to turn that menu into a "navigation left panel", because I can read it better that way.
    April 21, 2014, 04:12:13 PM
  • oNLy1: Nakroma, please use the forum for support - ask all the questions (dumb or not) they will get answered
    April 18, 2014, 08:03:49 PM
  • Nakroma: i know this is just another question but im too dumb for it, where can I actualy get into the GENERAL SETTINGS page? im dumb sorry ;-;
    April 18, 2014, 04:27:39 PM
  • Nakroma: ahh okey, i get it. thanks
    April 18, 2014, 04:16:18 PM
  • [SiNaN]: Please don't get me wrong; I didn't mean that. You need to use the navigation menu right above the yellow Documentation bar you describe to navigate through different sections of documentation.
    April 18, 2014, 04:12:37 PM
  • Nakroma: okey I am dumb, could someone point out where at the top of the site it is? with a screenshot or something? if you mean the yellow Documention bar, thats not clickable for  me :|
    April 18, 2014, 03:57:34 PM
  • [SiNaN]: I wouldn't say it's hidden, lol. And it's extensive enough, thanks to Angelina.
    April 18, 2014, 02:28:55 PM
  • oNLy1: Documentation [link] (hidden at top of site)
    April 18, 2014, 12:48:01 PM
  • Nakroma: am I dumb or is there actually no tutorial? [link]
    April 18, 2014, 08:29:41 AM
  • AngelinaBelle: Welcome Gusto Prod.  Please visit [link] for info on creating an SMF forum
    April 17, 2014, 12:04:00 PM
  • GUSTO PROD: hi all give me creat new forum free
    April 16, 2014, 12:21:54 PM
  • AngelinaBelle: Hello w1ck3d! Welcome to Simple Portal. Unfortunately, there are not Russian speakers here very often.  Aplogies
    April 14, 2014, 07:49:26 AM
  • w1ck3d: тест
    April 14, 2014, 02:50:12 AM
  • Underdog: How to use Simple Portal for SMF: [link]
    April 02, 2014, 07:52:45 PM
  • Underdog: Thariq, please post questions in the forum. thank you.
    April 02, 2014, 07:51:40 PM
  • Thariq: how to create portal/site
    April 02, 2014, 06:30:42 AM
  • Ali çelen: forum nasıl oluştırıcam
    March 30, 2014, 10:59:08 PM
  • Ali çelen: sa
    March 30, 2014, 10:58:54 PM
  • AngelinaBelle: processor -- I think your customization will probably be just fine.
    February 14, 2014, 07:18:41 PM
  • AngelinaBelle: noumankhan: Welcome to SimplePortal.  Please read the documentation above. If you have questions about how to make a forum, please seek help at [link]
    February 14, 2014, 07:16:45 PM

* Team Blog

* Recent Posts

Re: Youtube Block - 1.0 by USFA
[Today at 12:38:51 AM]


Re: Youtube Block - 1.0 by USFA
[Today at 12:20:58 AM]


Re: Youtube Block - 1.0 by cy8erpunk
[Yesterday at 06:24:00 PM]


Re: Aeva Media Block by USFA
[Yesterday at 11:51:37 AM]


RSS Blocks not updating. by USFA
[Yesterday at 11:47:35 AM]

Blocks speak! Do you have an interest in getting more blocks - or even making your own? The Blocks Board is for you!

Author Topic: [Tip] Post Notifications on shoutbox  (Read 10498 times)

0 Members and 1 Guest are viewing this topic.

Offline 130860

  • Super Handsome Language Coordinator
  • Comrade
  • *
  • Posts: 1777
  • Gender: Male
  • You and I are not the same class of pirate!
  • SMF Version: 2 RC3
  • SP Version: 2.3.2
Re: [Tip] Post Notifications on shoutbox
« Reply #40 on: November 29, 2012, 03:34:39 PM »
any error on the error log? this code was made for an old version of SO, perhaps its different on new version, I haven't checked the new version.

weerforum

  • Guest
Re: [Tip] Post Notifications on shoutbox
« Reply #41 on: November 29, 2012, 03:36:52 PM »
No errors but just dont show up  ;)

Offline 130860

  • Super Handsome Language Coordinator
  • Comrade
  • *
  • Posts: 1777
  • Gender: Male
  • You and I are not the same class of pirate!
  • SMF Version: 2 RC3
  • SP Version: 2.3.2
Re: [Tip] Post Notifications on shoutbox
« Reply #42 on: November 29, 2012, 03:40:27 PM »
Ok, lets put the query right after the call to createPost() then, not the best place but it should work.

weerforum

  • Guest
Re: [Tip] Post Notifications on shoutbox
« Reply #43 on: November 29, 2012, 03:47:41 PM »
No result grrrrrrrrrrrrrrrrrr

Offline phantomm

  • Translator
  • *
  • Posts: 326
  • Gender: Male
  • Smile, tomorrow will be worse...
  • SMF Version: 2.0.2
  • SP Version: 2.3.5
Re: [Tip] Post Notifications on shoutbox
« Reply #44 on: November 30, 2012, 09:12:55 AM »
I tried to make it work with latest SP and code works partially - shouts are added in database, but shoutbox does not display them :|

Offline Underdog

  • Support
  • *
  • Posts: 721
  • Gender: Male
  • On Hiatus
    • Underdog-01 GitHub Repositories
  • SMF Version: 2.0.7
  • SP Version: 2.3.5
Re: [Tip] Post Notifications on shoutbox
« Reply #45 on: November 30, 2012, 02:18:12 PM »
  I have only very briefly looked at the edits to Post.php from this thread & can see some possible issues.

  • It is hard coded to only edit db data for shoutbox id#1
  • JS needed to implement shouts (client side/dynamic)

SP already has a function to add the shouts to the db and can be called instead of implementing the db edits I see in that file. Imo this is not the issue though.. it is possibly the shoutbox id# (if the user has set up more than 1 shoutbox) & the need for client side js.

Here is a brief example:
Code: [Select]
global $context;

$shout = 'This is a test shout';
$shout_id = 1;
$context['SPortal']['shoutbox'] = sportal_get_shoutbox($shout_id, true);

sportal_create_shout($context['SPortal']['shoutbox'], $shout);
echo '
<script language="Javascript" type="text/javascript"><!-- // --><![CDATA[
sp_submit_shout(', $shout_id, ', \'', $context['session_var'], '\', \'', $context['session_id'], '\');
// ]]></script>';

130860,
  The above uses shoutbox id#1 .. hard code that id#, another id# or create a drop-down option in SP admin menu to opt a specific shoutbox id#.  The sportal_create_shout & sportal_get_shoutbox functions should work without having to include any SP php file as it is already previously loaded/used by SP.

  One can just try adding the js after the db edits & it will probably work if that is the route opted.

« Last Edit: November 30, 2012, 03:20:26 PM by Underdog »

weerforum

  • Guest
Re: [Tip] Post Notifications on shoutbox
« Reply #46 on: February 05, 2013, 05:02:22 PM »
Didn`t work sorry ?
Not showing new post in te shoutbox

Any update ???
I love to see any post to show up in the shoutbox please

weerforum

  • Guest
Re: [Tip] Post Notifications on shoutbox
« Reply #47 on: March 03, 2013, 02:02:10 PM »
Please ???