vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Miscellaneous Hacks - [AJAX] News/Announcements (https://vborg.vbsupport.ru/showthread.php?t=144414)

harmor19 04-08-2007 10:00 PM

[AJAX] News/Announcements
 
With this add-on you can quickly add new or announcements on your forum's index, forum display, or thread display. Each forum and thread can have their own unique message.

In the vBulletin options you can choose which user's can edit the text by entering their user ID into the box.
You can choose whether or not moderators can edit the message in the forums they moderate.
You can choose if you want the news/announcements to display on forum home, forum display, or thread display.

You can use bbcode and HTML but only if HTML tags have bbocde to convert to.
For example if you type <b></b> it'll convert to [b][/b].

Here are some screensohts
http://xenweb.net/images/ajaxnews/ajaxnews_1.png
http://xenweb.net/images/ajaxnews/ajaxnews_2.png

harmor19 04-09-2007 05:19 PM

I hope you like this hack.

needtheend 04-09-2007 05:19 PM

Thanx

HDT 04-09-2007 05:42 PM

This should work on 3.6.0 with totally customize template?

harmor19 04-09-2007 05:44 PM

Quote:

Originally Posted by HDT (Post 1223458)
This should work on 3.6.0 with totally customize template?

I can't promise if it will work.

harmor19 04-09-2007 08:04 PM

Before anyone asks I like to explain some things.

If you want the moderator's to be able to edit the news/announcement of the forums they moderate you don't have to enter their User ID in the text box.

If you want line breaks in the news/announcements you'll need to use the break tag ( <br /> ).

apfparadise 04-09-2007 10:20 PM

installed, but nothing is happening as far as AJAX. I have AJAX on, other things work, but this one, I click and click and it stays a line of text. It's on, and I have ability to moderate it. Nothing.

ChopBam 04-09-2007 11:18 PM

When I click to Mark all Forums as read, I get a database error.
Everything else seems to run pretty smoothly.

I would prefer though if when you click to edit it that the codes stay in BB format, because HTML doesn't show up.

bitdefuser 04-09-2007 11:32 PM

Suggestions:
Make it global for all the boxes. (I don't want to manually edit every single forum's box and put the message I want.)

harmor19 04-10-2007 12:06 AM

Quote:

Originally Posted by ChopBam (Post 1223674)
When I click to Mark all Forums as read, I get a database error.
Everything else seems to run pretty smoothly.

I would prefer though if when you click to edit it that the codes stay in BB format, because HTML doesn't show up.

I'll look into the database error.
When you edit the message doesn't show the way I want it to but when you refresh the page it should show fine.


Quote:

Originally Posted by bitdefuser (Post 1223679)
Suggestions:
Make it global for all the boxes. (I don't want to manually edit every single forum's box and put the message I want.)

I'll try to do this in the next release.

ChopBam 04-10-2007 12:29 AM

Quote:

Originally Posted by harmor19 (Post 1223701)
When you edit the message doesn't show the way I want it to but when you refresh the page it should show fine.

Ah I see. It's a little inconvenient but it's better than what I had originally thought.
Can anybody else confirm the DB error? I'm running on 3.6.5 with some modified templates and a bunch of other hacks.

harmor19 04-10-2007 12:36 AM

I have fixed the database error. I will upload the upgrade after I upload the upgrade for "Usergroup Messages".

harmor19 04-10-2007 01:11 AM

I have fixed the database error when marking threads as read.

bitdefuser 04-10-2007 02:20 AM

Quote:

I'll try to do this in the next release.
Thanks and good luck! :)

dbirosel 04-10-2007 02:36 AM

Sweet BB Code, but why do we still need to enter the <br /> tag, if BB code is enabled?

What about if they moderate a certain forum, but i don't want them to have permission with the news/announcements feature?

projectego 04-10-2007 02:52 AM

[high]* projectego clicks install :)[/high]

harmor19 04-10-2007 03:01 AM

Quote:

Originally Posted by dbirosel (Post 1223778)
Sweet BB Code, but why do we still need to enter the <br /> tag, if BB code is enabled?

What about if they moderate a certain forum, but i don't want them to have permission with the news/announcements feature?

Do you mean if a user can moderate two forums but you only want them to have permission to use the news/announcement feature on one forum and not the other?
If so it isn't possible with this version.

efil 04-10-2007 03:05 AM

Hi,
Where should i find the templates that need to edit?

I can't find them.

harmor19 04-10-2007 03:11 AM

Quote:

Originally Posted by efil (Post 1223804)
Hi,
Where should i find the templates that need to edit?

I can't find them.

In your ACP go to Styles & Templates --> Style Manager Click on the button that looks like this [<< >>].
Here you will find "headerinclude" and "navbar". navbar can be found in "Navigation / Breadcrumb Templates"

