vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   New Posting Features - Template in NewTheread (https://vborg.vbsupport.ru/showthread.php?t=224262)

chomiczek 09-29-2009 10:00 PM

Template in NewTheread
 
1 Attachment(s)
Hi. We have problem in market section, because user don't write price, contact, etc.. We fix it :D

First visit AdminCP->Modifications->Plugin management, click NEW and fill:
- Produckt - vBulletin
- Localization - global_start
- Title - Ur own title of this template
- PHP Code -
PHP Code:

ob_start();
   include(
'szablonSprzedaz.php');
   
$szablonSprzedazob_get_contents();
ob_end_clean(); 

- Acitve set Yes

Save and reload

Now U must created new phpfile like this:
Code:

<?PHP
if ($_GET['do']=='newthread'&&$_GET['f']==15&&) {
        ?>
  <script type="text/javascript">
        var szablon = "Nazwa: \nCena: \nKontakt: \nOpis: \nLink zewnętrzny: \nZdjęcia: ";
        document.getElementById('vB_Editor_001_textarea').innerHTML = szablon;
        </script>
  <?PHP
}
?>

U can change var szablon it's text like U see in texteditor
U can change $_GET['f']==15 - 15 it's thread id.. if U want this same template in many threads U can use php function in_array() if U want other template in many threads U must modificated this code and U must change $_GET['f'] and past it on end the file.

save file like: szablonSprzedaz.php and upload to Ur root folder on forum.

In this case if U visit my forum, and go to the market http://forum.omegaklub.eu/forumdisplay.php?f=15 nad click New Topic, u see in textarea template like this:
Code:

Nazwa:
Cena:
Kontakt:
Opis:
Link zewnętrzny:
Zdjęcia:

in template footer U must paste on the end $szablonSprzedaz
enjoy

This mod don't work on WYSIWYG mode :( i think that I fix that in few days

Po Polsku: Modyfikacja pozwala wstawiać dowolną treść do pola post w określonych działach.

Najpierw należy dodać w AdminCP->Wtyczki i modyfikację->Zarządzaj wtyczkami nową wtyczkę, kt?rą wypełniamy jak poniżej:
- Produkt - vBulletin
- Lokalizacja - global_start
- Tytuł - Tytuł Twojej modyfikacji
- Kod PHP -
PHP Code:

ob_start();
   include(
'szablonSprzedaz.php');
   
$szablonSprzedazob_get_contents();
ob_end_clean(); 

- Aktywna ustaw na TAK

Save and reload

a nastęnie utw?rz plik jak szablonSprzedaz.php (w załączeniu).
Możesz zmienić to co jest w linii var szablon = to jest właśnie tekst, kt?ry będzie dopisany
Mozesz zmienić $_GET['f']==15 - 15 to jest id sekcji w jakiej ma się to pojawiać. Jeżeli chcesz te same szablony w kilku miejscach użyj funkcji in_array (PHP)
Jeżeli chcesz r?żne szablony w r?żnych sekcjach musisz stworzyć identyczne warunki modyfikując tylko $_GET['f'] i podając liczbę odpowiadająca konkretnym sekcją..

w templatce footer musisz wkleić na samym dole pliku $szablonSprzedaz

sensimilla 09-30-2009 10:58 AM

I believe you would have to better explain what it does to make people enjoy it :)
Screenshitz would be more than welcome.

Wydaje mi się że tekst po angielsku nie za bardzo wyjaśnia o co chodzi.
Radzę wrzucić zrzuty z ekranu lub lepiej wyjaśnić.
Jeśli to predefiniowane pola do wprowadzenia przy zakładaniu nowego postu to taki hack już istnieje jako plugin.

New Joe 09-30-2009 02:08 PM

I no understand:confused:;)

bada_bing 09-30-2009 05:38 PM

English Please

drpeppper 09-30-2009 05:53 PM

i think hes adding entries to the new thread template.

lazydesis 09-30-2009 07:16 PM

screenshots pls :)

Robert Waanders 09-30-2009 07:36 PM

hmmmmm... On my forum i have the same problem on our marketplace... I wil watch this thread very closely..

Robert

NissanClub 10-05-2009 05:07 PM

Subscribed :) I need the WYSIWYG function to work and i'll update my forums with this mod.

chomiczek 10-05-2009 05:11 PM

I works on the WYSIWYG.. I think that I and in this week

I fix problems with IE and Opera.. In this moment work ok on FF, IE and Opera, but not in WYSIWYG


All times are GMT. The time now is 02:33 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.01046 seconds
  • Memory Usage 1,736KB
  • 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
  • (2)bbcode_code_printable
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete