![]() |
|
|
Thread Tools |
|
#1
|
||||
|
||||
|
Changing templates with plugins
Just when I thought I had finally understood a small percentage of the vBulletin code, a completely new (but very powerful) template syntax has been released!
![]() I have a small piece of code that adds an extra checkbox when a user is posting a reply. This ultimately adds some text to the message area and changes the prefix. Unfortunately with the new version, the page wont even load. I've read some of the template articles and examined some 4.0 mods. However, they are at a level higher than my current vBulletin code comprehension. Here is the code that is compatible with vB 3.8 using the "newreply_form_complete" hook:
There is also another plugin hooked to "newreply_post_start" that massages the data. It probably isn't compatible either, but I'll cross that bridge when I get to it. Is there still a way to perform the functionality of my current code? If so, could someone give me some guidance? No members have liked this post.
Last edited by Mrajp : 15 Dec 2009 at 14:33. Reason: Missed question |
||||
|
#2
|
||||
|
||||
|
Is there a question here?
__________________
Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools - Online vBulletin Manual If I post some CSS and don't say where it goes, put it in the additional.css template. I will NOT help via PM (you will be directed to post in the forums for help.) No members have liked this post.
|
|
#3
|
|||
|
|||
|
Whoops! I just realized I forgot to ask one. Thanks Lynne!
Is there still a way to perform the functionality of my current code? If so, could someone give me some guidance? Thanks in advance. No members have liked this post.
|
|
#4
|
||||
|
||||
|
It would be like this.
No members have liked this post.
|
||||
|
#5
|
||||
|
||||
|
Originally Posted by BBR-APBT
I don't mean to seem ignorant, but the only difference I see between your code and mine is that the $replace string is all on one line. Are you saying that vB 4.0 can only handle 1 line replacement strings?
The above code still doesn't work in vB 4.0 No members have liked this post.
Last edited by Mrajp : 15 Dec 2009 at 20:28. |
||||
|
#6
|
||||
|
||||
|
With the proper hook location? process_templates_complete
No members have liked this post.
|
|
#7
|
||||
|
||||
|
Well, I originally didn't have the hook location set to "process_templates_complete". However, even after changing the hook location, I get the following error message and the page does not load:
I've hardcoded the replace string into the style just to verify that the HTML is correct. When hardcoded, the page loads without error and the checkbox appears. Any Ideas? No members have liked this post.
|
||||
|
#8
|
||||
|
||||
|
Can I see your exact code.
You can post the error all day long with out the code its no good. No members have liked this post.
|
|
#9
|
||||||||
|
||||||||
|
Most certainly,
Here is the section of the style 'newreply' with the comment
Here is my complete plugin code on the 'process_templates_complete' hook:
I'm running vB 4.0 RC2. Please let me know if you need any more information. Thanks Again. No members have liked this post.
|
||||||||
|
#10
|
||||
|
||||
|
Try this
I switched the " and ' around. No members have liked this post.
|
||||
|
#11
|
||||
|
||||
|
My question is a little bit offtopic.
Can the new vB4 Template Mering be used for this? http://www.vbulletin.com/forum/entry...Way-Comparison Anybody tried this?
__________________
my addons: http://ragtek.github.com No members have liked this post.
|
|
#12
|
||||
|
||||
|
Originally Posted by ragtek
It should stay there with upgrade but I don't trust it my self as I haven't tested that feature out enough yet.
No members have liked this post.
|
|
#13
|
||||
|
||||
|
Originally Posted by BBR-APBT
Switching the string identifiers fixed the problem. Thank you so very much!
![]()
Originally Posted by ragtek
This looks interesting, I'm going to have a lot of style changes to make and I may try this.
No members have liked this post.
|
||||
|
#14
|
||||
|
||||
|
If it's not working, try tms!
__________________
my addons: http://ragtek.github.com No members have liked this post.
|
![]() |
«
Previous Thread
|
Next Thread
»
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Advanced Templates: Dynamic Templates Changing according to different conditions | Logician | vBulletin 2.x Full Releases | 312 | 24 Apr 2005 19:20 |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
| Thread Tools | |
|
|
| New To Site? | Need Help? |
All times are GMT. The time now is 00:26.