efil 04-10-2007 03:38 AM

Quote:

Originally Posted by harmor19 (Post 1223808)
In your ACP go to Styles & Templates --> Style Manager Click on the button that looks like this [<< >>].
Here you will find "headerinclude" and "navbar". navbar can be found in "Navigation / Breadcrumb Templates"

In your install.txt file and now you are writing "headerinclude" instead of "headinclude".
Thats why i didn't find it in the search.

harmor19 04-10-2007 03:52 AM

Quote:

Originally Posted by efil (Post 1223829)
In your install.txt file and now you are writing "headerinclude" instead of "headinclude".
Thats why i didn't find it in the search.

Sorry about that.

hdrmut 04-10-2007 05:24 AM

Hello

thanx for great hack

but this not support arabic Language [ charset=windows-1256 ]

soo can you make it suported ?

Hornstar 04-10-2007 10:30 AM

Looks like a nice looking mod, will consider this in the near future. thanks.

Harley77 04-10-2007 01:56 PM

Great hack. My only suggestion is to allow the option of making the announcement block global. That is, the same thing is displayed on ALL pages, rather than each one having it's own.

harmor19 04-10-2007 04:03 PM

I think I have figured out how to make messages global. I am working on it right now.

harmor19 04-10-2007 04:32 PM

This was a quick upgrade to allow a global message. In the future I'd like to implement inheritance. This means that you can have each forum have their own message and have the threads in the respective forum share the same message.

Changed Files
-- product-ah_ajaxnews.xml

Changed Templates
-- navbar

projectego 04-10-2007 04:35 PM

Thanks for the update. :)

harmor19 04-10-2007 04:52 PM

Quote:

Originally Posted by hdrmut (Post 1223894)
Hello

thanx for great hack

but this not support arabic Language [ charset=windows-1256 ]

soo can you make it suported ?

I don't know how to go about doing that.

Terminatoronly 04-10-2007 05:01 PM

awsem i been waiting for a new mod :D

efil 04-10-2007 05:02 PM

It's not working in hebrew lang!

Harley77 04-10-2007 05:06 PM

Quote:

Originally Posted by harmor19 (Post 1224287)
This was a quick upgrade to allow a global message. In the future I'd like to implement inheritance. This means that you can have each forum have their own message and have the threads in the respective forum share the same message.

Changed Files
-- product-ah_ajaxnews.xml

Changed Templates
-- navbar



Awesome. Works perfectly.

Sofia 04-10-2007 05:08 PM

Thanks a lot, harmor ! I love your hacks.

It's very clean and i like it :)

Sofia 04-10-2007 05:27 PM

harmor, i've a little problem.

I indicate my ID in the options, i activate your hack, but when i try to change the news, it indicate me "Direct Access is Prohibited". Why there is this message ?

I read the php file :

PHP Code:

if($can_edit == OR !$_SERVER['HTTP_REFERER'])
{
    die(
'Direct Access is Prohibited');


$can_edit == 0 -> i can edit

!$_SERVER['HTTP_REFERER'] -> ???

So when i delete !$_SERVER['HTTP_REFERER'], it's good, but why ?

Thanks :)

Sinistra 04-10-2007 07:05 PM

When posting news with any (") or (') I get a database error Also when adding vBcode int converts the coed th HTML this also needs to be fixed and you will have a great hack

Sofia 04-10-2007 08:19 PM

Hi harmor, i have translate your hack into french. I put it here, if you want to add in your thread :)

Excellent hack ;)

Veer 04-10-2007 09:29 PM

Very Nice hack.

Thanks.

bitdefuser 04-10-2007 10:28 PM

Quote:

Originally Posted by harmor19 (Post 1224287)
This was a quick upgrade to allow a global message. In the future I'd like to implement inheritance. This means that you can have each forum have their own message and have the threads in the respective forum share the same message.

Changed Files
-- product-ah_ajaxnews.xml

Changed Templates
-- navbar

Yes! :) Thanks for adding my suggestion but, the global function does not work.

harmor19 04-11-2007 12:00 AM

Quote:

Originally Posted by bitdefuser (Post 1224509)
Yes! :) Thanks for adding my suggestion but, the global function does not work.

Did you enable it in vBulletin Options -- > Ajax News Settings?

v2neo 04-11-2007 12:02 AM

does this work wiht 3.6.5?

thanx

harmor19 04-11-2007 12:04 AM

Quote:

Originally Posted by v2neo (Post 1224567)
does this work wiht 3.6.5?

thanx

It should work.


All times are GMT. The time now is 05:23 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01663 seconds
  • Memory Usage 1,817KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (14)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete